CSV ↔ JSON
Convert between CSV and JSON in either direction, with proper quoting per RFC 4180.
[
{
"name": "Ada",
"role": "engineer",
"active": "true"
},
{
"name": "Lin",
"role": "designer",
"active": "false"
},
{
"name": "Grace",
"role": "manager",
"active": "true"
}
]How to use the CSV / JSON Converter
CSV and JSON are the two most common formats for tabular data, and converting between them by hand is tedious. This tool reads CSV with full RFC 4180 quoting support, turns the first row into JSON keys, and goes the other way just as cleanly \u2014 all in your browser.
- 01Pick a direction using the toggle: csv \u2192 json or json \u2192 csv.
- 02Paste your data into the input panel on the left (or click the toggle to load a sample).
- 03Copy the converted output on the right. Errors \u2014 such as malformed CSV or non-array JSON \u2014 show inline.
tips
- —In CSV, any field containing a comma, quote or newline must be wrapped in double quotes. This tool reads and writes that quoting correctly.
- —When converting JSON to CSV, the column order is the order keys first appear across all objects. If order matters, normalise the key order in your JSON first.
- —Nested objects and arrays are stringified into a single CSV cell. Flatten your data first if you need each nested value in its own column.
frequently asked
How are commas inside a field handled?+
Fields that contain a comma, double quote or newline must be wrapped in double quotes in CSV. Inside a quoted field, a literal double quote is written as two quotes in a row. This tool follows RFC 4180.
What does the first CSV row become?+
The first row is treated as the header. Each following row becomes an object keyed by those headers, so the JSON output is an array of objects.
How does JSON to CSV pick the columns?+
It collects every key from every object in the array and uses the union as the column set, in first-seen order. Missing values become empty cells.
Can it convert nested objects?+
Not in this version. Only flat objects with string, number or boolean values convert cleanly. Nested objects and arrays will be stringified into the cell.