Turn a JSON array into spreadsheet-ready CSV. Headers inferred from your keys. 100% in your browser.

Input — JSON
Output — CSV
Ctrl+Shift+CCopyCtrl+KClear

Share this tool

Found it useful? Help a fellow developer discover it.

https://developertoolkit.dev/tools/json-to-csv

Convert in the other direction

Going the other way, parsing a spreadsheet export into a JSON array?

Convert CSV to JSON

Open CSV to JSON Converter

Why convert JSON to CSV?

JSON is what your API returns. CSV is what the person asking for the data actually wants. That gap shows up constantly: an analyst needs last month's orders in a spreadsheet, a finance team wants the export as an attachment, a migration script expects a flat file, or you simply want to eyeball 500 records in columns instead of scrolling through nested braces. Converting means flattening a tree into a grid, which requires deciding what the columns are and what to do with nested values. This tool infers the column set from the keys across your records, so a field missing from some objects still gets a column with empty cells rather than silently shifting your rows out of alignment.

What happens to your JSON structure

Converts cleanly

  • ·Arrays of flat objects, the standard API list response
  • ·Keys that vary between records, unioned into one header row
  • ·Strings containing commas, quotes, or newlines, escaped per RFC 4180
  • ·Numbers, booleans, and null values

Needs a decision from you

  • ·Nested objects, written into the cell as JSON rather than split into columns
  • ·Arrays inside a record, such as a list of tags, also written as JSON
  • ·An array of plain values, which has no columns and is rejected with a message
  • ·Very wide records, where the CSV becomes hard to read

How to convert JSON to CSV

  1. Paste a JSON array. The input should be an array of objects, which is the shape almost every API returns for a list endpoint. This page opens in the JSON to CSV direction already.
  2. Check the inferred headers. The first output row is the column set, built from the keys found across your records.
  3. Scan for the nested-value notice. If any record contains a nested object or array, the tool says so, because those are written as JSON inside a single cell rather than becoming columns of their own.
  4. Download the .csv. Save it and open it directly in Excel, Numbers, or Google Sheets.

Frequently Asked Questions

How do I convert JSON to CSV online?

Paste a JSON array of objects into the left panel. This page opens already set to the JSON to CSV direction, so the CSV appears on the right immediately with a header row inferred from your keys. Download it as a .csv file and open it in any spreadsheet application.

What JSON shape does the converter expect?

An array of objects, for example [{"id": 1, "name": "Ada"}, {"id": 2, "name": "Grace"}]. That is what a REST list endpoint returns and it maps directly onto rows and columns. A single object produces a single data row. A bare array of primitives produces a single column.

What happens to nested objects and arrays?

A grid holds one value per cell, so nested structures have no exact CSV equivalent. The converter writes them into the cell as JSON, for example {"a":1}, so the data survives the round trip and can be parsed back out. The tool flags this with a notice when it happens. If you need nested fields as real columns, flatten the JSON first so every leaf value has its own top-level key.

Why do some of my records have empty cells?

The header row is the union of every key across all records, so a field present in only some objects still gets its own column. Records missing that field get an empty cell. This is deliberate: the alternative would be rows with differing column counts, which most spreadsheet parsers reject.

Can I change the delimiter when converting JSON to CSV?

Output in this direction is always comma-separated, which is what Excel, Numbers and Google Sheets expect by default. The delimiter selector applies to the CSV to JSON direction, where the delimiter of the file you paste has to be detected. If your spreadsheet locale expects semicolons, a find and replace after download is the quickest fix.

Will the CSV open correctly in Excel?

Yes for standard comma-separated output. Two things to watch for, neither specific to this tool: Excel in some European locales expects a semicolon delimiter, and Excel will reformat values that look like dates or long numeric IDs on import. For IDs, importing via Data then From Text and marking the column as text avoids the reformatting.

How do I convert CSV back to JSON?

Use the Swap button to flip direction in place, or open the CSV to JSON converter, which is a separate page covering that direction with its own guidance on headers, delimiters and type inference.

Is my data uploaded anywhere?

No. The conversion runs entirely in your browser with client-side JavaScript. Nothing is transmitted, stored, or logged, which means production exports containing customer data are safe to paste here.

Related Tools