CSV to JSON or JSON to CSV: which direction do you need?
Decide whether to convert CSV rows into JSON objects or flatten JSON back into spreadsheet rows, with examples of each.
Both converters move tabular data between spreadsheet text and JSON, but in opposite directions. This guide shows a sample input for each path so you can match your starting format to the right tool before pasting anything.
Convert CSV to JSON when you start from spreadsheet text
Choose CSV to JSON when your data looks like rows: a header line followed by comma-separated values copied from a sheet or report. The tool treats the first row as field names and returns an array of objects, keeping every value as text so codes like 00123 survive unchanged.
Convert JSON to CSV when you start from structured objects
Choose JSON to CSV when your data already looks like objects — an array of records from an API response or export. The tool collects every key as a column header and writes one row per object, quoting values that contain commas so spreadsheets reopen them correctly.
What stays identical whichever direction you convert
Both tools run entirely in your browser with the same guards: strict header checks, clear first-error messages, and no uploads. Neither invents types or drops columns silently, so a round trip preserves exactly what you pasted.
Tools covered in this guide
- CSV to JSON
Convert CSV rows to a JSON array with header validation.
- JSON to CSV
Flatten a JSON array of objects into spreadsheet-ready CSV.
Frequently asked questions about CSV and JSON conversion
How do I know which format my data is in?
If the first line is a header row with the same separators throughout, it is CSV-like. If it starts with [ or { and has quoted keys, it is JSON. Match that shape to the tool name.
Will my numbers stay numbers after converting?
No — both tools keep every value as text. That preserves leading zeros and long identifiers that automatic typing would corrupt.
Does either converter upload my data?
No. Parsing and conversion run locally in your browser; nothing is sent, stored, or logged by either tool.
More guides
- JSON formatter, tree viewer, or CSV: which one do you need?
- Read, re-delimit, or convert a CSV: which step comes first?
- Basic meta, Open Graph, or Twitter Card: which tags do you need?
- Bold, italic, cursive, or blackletter: which Unicode style?
- Canonical or hreflang: which duplicate problem are you fixing?
- Check, find, or build a palindrome?