JSON to CSV

Convert a JSON array of objects into a downloadable CSV file, with nested objects flattened.

Input (JSON array)
Loading editor…
CSV Output
Loading editor…
Size: 0 bytesLines: 0

Related Tools

Learn more about the JSON to CSV

What Does This JSON to CSV Converter Do?

This tool turns a JSON array of objects into a downloadable CSV file. Paste a JSON array — an API response, an export, a list of records — or drag and drop a .json file, and each object becomes one row.

Nested objects are flattened into dot-notation columns automatically (an address object becomes address.city, address.zip), and the header row is built from the union of every field found across all objects, so records with slightly different shapes don't break the conversion — a missing field just becomes a blank cell. Output follows RFC 4180, so commas, quotes, and line breaks inside values are escaped correctly and the file opens cleanly in Excel or Google Sheets.

Everything runs locally in your browser; your JSON is never uploaded to a server.

Why Convert JSON to CSV?

Sharing Data with Non-Developers

Stakeholders who live in spreadsheets can’t easily read a JSON API response. Converting it to CSV lets them open, filter, and pivot the data in Excel or Google Sheets.

Exporting Logs and Records

API logs, database exports, and analytics events are usually arrays of similarly-shaped objects — a natural fit for rows and columns once flattened.

Handling Real-World, Uneven Data

Not every record has every field. Missing keys become blank cells instead of breaking the conversion, so partial or inconsistent records still produce a usable file.

Feeding BI and Import Tools

Many spreadsheet, BI, and bulk-import tools only accept flat, tabular CSV — this bridges the gap from nested JSON without writing a script.

Example

Notice how address becomes two flattened columns, the missing address.zip and tags for Alan Turing are left blank, and the comma and quotes in row three are escaped correctly.

Before (JSON)
[
  { "id": 1, "name": "Ada Lovelace", "address": { "city": "London", "zip": "SW1" }, "tags": ["math", "pioneer"] },
  { "id": 2, "name": "Alan Turing", "address": { "city": "Manchester" } },
  { "id": 3, "name": "Grace \"Amazing\" Hopper", "address": { "city": "New York, NY", "zip": "10001" } }
]
After (CSV)
id,name,address.city,address.zip,tags
1,Ada Lovelace,London,SW1,"[""math"",""pioneer""]"
2,Alan Turing,Manchester,,
3,"Grace ""Amazing"" Hopper","New York, NY",10001,

Features

Header Generation

Column headers are built from the union of every field across all objects, in the order they first appear.

Nested Object Flattening

Nested objects become dot-notation columns automatically — address.city, address.zip — instead of an unusable [object Object] cell.

RFC 4180 Escaping

Values containing commas, quotes, or line breaks are quoted and escaped correctly, so the file opens cleanly in Excel or Sheets.

Upload a File

Drag and drop or upload a .json file to convert it directly, no copy-pasting required.

Download CSV

Save the result as a standalone .csv file ready to open or import anywhere.

How to use

Paste your input in the left editor. The output appears automatically on the right. Use the toolbar buttons to copy, download, or transform the result.

  1. Paste or type your content in the input editor on the left.
  2. The formatted output is generated automatically.
  3. Use Copy, Download, or other actions from the output toolbar.
  4. Click the expand icon to view the output in fullscreen.
FAQ

Is this JSON to CSV converter free?

Yes, it is completely free to use with no limits, signup, or account required.

Is my JSON data uploaded to a server?

No. Conversion runs entirely in your browser using JavaScript, whether you paste JSON or upload a file. Your data never leaves your machine.

What kind of JSON can I convert?

The input must be a JSON array of objects, e.g. [{"id":1,"name":"Ada"}, {"id":2,"name":"Alan"}]. Each object becomes one row in the resulting CSV.

How are nested objects handled?

Nested objects are flattened into dot-notation columns automatically. A field like address.city in the CSV header corresponds to the city key inside an address object in the JSON.

What happens to arrays inside an object?

An array value is kept as a single cell, written out as its JSON text (e.g. ["math","pioneer"]), rather than exploded into separate columns.

What if some objects are missing fields that others have?

The header row is built from the union of every field found across all objects. Objects missing a given field simply get a blank cell in that column instead of breaking the conversion.

How does it handle commas and quotes inside values?

The output follows RFC 4180: any value containing a comma, quote, or line break is wrapped in quotes, with internal quotes doubled, so the file opens correctly in Excel or Google Sheets.

Can I upload a file instead of pasting JSON?

Yes. Drag and drop a .json file onto the input panel, or click the upload icon in the panel header to browse for one. Files up to 5MB are supported.

What happens if my JSON is invalid or not an array?

The tool shows a clear error — either a JSON syntax error with details, or a message explaining that the top-level value must be an array of objects.