← All text tools

JSON and Java Properties Converter

Convert JSON to a Java .properties file with dotted keys and convert properties files back to nested JSON, with array keys like items[0].

  • Free
  • No sign-up
  • Works on any device

About JSON and Java Properties Converter

Java applications and Spring Boot store settings in .properties files, where nested values are written as dotted keys, while many tools use JSON. This converter flattens JSON into server.host=localhost lines, using items[0] or items.0 for arrays, and rebuilds nested JSON from a properties file. It follows the rules of java.util.Properties: # and ! comments, equals, colon or space between key and value, backslash line continuations, and \uXXXX escapes, which you can switch on for non-ASCII letters. Numbers, true, false and null can be turned back into JSON types when reading properties.

How to use JSON and Java Properties Converter

  1. Choose JSON to properties or properties to JSON and paste your input.
  2. Set the separator, the array key style and the escape and type options.
  3. Copy the result, or fix the message about a key that is both a value and a parent.

Why use this tool?

Also known as

Frequently asked questions

How are arrays written in a properties file?

With a position in square brackets, such as tags[0]=a and tags[1]=b. You can switch to tags.0 style, and when reading back, keys numbered 0, 1, 2 can be turned into an array.

Why does my accented text come out as \u00E9?

Classic Java properties files are read as ISO-8859-1, so other characters are written as unicode escapes. Turn the option off if your application reads the file as UTF-8.

What happens to empty objects or null values?

They become a key with an empty value, because a properties file cannot say empty object or null. Reading it back gives an empty string, so those cannot round-trip exactly.

Is JSON and Java Properties Converter free?

Yes. JSON and Java Properties Converter on Toolipedia is free to use, with no sign-up and no watermark.

Is it safe to use?

Yes. Everything is worked out in your browser, and nothing you enter is sent to our server.

Does it work on my phone?

Yes. It works in any modern browser on Android and iPhone, as well as on tablets and computers. There's nothing to install.

Do I need an account?

No. Just open the page and use the tool. There's no sign-up and no email needed.

Can I put JSON and Java Properties Converter on my own website?

Yes. Use the Embed on your site button under the tool to copy a short piece of code and paste it into your page. It is free, needs no account, and the tool keeps working inside your page.

Related tools