Converter Tools
TOML to JSON Converter
Convert TOML to JSON and JSON back to TOML in your browser. Supports tables, arrays of tables, dotted keys, inline tables, multi-line strings, and dates.
Convert
TOML and JSON in either direction
JSON output indent
TOML 1.0 features supported: tables, arrays of tables, dotted keys, inline tables, multi-line basic and literal strings, integers in decimal/hex/oct/bin with underscores, floats, booleans, and RFC 3339 dates.
Conversions run entirely in your browser. Nothing you paste is sent to a server.
How to use
- Pick a direction: TOML to JSON or JSON to TOML. The toggle at the top of the tool swaps the input and output panels.
- Paste your file into the input box, or click Load sample to start with a realistic example that exercises tables, arrays of tables, dotted keys, inline tables, multi-line strings, and dates.
- Read the converted output on the right. The result chips show how many tables and keys were parsed, the byte size of the output, and whether any JSON nulls had to be dropped because TOML has no null value.
- Adjust the JSON output indent (2 spaces, 4 spaces, or minified) when converting TOML to JSON. JSON input is read as-is.
- Click Swap direction to feed the current output back as the new input. Use Copy to grab the result, Clear input to start over, or Load sample to reset to the example.
About this tool
TOML to JSON Converter is a two-way converter between TOML (Tom's Obvious Minimal Language) and JSON. Pick a direction, paste your config, and read the converted output as you type. The TOML parser targets the TOML 1.0.0 specification and supports the features real-world configuration files actually use: standard tables ([package]) and nested tables ([servers.alpha]), dotted keys (a.b.c = 1), inline tables ({x = 1, y = 2}), arrays of tables ([[products]]), arrays with mixed types and nested arrays, basic and literal strings, multi-line basic and literal strings with TOML 1.0 line-trim and trailing-quote rules, integers in decimal, hex (0x), octal (0o), and binary (0b) with underscores as digit separators (1_000_000), floats with exponents and the special inf/nan values, booleans, RFC 3339 local and offset datetimes, local dates, and local times. The JSON to TOML emitter writes the cleanest TOML representation it can find for each JSON shape: top-level scalars become key/value pairs, nested objects are written as [headers] when they hold nested data, arrays of plain objects expand into [[arrays of tables]] blocks, short flat objects use inline-table syntax for readability, strings with newlines use triple-quoted multi-line basic strings, and date-shaped strings are emitted as native TOML dates so the round trip preserves typing. TOML has no null value, so any JSON null is dropped from the output and the result panel reports how many nulls were dropped. Parse errors include the line and column number so configuration mistakes are easy to find. Everything runs locally with no dependencies; your config files never leave your device. Useful for working with Cargo.toml, pyproject.toml (PEP 518 and PEP 621), Hugo config.toml, netlify.toml, Poetry, Black, ruff, Dependabot, Spin, Foundry, and dozens of other modern tools that picked TOML as their configuration format.
Free to use. Works in your browser. No signup, no login.
Related tools
You may also like
YAML to JSON Converter
Two-way YAML and JSON converter with anchors, flow, and block scalars.
Open tool
ConverterJSON to YAML Converter
Convert JSON into YAML with block or flow style and smart quoting.
Open tool
DeveloperJSON Formatter
Format, minify, and validate JSON in your browser.
Open tool
ConverterJSON to XML Converter
Convert JSON to XML with attribute keys, text nodes, indent, and array options.
Open tool
ConverterXML to JSON Converter
Convert XML to JSON with attribute, text, force-array, and value-parsing options.
Open tool