CSV to JSON Converter (Header Row to Keys)

Convert CSV into a JSON array. Paste or upload a file, processed locally by default.

Paste CSV and convert instantly to JSON. Handle personal data carefully.

Input data is processed in your browser and never uploaded.

CSV JSON Conversion Tool

Use it for “CSV JSON conversion”, “csv to json”, and “convert CSV to JSON” workflows with quick paste or upload.

How to use

  1. Paste CSV (or upload a file)
  2. Choose header, type inference, and empty-cell behavior when needed
  3. Copy JSON output or download as .json

Examples

Basic (Type Inference ON)

Input

name,age,active
Alice,30,true
Bob,25,false

Output

[
  { "name": "Alice", "age": 30, "active": true },
  { "name": "Bob", "age": 25, "active": false }
]

Empty cell to null

Input

name,age
Alice,
Bob,25

Output

[
  { "name": "Alice", "age": null },
  { "name": "Bob", "age": 25 }
]

Conversion Tips

  • Keep type inference OFF for ID columns where leading zeros are important.
  • For TSV, set delimiter to tab or use auto detection.
  • If column counts vary, check warnings and set delimiter manually when needed.

FAQ

Can I use the first row as headers?

Yes. If header mode is off, keys are generated as col1, col2, ...

Numbers stay as strings.

Turn on type inference. Safe default is OFF (all values as strings).

Can empty cells become null?

Choose empty string, null, or omit key.

Can it convert TSV too?

Set delimiter to tab or use auto detection.

Does it support commas/newlines inside quoted fields?

Yes. If parsing fails, explicitly set quote character and delimiter.

What if header names are duplicated?

They are auto-renamed like name_2, name_3 and shown as warnings.

Related Tools