JSON to INI
This converter turns a JSON object into INI configuration text. Nested objects become [section] blocks and scalar fields become key/value pairs, with the separator set to either an equals sign or a colon. It is a convenient way to produce Windows- or Java-style .ini configuration files, and the conversion runs entirely in your browser — nothing is uploaded.
How to use it
- 1
Paste a JSON object
The root must be an object, and each first-level nested object becomes a section.
- 2
Choose the separator
Use an equals sign or a colon between the key and the value.
- 3
Set an optional global section
Give root-level scalar fields a default section name, or leave it blank.
- 4
Copy the result
Take the .ini text for your application config, or switch to the reverse direction to go back to JSON.
Key features
Nested objects become sections
A server object is emitted as a [server] group with its fields as key/value pairs inside.
Configurable separator
Pick an equals sign or a colon to match how the consuming tool reads the file.
Flatter keys for deeper nesting
Deeper nesting is flattened into key names using a path separator instead of endless nested groups.
Familiar format
Produces the INI style used by many Windows and Java applications.
Round-trip friendly
Pairs with the reverse direction to turn an INI file back into JSON.
Local and private
The conversion runs in a Web Worker in your browser; nothing is uploaded.
Common errors & troubleshooting
- ! The root node must be an object; deeper nesting is flattened into keys with a path separator rather than creating unlimited section levels.
- ! INI has no standard type system, so all values are written as text; enable type inference on the way back to restore numbers and booleans.
- ! A key can appear in more than one section; keep the names distinct to avoid confusion when the file is read back.
- ! If a value contains a separator character, check the output before shipping it to make sure the key/value split is what you expect.
Frequently asked questions
What is the difference between INI and .env?
INI groups values under [section] headers, which reads more clearly and is common on Windows and in Java; .env is a flat list of KEY=value pairs, common in front-end and container environments.
Can I convert an INI file back to JSON?
Yes. Switch to the reverse mode on the same page, and optionally enable type inference to restore numbers and booleans.
How are deeply nested objects handled?
Only first-level objects become sections; deeper levels are flattened into key names using a path separator.
Is my data uploaded?
No. The conversion runs locally in your browser; nothing leaves your device.
Related tools
JSON to .env
Convert a JSON object into .env KEY=value pairs, flattening nested fields into dot paths with an optional export prefix and UPPER_SNAKE_CASE keys.
JSON to Properties
Convert JSON to Java .properties key-value config. Nested objects flatten to dotted paths, values are escaped to the java.util.Properties rules, and non-ASCII text is written as UTF-8. Runs locally.
JSON Formatter
Format, beautify and validate JSON in your browser. Errors point to the exact line and column, and you can indent with 2 spaces, 4 spaces or a tab.