About TOML to JSON

TOML to JSON reads a TOML document into a JSON structure and writes a JSON object back out as TOML.

It covers the common shapes: key-value pairs, dotted keys, tables, arrays of tables, inline tables, nested arrays, and the scalar types. Datetimes are kept as strings. It runs in your browser.

How to use it

  1. Paste your TOML or JSON and pick the direction.
  2. Read the converted output.
  3. Copy the result.

Common questions

Is this a full TOML implementation?

No. It is a practical subset that handles the cases most config files use. Very unusual TOML may not round-trip.

How are dates handled?

Datetime and time values are kept as strings, since JSON has no date type.

Does it preserve comments?

No. Comments are dropped, like in most format converters.