CSV to JSON
CSV ⇄ JSONConvert CSV to JSON and back, quoted fields and all.
Result appears hereQuoted fields containing the delimiter, doubled quotes, and newlines inside a field are all handled. Values that look like numbers or booleans become real JSON types, except where a leading zero suggests a code rather than a number — so 01234 stays a string.
About CSV to JSON
Convert a CSV export into JSON, or an array of JSON objects back into CSV. The delimiter is detected automatically — comma, semicolon, tab or pipe — and can be overridden when the guess is wrong.
The parsing is done with a proper state machine rather than by splitting on commas, which matters the moment real data arrives. A quoted field containing a comma, a doubled quote standing for a literal one, a newline inside a single field, Windows line endings: all of these appear constantly in spreadsheet exports, and all of them turn a naive split into silent nonsense rather than a visible error.
Values that look like numbers or booleans become real JSON types, with one deliberate exception: anything with a leading zero stays a string, because 01234 is a postcode or an account number far more often than it is the number 1234. Going the other way, the columns are the union of keys across every record, so a field missing from the first row still gets a column.
Common questions
This page does the work itself, in this tab. Nothing you paste is sent to a server. Close the tab and no copy remains.