Free tools • Fresh ideas
CSV to JSON Converter
Turn comma-separated rows with headers into JSON objects.
How to use the CSV to JSON Converter
Quoted commas, line breaks and doubled quotes are supported. Values stay strings so leading zeros survive. Use unique headers and a consistent number of fields on every row.
Example input
name,city
"Lina, A.",Leeds
Sam,York
Treat the first row as a schema
Paste comma-separated input with a header row. Each following row becomes an object, and the header provides its property names. A small inventory might use item_id, location and count. Choose headings that describe the actual values so a recipient can use the JSON without also opening your spreadsheet. The converter expects unique header names because repeating the same property in one object would make one value replace another or leave the recipient to decide which value matters.
Start by loading the example. The first person’s name contains a comma inside quotes, so that comma remains part of the field. A plain split at every comma would create an extra column. This distinction matters when preparing addresses, product names or descriptive text. If your spreadsheet exported tabs or semicolons, export comma-separated data or convert the delimiter with a parser that understands quoting. A general find and replace can damage text inside quoted fields.
Keep text intact until you know its intended type
The converter preserves field values as strings. A postcode, ticket identifier or contact extension can begin with zero, and interpreting such a value as a number would remove information. Empty fields also have meaning. An empty string can mean the author deliberately left the field blank. A downstream schema may use null for unknown information or omit a property entirely. Choose that interpretation once you know the receiving system’s requirements.
If a report genuinely needs numeric totals, convert only the fields designated as numbers in your application. Check missing values and values outside the intended range before computing a total. Dates can be even more ambiguous because a value like 4/5 may be interpreted differently in two locales. Export dates in a documented, consistent representation if the next system needs to sort or compare them. The JSON result leaves those decisions to the code that owns the data model.
Check difficult rows before converting the whole file
Test a source containing quotation marks, commas and line breaks. CSV can express a literal quote by doubling it inside a quoted field. A record with a long description may span several lines while still representing one row. A missing closing quote can cause a parser to combine what you intended as multiple rows, so fix the original export before trying again. When the converter reports a field count mismatch, compare the questioned record with the header and inspect how each embedded punctuation mark is quoted.
Also look for an extra separator at the end of a record. It can add a field even when the last cell looks blank in a text editor. Export a small subset first and compare source and result side by side. Then convert the full input and check the expected record count. If another system produced the CSV, keep a small example that demonstrates its quoting rules alongside your integration notes.
Use the output with another program
Copy the JSON for a small experiment or use Download for a file you can import. Open the file in a text editor and compare several objects with the source, including the first and last records. If the receiver expects an outer object with a specific property, place the resulting array under that property in your application. If it expects one JSON record per line, convert the array through your own export path. Line breaks inside a formatted JSON array do not make it a line-oriented format.
Browser processing suits data you can inspect and paste. For a larger recurring export, use a local pipeline that can report failures at the source and preserve an audit trail. Keep the input around until you have verified the imported data. The successful conversion confirms the file could be parsed according to this tool’s rules. Confirming every identifier and business value is still part of the import.