JSON Flatten / Unflatten

JSON Flatten / Unflatten

Local Processing

Flatten nested JSON into dot paths or rebuild nesting from dot paths.

How It Works & Processing Standards

Flatten nested JSON into dot paths or rebuild nesting from dot paths.

Tool processing runs in your browser. If you create a calculator or conversion share link, its values are included in the URL. See the privacy policy for account, analytics and advertising data.

Current Limits

  • Desktop max file size: 50MB
  • Mobile max file size: 20MB

Choose flatten or unflatten under "Task". Useful for moving data into tables or CSV, or matching one-level key formats such as i18n files and environment variables. The separator is configurable.

What You Can Do

Flatten
Spreads nested objects into dotted path keys.
Unflatten
Rebuilds nested objects from dotted keys.

How to Use JSON Flatten / Unflatten

  1. 1
    Choose a taskFlatten or unflatten.
  2. 2
    Enter JSON and separatorPaste JSON and set the separator (default .).
  3. 3
    CopyCopy the result.

Examples

Flatten
Input: {"user":{"name":"민수","address":{"city":"서울"}}}
Result: { "user.name": "민수", "user.address.city": "서울" }
Unflatten
Input: {"a.b":1,"a.c":2}
Result: { "a": { "b": 1, "c": 2 } }

Common Use Cases

  • Before spreading nested JSON into CSV columns
  • Restructuring keys in i18n translation files

Frequently Asked Questions (FAQ)

What if keys contain dots?

Dots are read as path separators when unflattening. Use another separator such as / if keys contain dots.

Have feedback or ideas for this tool? Suggest & Inquire →