ToolWren logo ToolWren
ToolWren › CSV ⇄ JSON

CSV ⇄ JSON Converter

Turn a CSV table (with a header row) into a JSON array of objects, or convert a JSON array back into CSV. Quoted fields, commas and embedded quotes are handled correctly.

100% client-side · nothing is uploaded

Loading tool…

How to use the CSV ⇄ JSON

  1. Choose the mode you need with the Encode / Decode toggle at the top of the tool.
  2. Type or paste your text into the Input box — the result appears instantly as you type.
  3. Use Swap (⇅) to move the output back into the input and flip the mode, which is handy for round-trips.
  4. Click Copy to copy the result, or Clear to start over.

Privacy: this tool runs entirely in your browser. Your input is never sent to, received by, or stored on any server — there are no uploads and no tracking of what you enter.

About CSV ⇄ JSON

CSV to JSON

The first CSV row is treated as the header. Each subsequent row becomes a JSON object whose keys are the header names. This is ideal for feeding spreadsheet exports into APIs or JavaScript.

JSON to CSV

Given a JSON array of objects, the converter collects the union of all keys as the header row and writes one CSV line per object. Values containing commas, quotes or newlines are safely quoted and escaped per RFC 4180.

Why convert in the browser?

Spreadsheet data is often sensitive. Because this tool runs locally, your rows never leave your device — unlike many online converters that upload your file.

Frequently asked questions

Does my CSV need a header row?
Yes, for CSV→JSON the first row is used as the object keys. For JSON→CSV the header is generated from the object keys.
Are quoted fields and commas inside values handled?
Yes. The parser understands double-quoted fields, escaped quotes ("") and commas/newlines inside quotes.
Are values typed as numbers or kept as strings?
CSV→JSON keeps cell values as strings to avoid data loss (e.g. leading zeros, IDs). Convert types in your own code if needed.
Is my data uploaded?
No. All parsing happens in your browser with JavaScript.

Related tools