JSON to TOML Converter

Turn JSON settings into clean TOML with tables and arrays of tables.

100% Client-Side Processing — your data never leaves this browser. Works offline. How it works

0 lines • 0 bytes Ready
Tip: drop a file anywhere on the editor
Input
Paste, type or drop a file
1
Result
Updates as you type
// Output will appear here…
About this tool

How the JSON to TOML works

Convert JSON to TOML with proper [tables], [[arrays of tables]] and inline arrays. Ideal for Cargo.toml, pyproject.toml and app configs. Runs in your browser.

How to use the JSON to TOML

  1. Paste a JSON object.
  2. Check the generated tables and arrays.
  3. Copy the TOML or download it as a .toml file.

JSON to TOML example

Input
{"title":"App","server":{"port":8080,"debug":false},"hosts":["alpha","beta"]}
Result
title = "App"
hosts = ["alpha", "beta"]

[server]
port = 8080
debug = false

When to use it

  • Writing pyproject.toml, Cargo.toml or Hugo configuration.
  • Migrating JSON config files to TOML.
  • Generating TOML settings from code.

Tip: Dates stay as quoted strings. If you need native TOML datetimes, remove the quotes around those values afterwards.

Proper TOML tables

Nested objects become [section] tables and arrays of objects become [[array]] tables.

Readable keys

Simple keys stay bare; keys with spaces or dots are quoted automatically.

Escaped strings

Quotes, backslashes, tabs and newlines are escaped correctly.

Null handling

TOML has no null, so null values are left out and a comment tells you how many.

FAQ

Common questions

Why are some values missing?

TOML has no null value. Keys whose value is null are omitted, and the output starts with a comment counting them.

Does the top level have to be an object?

Yes. A TOML document is a table, so the JSON must be an object such as {"title": "App"}.

Which TOML version is produced?

TOML v1.0, which Cargo, Poetry, pip (pyproject.toml), Hugo and most libraries read.

Is it private?

Yes, conversion runs in your browser.