How to flatten json for csv export
- Step 1Paste the nested JSON array — Paste a JSON array of objects where some objects have nested sub-objects. The flattener processes each element in the array independently.
- Step 2Select underscore separator for CSV column names — Use '_' as the separator to produce CSV-friendly column names like user_name and address_city. Dot notation works in pandas and BigQuery but may require quoting in Excel.
- Step 3Set a depth limit if needed — If the structure is very deeply nested (5+ levels), set a max depth of 2–3 to flatten the most important levels and preserve the deepest sub-objects as JSON strings in their own column.
- Step 4Pass the flattened JSON to the CSV converter — Copy the flattened JSON array and paste it into the JSON to CSV converter tool. Every flattened key now maps cleanly to a CSV column header with a scalar value.
Frequently asked questions
What happens to array values during flattening?+
Arrays of primitive values are serialized as a comma-separated string in a single CSV cell by default (e.g. [1,2,3] →’ '1,2,3'). Arrays of objects are serialized as a JSON string. If you need array elements as separate CSV rows, use the CSV Row Splitter tool on the exported CSV after conversion.
My JSON has 10 levels of nesting. Should I flatten all of it?+
For CSV export, flatten only the levels that contain meaningful scalar values (strings, numbers, dates). Deep nesting beyond 3–4 levels usually means the data is a sub-entity better represented as a separate CSV file with a foreign key. Use a depth limit of 2 and handle deeper structures as separate exports.
Is the nested API response data transmitted to JAD Apps?+
No. The JSON flattening runs entirely in your browser. API responses, customer data, and any nested objects are never sent to JAD Apps servers.
Privacy first
Conversion runs locally in your browser. No file is uploaded — only metadata counters are saved for signed-in dashboard stats.