About this tool
Test data often lives in spreadsheets, but test code wants JSON. This converter implements RFC 4180 properly: quoted fields, doubled quotes inside quotes, delimiters and line breaks inside quoted values, and CRLF or LF line endings. It detects comma, semicolon, tab and pipe delimiters (European Excel exports usually use semicolons), turns the header row into object keys, and can infer numbers, booleans and null. Values with leading zeros, such as ZIP codes and account numbers, stay strings so they are not silently corrupted.
How to use it
- Paste CSV, or click “Load sample” for a file with quoted commas, escaped quotes and a multi-line value.
- Leave the delimiter on Auto-detect or choose one explicitly.
- Untick “First row is header” to get arrays instead of objects, and untick type inference to keep every value as a string.
- Check the status bar for ragged rows, then copy or download the JSON.
CSV to JSON Converter FAQ
Why did 007 or a ZIP code stay a string?
Numbers with leading zeros are kept as strings on purpose, because converting them would change the value (02139 would become 2139). Integers too large to represent exactly in JavaScript are also kept as strings.
What happens with rows that have too many or too few fields?
Missing fields become null and extra fields are added as column_N keys. The converter lists every ragged row by line so you can fix the source rather than shipping a shifted column into your test.
Does it handle Excel exports?
Yes, including the UTF-8 byte order mark Excel adds and semicolon delimiters from locales that use a decimal comma. Decimal commas inside values (1,5) are not converted to numbers.