BYTETOOLS

JSON Unflattener

Expand flat dot-notation keys back into nested JSON online. Rebuilds objects and arrays from paths like user.address.city or items[0].price, in your browser.

Drop a .json file here or click to browse

What is the JSON Unflattener?

The ByteTools JSON Unflattener takes a flat object whose keys are paths — user. address.

  • Rebuilds nested objects from dot-notation paths
  • Understands both items[0] and items.0 index styles
  • Numeric segments optionally become real arrays
  • Clear errors when two keys describe conflicting shapes
  • Choose the separator and output indentation
  • 100% private — data never leaves your browser

How to use the JSON Unflattener

  1. 1

    Paste a flat JSON object whose keys are dot-notation paths, or drop a .json file.

  2. 2

    Select the separator your keys use and the indentation you want.

  3. 3

    Keep 'Numeric segments become arrays' ticked if paths like items.0 should rebuild arrays.

  4. 4

    Click Unflatten JSON, then copy the nested result or download it.

About the JSON Unflattener

The ByteTools JSON Unflattener takes a flat object whose keys are paths — user.address.city, items[0].price — and rebuilds the nested JSON they describe. Numeric path segments become real arrays, so a flattened list comes back as a list rather than an object with the keys "0" and "1".

It is the inverse of flattening and is handy for turning spreadsheet exports, environment variables, translation files or log fields back into structured documents an API can accept. Choose the separator your keys use, pick your indentation, and get clean nested JSON in one click.

Everything is parsed and rebuilt 100% locally in your browser using JavaScript. Your data is never uploaded or stored, which makes the tool safe for internal configuration and customer records.

Frequently asked questions

How do I convert dot notation keys back into nested JSON?

Paste an object like { "user.name": "Ada" }, choose the dot separator and click Unflatten JSON. Each key is split into path segments and rebuilt as nested objects, so you get { "user": { "name": "Ada" } } back.

Will numeric keys become arrays or objects?

By default a numeric segment such as items.0 creates an array, which is usually what you want. Untick 'Numeric segments become arrays' if your data genuinely uses numeric strings as object keys and you want them preserved.

What happens if two keys conflict?

If one key needs a plain value where another needs a nested object — for example user and user.name together — the tool stops and names the conflicting path instead of silently discarding data.

Does it handle bracket notation like items[0].name?

Yes. Bracket segments are read as array indexes, and quoted brackets such as config["api-key"] are read as literal object keys, so mixed exports from different tools still expand correctly.

Is my data sent to a server?

No. Parsing and rebuilding happen entirely in your browser with JavaScript. Nothing is transmitted or stored, so it is safe for private configuration and confidential records.

Related tools