TOML to JSON Guide: Tables Become Objects
Learn how TOML sections map to nested JSON objects and how values are typed.
What is the TOML to JSON Converter?
This converter handles the TOML subset most small config files use: key = value pairs, string, integer, float and boolean values, arrays of simple values, and [table] headers, including dotted table names such as [server.tls]. It is not a full TOML parser, so inline tables, arrays of tables, multi-line strings and date values with special handling are outside its scope; dates are kept as plain strings. Comments after a value are stripped only when they sit outside quotes.
How to use it
- Paste your TOML into the box.
- Click Convert to JSON.
- Copy the JSON result.
Worked example
For the sample, the result is JSON with title Garden Notes, version 2 as a number, tags as an array, and an author object with name Ava and email ava@example.com.
Why use TOML for configuration?
Because it is easy to read and write by hand, with clear sections and simple value types, while JSON is easier for programs to consume.
Frequently asked questions
What TOML features are supported?
Key-value pairs, strings, numbers, booleans, simple arrays and table headers, including dotted names.
What about dates?
Date-like values are kept as plain strings in this subset, rather than being converted to a special date type.