JSON to CSV
Convert JSON arrays to CSV format for spreadsheet import, with a live preview that updates automatically as you type. Two previously-confirmed bugs are now fixed: the destructive "Convert" button (which used to overwrite your JSON input with the CSV output, with no undo) has been removed entirely since the live preview already covers its function, and array values — including arrays of objects — are now genuinely preserved as real JSON text in the CSV cell instead of collapsing to the useless placeholder "[object Object]".
How to Use This Tool
Paste your JSON array into the input textarea
the CSV table and raw output below update automatically as you type.
Select the delimiter (comma, tab, or semicolon).
Select the delimiter (comma, tab, or semicolon).
Pro Tip
Before converting a large JSON array with inconsistent object shapes, check whether every object actually has the same keys — if some objects are missing fields that others have, a naive converter can silently misalign columns row to row; this tool avoids that by scanning the entire array first to build a unified superset of column headers, then backfilling empty cells for objects missing a given key. Array-valued fields no longer need to be flattened or summarized before converting — they're now preserved as real, recoverable JSON text directly in their cell.
About This Tool
When to Use
- A data analyst, Bogdan, converts a 2,000-row JSON API export of customer orders into CSV so he can pivot-table it in Excel for a quarterly sales report
- A marketing coordinator, Suri, converts JSON survey response data from a form tool into CSV to import into Google Sheets for manual tagging.
- A backend developer, Achilles, converts a JSON array of user records into CSV to hand off to a non-technical stakeholder, trusting an array-valued "roles" field to survive the conversion as real, recoverable JSON text in its cell rather than needing to manually restructure it first.
Key Details
A JSON to CSV converter flattens an array of JSON objects into comma-separated tabular rows, using each unique object key as a column header and handling nested objects by flattening them with dot-not...
Worked example
Bogdan pastes an array of 3 order objects, each with keys order_id, customer.name, total, and a line_items array of objects. The moment he pastes, the tool flattens the nested customer.name key into a single column header 'customer.name', reconciles that all three objects share the same keys, and the table and raw CSV below already show the finished result — header row 'order_id,customer.name,total,line_items' followed by three data rows, with the line_items column containing each order's real JSON array text (quoted per CSV rules) rather than the placeholder text [object Object]. He copies the CSV directly from the live preview.
Interpreting your result
A successful conversion shows a green "Converted" badge with the row and column counts, a preview table, and the raw CSV text below — all generated the moment valid JSON is pasted, with no button click required (the button has been removed). If a column containing an original array value shows real bracketed JSON text like ["a","b","c"] rather than the old [object Object] placeholder, that's the fix working correctly — that text can be parsed back with JSON.parse() to recover the original array.
JSON to CSV FAQ
What JSON structures can be converted to CSV?
This tool converts JSON arrays of objects. Each object becomes a row, and the column headers are the union of every key used across every object in the array — confirmed by tracing the code, this is a full superset of keys, not just whatever the first object happens to have. Nested objects are flattened into dot-notation columns. Arrays within values are now genuinely preserved as JSON text in their cell (see the dedicated question below).
How are nested JSON objects handled?
Nested objects are flattened using dot notation. For example, {"user": {"name": "John", "age": 30}} becomes columns "user.name" and "user.age". This makes complex JSON structures compatible with CSV's flat format, and was verified to work correctly across multiple nesting levels.
What delimiter options are available?
You can choose comma (,), tab, or semicolon (;) as the delimiter. Comma is standard but can conflict with data values. Tab and semicolon are useful when your data contains commas (e.g., addresses like "123 Main St, Apt 4").
How are special characters in values handled?
Values containing the delimiter, double quotes, or newlines are wrapped in double quotes. A double quote inside a value is escaped by doubling it — one " character becomes two ("") in the output. All output is valid CSV per RFC 4180, confirmed by tracing the escaping function directly.
Is there still a "Convert" button I need to click?
No — it's been removed. The CSV table and raw CSV text below the input have always updated automatically the moment you paste or type, which made the button both unnecessary and, previously, actively destructive: clicking it used to overwrite your JSON input with the CSV output text, with no undo. That behavior is now fixed by removing the button entirely — just paste your JSON, pick a delimiter, and copy or download directly from the live preview.
How are arrays within JSON objects handled in the CSV output?
Correctly now, and genuinely recoverable. Arrays are JSON-stringified into the cell rather than left to plain string coercion — an array of plain values like ["a","b","c"] appears as the literal bracketed text ["a","b","c"] in the cell (quoted per CSV rules since it contains commas and quotes), and an array of objects — like a list of line items or addresses — appears as its real JSON representation, fully recoverable by parsing that cell's text back with JSON.parse(), instead of the previous [object Object] placeholder that discarded the data entirely.
Master Your Entire Toolkit
Access 500+ specialized calculators and tools designed for precision. No sign-up required, 100% free.
Built and reviewed by the Toolzip Team · Based on RFC 4180 — CSV Format