A zip code
- Input
- zip 007
- Output
- [{"zip":"007"}]
Converting this to the number 7 would lose the leading zeros permanently. Any value that would not print back identically is kept as text.
This tool turns a CSV file into JSON. The parsing handles the cases that break naive splitting — a comma inside a quoted field, a doubled quote, a newline within a value. The type conversion is where most converters do damage: turning 007 into the number 7 destroys a zip code, a phone number or a part code, so values that would not survive the round trip are kept as text.
Runs entirely in your browser — nothing you paste is uploaded.
How to
Drop in a .csv file or paste the text. The delimiter is detected automatically, and can be overridden if the guess is wrong.
With a header, each row becomes an object keyed by column name. Without one, columns are named column_1 upwards.
Numbers and booleans can be converted from text. Values with leading zeros are always left as strings, since converting them loses information.
Copy the result or download it. Any rows the parser could not read cleanly are reported with their line numbers.
Examples
Converting this to the number 7 would lose the leading zeros permanently. Any value that would not print back identically is kept as text.
Splitting on commas would produce three fields and misalign the row. Proper CSV parsing treats the quoted section as one value.
Two columns with the same name would overwrite each other in an object. The second is renamed so no data is lost.
Why use it
Zip codes, phone numbers and part codes with leading zeros stay as text rather than being silently converted to numbers.
Quoted fields, doubled quotes and newlines inside values are all handled, which is where hand-rolled splitting always fails.
Blank and duplicate headers are given usable unique names instead of collapsing into one another.
Spreadsheet exports are usually real records. Nothing is uploaded.
Good to know
Summary
FAQ
Discover