CSV ↔ JSON converter
Turn a CSV (Excel, database export) into JSON, or a JSON array into CSV. Delimiter detected, quotes handled, file processed in your browser.
- Free
- No sign-up
- No file uploaded
- Windows, Mac, Android, iPhone
Loading the tool…
About this tool
Paste a CSV or open a file: it becomes a JSON array of objects, with column names as keys and numbers detected. The other way round, a JSON array becomes a CSV ready to open in Excel or LibreOffice. Your data stays on your device.
When to use it
Importing a spreadsheet into an app
A list of products, customers or translations entered in Excel exports as CSV; converted to JSON, it can be imported straight into an API, a NoSQL database or a config file.
Opening an API response in Excel
An API returns a JSON array? Convert it to CSV to sort, filter or share it with a team that works in spreadsheets. Nested objects become columns like address.city.
Preparing test data
Writing datasets in a spreadsheet is faster than typing JSON by hand. Convert them to feed automated tests, mock-ups or fixtures.
How to use
- Paste your data or open a file.
- Choose the direction and check the delimiter.
- Copy or download the result.
How it works
Parsing follows RFC 4180: a quoted field can contain the delimiter, line breaks and doubled quotes. The delimiter is guessed by finding the most consistent character over the first lines, which recognises semicolons from European Excel exports, tabs from TSV files, or commas.
With type detection on, 42 becomes a number, true a boolean and null the null value, but a postcode like 01000 stays a string to keep its leading zero. In the other direction, columns are the union of the keys of all objects; a byte-order mark (BOM) is added to the downloaded file so Excel shows accented characters correctly.
Tips for best results
- If Excel shows everything in a single column, pick the semicolon delimiter: that is what Excel expects in many European locales.
- Turn off type detection if your IDs or phone numbers must stay strings.
- Check that the first row really contains column names; otherwise untick the option and you will get arrays.
- For nested JSON, dotted columns (customer.name) are easy to convert back in code.
- For very large files (hundreds of MB), prefer a command-line tool such as csvkit or jq.
Common problems and fixes
All values end up in a single key
The delimiter is wrong: pick it manually (semicolon, tab…).
Accents look garbled in Excel
Use the download button: the file contains a UTF-8 BOM that Excel recognises. Pasting into a .csv file without a BOM may display badly.
“An array is required”
The JSON must be an array [ ... ] of objects or arrays. If your data sits in a property (data, items), paste only that array.
Frequently asked questions
Is my file uploaded?
No. Reading and conversion happen in your browser; the file never leaves your device.
Are fields with commas or line breaks handled?
Yes, if they are quoted as the CSV standard requires. When writing, such fields are quoted automatically.
What happens to nested objects in CSV?
They are flattened into dotted columns (address.city). Arrays are written as JSON in the cell.
Can I convert a TSV file?
Yes, tabs are detected automatically or can be chosen from the delimiter list.
Related searches
Still stuck?
Ask on the forum: the category, the tool, your device sheet and the test result will be filled in for you.