Properties to JSON Converter

Convert a Java .properties file to JSON and JSON back to .properties, right in your browser. Your config never leaves your device.

Java Properties ↔ JSON runs entirely in your browser. The .properties files and JSON you paste never leave your device and nothing is uploaded to ArrayKit.

Open the dotenv to JSON Converter

About Java Properties ↔ JSON

Java Properties ↔ JSON reads a Java .properties file — the key=value config format used by Spring, Maven, and countless JVM apps — and turns it into a clean JSON object you can drop into a modern config pipeline. It skips blank lines and '#' or '!' comments, joins backslash line continuations, and decodes \uXXXX and \n \t \\ escapes inside values. Turn on 'Expand dotted keys' and dotted keys like db.host automatically nest into a db: { host } object; turn it off to keep dotted keys flat. Flip the direction to go the other way and a JSON object becomes valid .properties text, with nested objects flattened back into dotted keys and special characters escaped. It is built for Java and Spring developers migrating config between legacy properties files and JSON-based tooling. Everything runs locally — your configuration never leaves the browser.

Features

How to use the Java Properties ↔ JSON

  1. Keep 'Properties → JSON' selected and paste your .properties file
  2. Toggle 'Expand dotted keys (nested)' on or off as needed
  3. Copy the JSON output or download it as config.json
  4. Switch to 'JSON → Properties' to reverse the conversion

Example

Input

db.host=localhost
db.port=5432

Output

{
  "db": {
    "host": "localhost",
    "port": "5432"
  }
}

Dotted keys like db.host expand into a nested db object when nesting is on.

Common errors & troubleshooting

Frequently asked questions

What does the Java Properties ↔ JSON converter do with dotted keys?
With 'Expand dotted keys (nested)' on, a key like db.host=localhost becomes { "db": { "host": "localhost" } }. Turn the toggle off to keep the literal key "db.host" as a single flat property instead.
Does the Properties to JSON converter support \uXXXX unicode escapes?
Yes. Values containing \uXXXX sequences (the standard way Java's Properties format encodes non-ASCII text) are decoded to the actual character, along with \n, \t, and \\ escapes.
Can I use ':' or whitespace instead of '=' in my .properties file?
Yes. The parser accepts key=value, key:value, and key value (separated by whitespace), matching how Java's Properties.load() reads all three separator styles.
How does JSON to Properties handle nested JSON objects?
Nested objects are flattened into dotted keys, so { "db": { "host": "x" } } becomes db.host=x. Arrays and other non-object values are converted to their string representation.
Does this tool ignore comments in a .properties file?
Yes. Lines starting with '#' or '!' are treated as comments and skipped, matching the two comment markers Java's Properties format recognizes.
Is my .properties file or JSON config uploaded anywhere?
No. Java Properties ↔ JSON runs entirely in your browser. The .properties text and JSON you paste never leave your device and are not sent to ArrayKit or any server.

Related tools

All ArrayKit tools