JSON to CSV Converter
Paste or drop a JSON array and download a clean, properly-escaped CSV file in one click. No upload, no sign up, no data ever leaves your browser.
How JSON to CSV Conversion Works
- 1Paste or drop your JSON. Type or paste JSON directly into the text area, or drop a
.jsonfile onto the input box to load it automatically. - 2Convert. The tool parses the JSON and builds a CSV string in your browser. Column headers are derived from the keys of the first object in the array.
- 3Preview the output. A preview of the first six rows is shown so you can confirm the columns and values look correct before downloading.
- 4Download. Click “Download CSV” to save the file as
output.csv. Open it in Excel, Google Sheets, or any data tool.
JSON vs CSV: When to Convert
JSON is the native format for most APIs and web services — it handles nested data structures elegantly and is easy to read in code. CSV (Comma-Separated Values) is the lingua franca of spreadsheets and data analysis tools: Excel, Google Sheets, pandas, R, and virtually every business intelligence platform can read CSV natively. Converting JSON to CSV makes API data immediately usable for non-technical stakeholders, reporting workflows, and data analysis pipelines that don't speak JSON.
Tips for Cleaner CSV Output
Flatten nested objects first
If your JSON has nested objects (e.g., address.city), flatten them into top-level keys before converting. Nested structures are stringified in CSV cells, which is rarely what you want in a spreadsheet.
Ensure consistent object keys
Column headers come from the first object's keys. If later objects have extra or missing keys, those columns may have empty cells. Normalize your JSON so every object has the same keys.
Open in Excel with UTF-8
Double-clicking a CSV in Windows Excel may corrupt non-ASCII characters. Use Data → From Text/CSV and select UTF-8 encoding, or open Google Sheets and import the file to preserve all characters correctly.
Strip nulls before converting
JSON null values appear as empty cells in CSV. If you need a specific placeholder (e.g., “N/A”), replace null values in your JSON before converting.
Use for API responses
Copy a JSON response from your browser's DevTools Network tab or a REST client like Insomnia and paste it directly here to export API data as a CSV without writing any code.
Check the row count in the preview
The preview header shows the total row and column count. Verify this matches your expected data before downloading — if rows are missing, the JSON may have a structural issue.
Frequently Asked Questions
Is my JSON data sent to a server?
No. The conversion runs entirely in your browser using pure JavaScript. Your JSON data is parsed and converted locally — nothing is uploaded, stored, or transmitted. This makes it safe to use with sensitive or private data.
What JSON structures are supported?
The converter handles three common structures: (1) an array of objects, where each object becomes a CSV row and the object keys become column headers; (2) a single JSON object, which becomes a single-row CSV; and (3) a flat array of primitive values (strings, numbers, booleans), which becomes a single-column CSV.
What happens with nested objects or arrays inside my JSON?
Nested objects and arrays are converted to their JSON string representation in the CSV cell. For example, a value like {"city":"London"} will appear as the string {"city":"London"} in the CSV. If you need nested data flattened into separate columns, pre-process your JSON to flatten it before converting.
How are special characters handled in the CSV output?
The converter follows RFC 4180. Values that contain commas, double quotes, or newlines are wrapped in double quotes. Any existing double quotes in the value are escaped by doubling them (e.g., He said "hello" becomes "He said ""hello"""). This ensures the CSV opens correctly in Excel, Google Sheets, and any standard CSV reader.
Can I upload a JSON file instead of pasting?
Yes. Drop a .json file onto the input area and its contents will be loaded into the text box automatically. You can then edit it before converting if needed.
What encoding does the output CSV use?
The output CSV is encoded as UTF-8, which is the standard for modern spreadsheet software. UTF-8 preserves international characters (accented letters, Chinese, Arabic, etc.) correctly. When opening the CSV in Excel, use "Data → From Text/CSV" and select UTF-8 encoding to avoid character corruption.
How many rows can the converter handle?
There is no hard limit. The conversion is pure JavaScript running in your browser, so your device's available memory is the only constraint. In practice, JSON files up to tens of megabytes convert instantly. Very large datasets (hundreds of thousands of rows) may take a few seconds and require a modern device with sufficient RAM.