JSON to TOML
Convert JSON into TOML, the configuration format used by Cargo, pyproject, and many static site tools. Nested objects become tables and arrays of objects become arrays of tables. TOML has no null, so null values are dropped and listed in a warning.
JSON
TOML
Result will appear hereReady. Press Convert or Ctrl+Enter.
How to use the JSON to TOML
- Paste a JSON object (TOML needs an object at the top).
- Press Convert.
- Copy the TOML output.
Example
The notes key is null in the sample, so it is dropped with a warning.
{
"name": "json-utils",
"version": "1.0.0",
"private": false,
"tags": ["json", "tools"],
"author": { "name": "Ada", "active": true },
"score": 9.5,
"notes": null
}Frequently asked questions
Why did my null values disappear?
TOML has no null type. Dropping them is the only honest option, and the tool warns you each time.
Why did conversion fail on my array?
TOML arrays must hold one type. Mixed type arrays and arrays mixing tables with scalars cannot be represented.