📄 TOML / INI Converter

Parse, validate, and convert between TOML, INI, and JSON formats, with the work done by this page's own script rather than a server.

Last updated: May 18, 2026 · By Λ

Input (TOML) 0 lines, 0 chars
Output (JSON) 0 lines, 0 chars
Ready. Paste your content and it will be converted automatically.

Free TOML / INI Converter

Convert between TOML, INI, and JSON with full parsing, validation, and pretty-printed output. The TOML parser supports key-value pairs, sections (tables), arrays of tables, basic and literal strings, integers, floats, booleans, inline tables, and arrays. The INI parser handles sections, key=value and key:value syntax, and comments using # or ;. Validation errors are shown with line numbers to help you fix formatting issues. Everything is parsed by the script embedded in the page, so nothing you paste gets transmitted anywhere.

What is TOML and INI?

TOML (Tom's Obvious, Minimal Language) is a configuration file format designed to be easy to read and write. It maps cleanly to hash table data structures and supports rich data types including strings, integers, floats, booleans, dates, arrays, and nested tables. TOML is widely used in projects like Rust's Cargo, Python's pyproject.toml, and Hugo static site configurations. Its syntax is intuitive: sections are defined with brackets, and values are assigned with equals signs.

INI files are one of the oldest and simplest configuration formats, originating from early Windows and DOS systems. They use a straightforward structure of sections in square brackets with key-value pairs separated by equals signs or colons. While INI lacks the richer data types of TOML, it remains popular for its simplicity and is still used in PHP (php.ini), Python (configparser), Git (.gitconfig), and many other tools. This converter lets you translate between TOML, INI, and JSON without installing any command-line tools or writing parsing code yourself.

How to Use This Tool

  1. Select your conversion mode from the top buttons: TOML to JSON, JSON to TOML, INI to JSON, or JSON to INI.
  2. Paste your source content into the input panel on the left, or click one of the sample buttons to load example data.
  3. Click the "Convert" button to process your input. The converted output will appear in the right panel with proper formatting.
  4. Copy the result using the copy button, or clear both panels to start fresh. If your input has syntax errors, the tool will display a detailed error message with line numbers to help you fix the issue.

Key Features

Frequently Asked Questions

What is the difference between TOML and INI?

TOML supports rich data types such as arrays, nested tables, dates, and typed values (integers, floats, booleans). INI files are simpler and treat all values as strings, with only flat sections and key-value pairs. TOML has a formal specification, while INI formats vary between implementations. Choose TOML for structured configuration and INI for simple settings files.

Why convert TOML or INI to JSON?

JSON is the most widely supported data interchange format, understood by virtually every programming language and tool. Converting your TOML or INI configuration to JSON allows you to use it in web applications, APIs, or tools that expect JSON input. It is also useful for comparing configuration values or migrating settings between different systems.

Does this tool validate my TOML file?

Yes. The parser validates your TOML input against the specification while converting it. If your file contains syntax errors such as mismatched quotes, invalid table headers, or unsupported escape sequences, the tool will display a clear error message with the line number where the problem was found.

Can I convert deeply nested JSON to TOML?

Yes, the converter handles nested JSON objects by generating TOML table sections using dotted key paths. Arrays of objects are converted to TOML arrays of tables. However, extremely complex or mixed-type arrays may not have a direct TOML equivalent, since TOML requires arrays to contain elements of the same type.

Related tools