How to convert JSON to CSV

You have JSON (an API response, an export, a config) and you need it in a spreadsheet. This guide shows the JSON shape that converts cleanly, what happens to nested data, quotes and line breaks, and how to convert in your browser without sending the data anywhere.

Need it done now? Paste the JSON, press Convert, copy or download the CSV.

A JSON array of objects in · CSV, semicolon-separated or TSV out · nothing uploaded

Open JSON to CSV →

At a glance

InputPasted JSON: an array of objects, or a single object (one row).
ColumnsEvery key found in any object, in the order first seen. A missing key leaves an empty cell.
Nested valuesWritten into the cell as compact JSON text. They are not split into extra columns.
OutputComma, semicolon or tab separated text, with quotes added where a value needs them. Copy it or download data.csv (UTF-8).
SizeNo row limit is set; very large pastes are limited by your browser's memory. Excel itself stops at 1,048,576 rows.

The structure that converts cleanly

CSV is a flat grid, so the ideal input is an array of flat objects: each object is a row, each key a column. Keep the keys consistent across objects for a tidy table.

Worked example: three orders with awkward values

Repeat it with our sample file: sample-orders.json (invented orders). It has a comma inside a name, quotes inside a name, an accented letter, a nested object, an array, a line break and keys that only some orders have:

[
  {
    "order_id": "A-1001",
    "customer": "Rivera, Sam",
    "items": 2,
    "total": 38.5,
    "shipped": true,
    "address": { "city": "Leeds", "country": "GB" }
  },
  {
    "order_id": "A-1002",
    "customer": "Noor \"Nina\" Haddad",
    "items": 1,
    "total": 12,
    "shipped": false,
    "tags": ["gift", "express"]
  },
  {
    "order_id": "A-1003",
    "customer": "Zoë Lindqvist",
    "items": 5,
    "total": 104.25,
    "shipped": true,
    "note": "Leave at the\nside door"
  }
]

Pasted into JSON to CSV with the comma delimiter, it gives Converted 3 rows to CSV. and this output:

order_id,customer,items,total,shipped,address,tags,note
A-1001,"Rivera, Sam",2,38.5,true,"{""city"":""Leeds"",""country"":""GB""}",,
A-1002,"Noor ""Nina"" Haddad",1,12,false,,"[""gift"",""express""]",
A-1003,Zoë Lindqvist,5,104.25,true,,,"Leave at the
side door"
  • Columns come from every key: tags and note appear even though only one order has each.
  • “Rivera, Sam” is wrapped in quotes because it contains a comma.
  • Inner quotes are doubled (""Nina""), the standard CSV escape.
  • The nested address and the tags array stay as JSON text in one cell.
  • The line break in the note is kept inside a quoted cell, so the row continues on the next line.
JSON to CSV after converting the sample orders: the JSON input on the left and the CSV output with a header row and three orders on the right.
The sample in JSON to CSV. Screenshot of the real tool, 30 October 2026.

Try it with the sample orders →

If it doesn't work

What you seeWhyWhat to do
“Invalid JSON: …” with a line and columnThe text is not valid JSON. With one comma removed from the sample, Chrome reports Invalid JSON: Expected ',' or '}' after property value in JSON at position 265 (line 14 column 5). Other browsers word it differently.Fix the spot it points to; the JSON Formatter shows errors in context.
Could not convert: expected an array of objects — no object keys found.The array holds plain values, like [1, 2, 3], so there are no columns.Wrap each value in an object, for example {"value": 1}.
Accented letters look wrong in ExcelExcel may not read the file as UTF-8 when you double-click it.Use Data › From Text/CSV and choose UTF-8, or open it in Google Sheets.
Everything lands in one columnYour spreadsheet expects a different separator (common where the comma is a decimal mark).Convert again with Semicolon, or use Tab and paste.
A cell shows JSON like {"city":…}That value was nested.Move the values you need to the top level of each object, then convert.

A value that starts with =, +, - or @ may be treated as a formula when a spreadsheet opens the file. The tool writes values as they are, so check data from untrusted sources before opening it.

Going the other way

A spreadsheet export back into JSON for code is just as quick with CSV to JSON, and CSV to Excel makes a native .xlsx file.

A note on privacy

Datasets often contain customer or internal data. JSON to CSV parses and converts entirely in your browser, so nothing you paste is ever uploaded to a server.

Open the JSON to CSV tool →

Common questions

What JSON structure converts cleanly to CSV?

An array of flat objects, where each object becomes a row and its keys become the columns — for example [{"name":"Ann","age":30},{"name":"Bo","age":25}]. Every object should share the same keys for a tidy table; missing keys become empty cells.

How are nested objects and arrays handled?

CSV is flat, so this tool writes a nested object or array into its cell as compact JSON text, for example {"city":"Leeds"}. It does not invent columns such as address.city. If you want separate columns, move those values to the top level of each object before converting.

Will the CSV open in Excel and Google Sheets?

Yes, CSV opens in Excel, Google Sheets and Numbers. If accented letters look wrong in Excel, import the file with Data › From Text/CSV and choose UTF-8 instead of double-clicking it. If you need a native .xlsx file, use CSV to Excel.

Is my data uploaded when I convert it?

No. The JSON is parsed and the CSV is generated entirely in your browser, so customer records, exports, and internal datasets never leave your device.