Report

Help us improve this tool

Convert Properties to JSON

Convert flat Java or INI-style .properties files back into structured, nested JSON objects recursively.

O M T

Convert Properties to JSON - Unflatten Configurations Online

Welcome to the online **Properties to JSON** converter. This powerful configuration parsing utility lets you instantly transform flat Java, Spring Boot, or INI-style .properties variables back into beautiful, recursively nested, highly structured JSON objects.

Why Convert Properties to JSON?

While .properties files are lightweight and convenient for simple deployments, they suffer from lack of native support for nested hierarchies, typed structures, and arrays. Modifying deep objects in properties files requires long, repetitive dotted paths (e.g. server.connection.timeout.retry = 5). Converting these settings to **JSON** structures unlocks full compatibility with modern web applications, document databases, and REST APIs, while restoring clean, readable nesting.

Key Features of the Properties to JSON Converter

  • Intelligent Tree Reconstruction: Flat key paths separated by dots are parsed recursively to reconstruct nested JSON object layers.
  • Robust Array Detection: Decodes both bracket-notation arrays (list[0] = value) and dotted-notation lists (list.0 = value) into fully compliant JSON lists automatically.
  • Coerces Primitive Types: String representations of booleans (true, false) and numbers are automatically converted into real JSON boolean and number data types, rather than plain strings.
  • Comment and Whitespace Ignoring: Safely skips comments starting with hash # or exclamation ! and trims whitespace, ensuring only valid configurations are parsed.
  • Escaped Character Decoding: Automatically decodes properties escaping sequences (like \=, \:, and double backslashes) to represent key-values exactly as they should be parsed.

How to Convert Your Properties Configuration

  1. Input Properties: Paste your flat .properties keys inside the left editor. Click **Sample** to load a standard Spring Boot application profile.
  2. Adjust Array Parsing: Toggle "Auto-detect Numeric Arrays" to enable or disable converting sequential numeric paths into list nodes.
  3. Select Formatting: Set the indentation preference for the output editor (2 or 4 spaces) or minify it for high-density payloads.
  4. Copy and Save: Easily copy the structured output to your clipboard or download it as a standalone config.json file.

For the reverse operation, check Convert JSON to Properties and Flatten JSON Object.

Frequently Asked Questions

How does the converter identify a JSON array?

The tool scans property keys for standard list formats. If it finds keys matching bracket index formats like `keys[0]`, `keys[1]` or numeric dotted paths like `keys.0`, `keys.1`, it combines these nodes into a single JSON array list in sequential index order.

Will properties file comments be preserved?

Lines starting with `#` or `!` are treated as metadata and are skipped to generate a clean, comment-free JSON document that complies with the standard JSON specifications (which do not support comments).

Are numbers and booleans kept as strings?

No. Our converter automatically detects standard representations of numbers (integers and floats) and booleans (`true` and `false`) and converts them into actual JSON numeric and boolean data types, preserving their native typing.

Is there a server execution risk with my properties files?

None. The conversion engine runs entirely on client-side JavaScript within your local web browser. Your credentials, host URLs, and sensitive application properties are never transferred outside your computer, ensuring absolute privacy.