CSV JSON Matrix
Convert CSV to JSON and back, with full RFC 4180 quoted-field support. Your data never leaves your browser.
CSV Input
JSON Output
How CSV ↔ JSON conversion works
CSV looks simple until a field itself contains the delimiter. RFC 4180 solves this by allowing a field to be wrapped in double quotes — inside quotes, commas and even line breaks are just data, and a literal quote is written as two quotes in a row (""):
// CSV
name,note
"Smith, John","He said ""hi"" to me"
// JSON
[
{ "name": "Smith, John", "note": "He said \"hi\" to me" }
]
This tool detects the delimiter (comma, semicolon or tab) from the first line and parses character-by-character rather than splitting on the delimiter — a plain split(',') would cut the "Smith, John" example into two broken fields. Converting JSON back to CSV builds the header row from the union of every object's keys, and re-quotes any field that contains a comma, quote, or line break.
Frequently asked questions
Does it handle commas inside quoted CSV fields?
Yes. Fields wrapped in double quotes can contain commas, line breaks, and escaped "" quotes, per RFC 4180 — a naive comma-split would break on all three.
How is the CSV delimiter detected?
The tool inspects the first line and picks whichever of comma, semicolon, or tab appears most often outside quotes.
What does JSON to CSV do with missing fields?
The header row is the union of every key seen across all objects. Any object missing a key gets an empty cell for it.
Is my data uploaded anywhere?
No. All parsing happens in your browser with plain JavaScript; nothing is sent to a server.