Why convert CSV to JSON?
Spreadsheets and databases export data as CSV, while web applications, APIs and JavaScript code work with JSON. Converting lets you load a product list, a contact list or survey results straight into a website, a chart library or a test script. This converter reads real-world CSV correctly, including values that contain commas, quotes and line breaks.
How to use the converter
- Paste CSV text. You can also copy cells directly from Excel or Google Sheets; they are pasted as tab-separated data, which is detected automatically.
- Keep First row is headers ticked to get an array of objects using the header names as keys. Untick it to get an array of arrays.
- Keep Convert numbers and true/false ticked so
55000becomes a number andtruea boolean. Empty cells becomenull. - Click Convert to JSON, then copy or download the result.
How the CSV is read
The parser follows the RFC 4180 rules that Excel and most programs use:
- Fields are separated by the delimiter and rows by line breaks.
- A field in double quotes can contain the delimiter and line breaks:
"Rahul, Jr."stays one value. - Two double quotes inside a quoted field mean one literal quote:
"Meera ""Mimi"" Rao"becomesMeera "Mimi" Rao. - Values with leading zeros, such as PIN codes like
0411or phone numbers, are kept as text so the zeros are not lost.
Example output
[{ "id": 1, "name": "Asha Patil", "city": "Pune", "active": true, "salary": 55000 }, ...]
Frequently asked questions
Why is a long ID number kept as text?
Numbers longer than 15 digits lose precision in JavaScript, so they stay as strings to protect the exact value.
Can I convert JSON back to CSV?
Yes, use the JSON to CSV converter.
Is my data uploaded?
No. The file is converted in your browser, which keeps customer lists and other private data safe.