SparkJSONConvert JSON to CSV Online

Convert JSON to CSV Online

Turn an array of JSON objects into a CSV table. Nested objects become dotted columns (e.g. meta.team); nested arrays are kept as JSON strings so rows stay rectangular.

Free SparkJSON tool — runs 100% in your browser. No signup, no upload, no paywall. This page converts JSON to CSV locally.

Loading converter…

No data leaves your browser.

Advertisement

How SparkJSON flattens JSON for CSV

CSV is a grid. JSON is a tree. When you convert, something has to give. SparkJSON expects an array of objects (or a single object treated as one row). Nested objects are flattened with dot notation so meta.team becomes its own column.

Nested arrays cannot become multiple CSV columns without inventing a schema. They are stringified with JSON.stringify so no data is dropped — you can parse that cell later if needed.

  • Array of objects — best input shape for clean headers.
  • Dot flattening — nested objects expand into columns.
  • Arrays as cells — nested arrays stay as JSON text in one cell.

Array and nesting caveats

Uneven keys across rows

If row 1 has city and row 2 has country, both columns appear; missing cells are empty.

[{ "a": 1 }, { "b": 2 }] → columns a,b

Deep trees

Very deep nesting creates many dotted columns. Prefer flattening upstream if the CSV is for Excel analytics.

Non-array root

A bare object becomes a one-row CSV. A bare array of primitives becomes a single value column.

Frequently asked questions

Will nested JSON become multiple rows?

No. Each top-level array element is one CSV row. Nested arrays stay in a single cell as a JSON string.

Are commas inside values escaped?

Yes. Values with commas, quotes, or newlines are wrapped in quotes per common CSV rules.

Is conversion uploaded?

No. JSON→CSV runs entirely in your browser.