Toml To Json
Free online toml to json tool, no installation required
About TOML to JSON Converter
Parses TOML using a hand-written recursive-descent parser that supports tables, dotted keys, arrays of tables (via [[name]]), inline tables, comments, basic and literal strings, integers with underscore separators, floats, inf/nan, and date/datetime tokens (returned as strings). Output is serialized as JSON and you can switch between Pretty (2-space) and Minified.
How to Use
1. Paste your TOML into the input textarea 2. Choose Pretty print or Minified using the radio buttons on the right 3. Click Convert (the arrow button) to run the parser 4. Use Copy to copy the JSON, or Clear to reset both panes
Supported TOML Constructs
Tables use [section] headers; dotted headers like [a.b.c] create nested objects. Dotted keys (a.b = 1) inside any section create nested keys. Arrays support mixed values, trailing commas, and inline comments. Inline tables use { a = 1, b = 2 }. Strings accept "basic" with escapes (\n, \t, \uXXXX, etc.) and 'literal' forms. Numbers support +/- sign and _ digit separators; dates matching YYYY-MM-DD are kept as strings.
▶What happens to invalid TOML?
▶How are dates and datetimes handled?
▶Are comments preserved?
▶What is the difference between Pretty and Minified?
If this tool has been helpful to you, consider buying me a coffee.
Buy me a coffee