How it works
The Properties to JSON converter transforms Java .properties files into JSON objects — mapping key=value pairs to JSON properties. Use it to migrate Java application configuration to a JSON-based system, to read .properties files in JavaScript applications, or to convert Spring Boot configuration to a format readable in Node.js or Python services.
Java .properties files are the standard configuration format for Java Spring applications, Log4j, Ant build files, and internationalization (i18n) resource bundles. When migrating Java services to cloud-native architectures, API-driven configuration, or polyglot systems, JSON is the more interoperable format.
How to use it: upload a .properties file or paste key=value text. The tool parses the file (handling comment lines starting with # or !, escaped characters, continuation lines with backslash, and Unicode escape sequences \uXXXX) and produces a JSON object. Hierarchical keys (server.port=8080 → {"server":{"port":8080}}) can be optionally nested.
Nested key option: enable Hierarchical Mode to convert dot-separated keys into nested JSON objects: server.port=8080 becomes {"server":{"port":"8080"}}. Disable for flat JSON: {"server.port":"8080"}.
Type inference: numeric values (without quotes in the .properties source) are converted to JSON numbers. true/false are converted to JSON booleans.
Privacy: .properties parsing runs in the browser.
Frequently Asked Questions
- Yes. Values continued on the next line with a trailing backslash (\) are correctly joined into a single value. This is the standard .properties continuation syntax used in large Spring configuration files.
- Comment lines are stripped from the JSON output — they are documentation for the .properties file and have no equivalent in JSON. If you want to preserve comments, toggle 'Include comments as _comment keys' to add comment text as special JSON properties.
- \uXXXX sequences in .properties values are decoded to their actual Unicode characters in the JSON output — \u00e9 becomes é. This matches the Java PropertyResourceBundle behavior at runtime.
- In Hierarchical Mode, a key like server.database.host=localhost is converted to {"server":{"database":{"host":"localhost"}}}. In Flat Mode, it becomes {"server.database.host":"localhost"}. Use Hierarchical Mode for configuration files that mirror Spring Boot's relaxed binding, Flat Mode for systems that use literal dot-key lookups.