tool

JSON ↔ CSV Converter

Convert JSON to CSV or CSV to JSON directly in your browser. Your data never leaves your device.

JSONCSV
Input · JSON
0 chars
1
Output · CSV
1
●Your data stays in your browser. Nothing is uploaded or stored.

Convert JSON to CSV and CSV to JSON

Turn an array of JSON objects into a CSV table you can open in Excel, Google Sheets or Numbers, or turn a CSV export back into JSON for an API, a seed file or a test fixture. Column headers are detected automatically, values that contain commas, quotes or line breaks are quoted correctly, and the conversion updates as you type. It all runs in your browser, so customer lists and exports stay on your device.

What can you do?

  1. 1. JSON to CSV
    Paste an array of objects. Every key found in any object becomes a column, in the order it first appears, so records with different fields still line up.
  2. 2. CSV to JSON
    Switch direction, paste CSV with a header row and get an array of objects where each header becomes a property name.
  3. 3. Comma, semicolon or tab delimiters
    Read CSV that uses commas, semicolons (common in European Excel exports) or tabs (what you get when copying cells from a spreadsheet).
  4. 4. Nested data kept intact
    Nested objects and arrays are written into a single CSV cell as JSON text instead of being dropped, so no information is lost.
  5. 5. Private by design
    Your data is converted in the browser and isn't uploaded to a Buggerspot server or stored in a database.

Why convert between JSON and CSV?

APIs, NoSQL databases and JavaScript apps speak JSON, while spreadsheets, CRMs, accounting software and most import screens expect CSV. Moving data between the two is a routine task: exporting API results for a manager who lives in Excel, importing a client's spreadsheet into an app, or preparing seed data for a database.

Writing a one-off script for each conversion takes longer than the job deserves. A converter handles the fiddly parts, such as quoting, escaping, missing fields and header detection, consistently every time.

How to convert JSON to CSV

  1. 1. Make sure your JSON is an array of objects
    The input should look like [{"name": "…"}, {"name": "…"}]. If you have a single object, wrap it in square brackets. If the array is nested inside a property such as data or results, paste just that array.
  2. 2. Paste it into the input
    The CSV output appears immediately, with a header row built from the object keys.
  3. 3. Copy the CSV
    Copy the result and paste it into a spreadsheet, or into a text file saved with a .csv extension.

Example: JSON with missing fields and nested data

Records don't need identical keys. Missing values become empty cells, and nested values are stored as JSON text inside the cell.

JSONJSON input
[
  { "id": 1, "name": "Arun", "city": "Madurai", "skills": ["React", "Node"] },
  { "id": 2, "name": "Meena, K", "email": "meena@example.com", "address": { "city": "Coimbatore" } }
]
CSVCSV output
id,name,city,skills,email,address
1,Arun,Madurai,"[""React"",""Node""]",,
2,"Meena, K",,,meena@example.com,"{""city"":""Coimbatore""}"

Notice that "Meena, K" is wrapped in quotes because it contains a comma, and the double quotes inside the nested values are doubled. That is the standard CSV escaping rule, and spreadsheet apps read it back correctly.

How JSON values are written to CSV

Mapping of JSON value types to CSV cell output
JSON valueCSV cellExample
StringThe text as-is, quoted if neededChennai
Number or booleanWritten as text42, true
null or missing keyEmpty cell,,
Nested objectJSON text inside one cell"{""city"":""Salem""}"
ArrayJSON text inside one cell"[""a"",""b""]"
Text with a comma, quote or line breakWrapped in double quotes, inner quotes doubled"Says ""hi"""

Which CSV delimiter should you choose?

The delimiter setting tells the converter how to split each CSV row when converting CSV to JSON. JSON to CSV output always uses commas.

When to use comma, semicolon or tab delimiters
DelimiterTypical sourceNotes
Comma (,)Most exports, Google Sheets, databases, APIsThe default and most widely supported choice.
Semicolon (;)Excel in regions that use a comma as the decimal separator (much of Europe)If every row ends up in a single column, try semicolon.
TabCells copied directly from Excel or Google Sheets, .tsv filesSelect a range in your spreadsheet, copy, paste it here and choose tab.

Converting CSV to JSON: what to expect

The first row is used as the property names, so it must not contain empty or duplicate column names. Quoted fields can contain the delimiter, escaped quotes ("") and even line breaks. Blank lines are skipped, missing cells at the end of a row become empty strings, and cells beyond the number of headers are ignored.

Every value is returned as a string. CSV has no data types, so 28 and true become "28" and "true" rather than a number and a boolean. This avoids silently changing values like ZIP codes, phone numbers or IDs with leading zeros. Convert specific fields in your own code if you need numbers.

Frequently asked questions

Why does it say my JSON must be an array of objects?

CSV is a table, so each row has to come from an object. A single object, an array of plain values or a wrapper object like { "data": [...] } can't be mapped to rows. Wrap a single object in [ ] or paste only the inner array.

Can I flatten nested JSON into separate columns?

Nested objects and arrays are kept as JSON text in one cell so nothing is lost. If you need columns like address.city, flatten the objects before converting.

How do I open the CSV in Excel?

Copy the output, paste it into a plain text file and save it with a .csv extension, then open it in Excel. You can also paste it straight into Google Sheets and use Split text to columns.

Is there a size limit?

There's no fixed limit, but conversion happens in your browser tab, so very large files (many megabytes) may feel slow. For huge exports, a script or database tool is a better fit.

Is my data uploaded?

No. The conversion runs entirely in your browser and the data is never sent to a server.

Getting “invalid JSON”? Clean it up first with the JSON formatter and validator.