How to use Flatten JSON
Write a flat JSON object whose keys represent the location of values in a nested source. This is useful when preparing a settings map or inspecting paths in a response.
- Open or paste the JSON, flatten and read the slash-separated keys.
- Verify array index paths and whether the destination expects the same key notation.
Example input
{"title":"Field Notes","inStock":true,"quantity":12,"tags":["paper","stationery"]}Example use
Make a flat lookup of a settings file and inspect configuration values without repeatedly opening nested objects.
Output and compatibility
Keys use JSON Pointer-style escaping for slash and tilde. Empty containers remain leaf values. This output is JSON rather than a two-dimensional table, and parsing can affect very large numeric literals.
Troubleshooting
If a receiver expects dotted keys, map the exported paths deliberately so that literal dots inside property names do not cause ambiguity.
Use JSON to CSV when the destination needs repeating records as rows.
Frequently asked questions
What happens to arrays?
The output can contain paths through numeric array indices.
Does it use dotted paths?
It uses slash-separated JSON Pointer-style paths.