Delimiter:
JSON Input 0 B
Ready
0 chars
CSV Output 0 B
CSV output will appear here...
0 chars
Features

Why use this converter

Auto-detect columns

Headers are automatically collected from all objects in the array, even if different records have different keys. Missing values become empty cells.

Flexible delimiters

Choose comma (default), semicolon, tab (TSV), or pipe as your delimiter. Great for European locales that use comma as decimal separator.

Proper escaping

Values containing the delimiter, quotes, or newlines are automatically wrapped in double quotes with embedded quotes doubled — fully RFC 4180 compliant.

How it works

Conversion explained

1. Validate input

The input must be a JSON array of objects. If it's a single object, it's wrapped as a one-element array. Anything else produces a clear error.

2. Collect headers

The parser walks every object to collect all unique keys, preserving first-seen order. These become the CSV header row.

3. Serialize rows

Each object becomes a row, with missing keys rendered as empty strings. Nested objects and arrays are JSON-encoded into a single cell.

FAQ

JSON to CSV Converter — frequently asked questions

What if my JSON is not an array?

A single JSON object is automatically wrapped as a one-element array. Any other type (number, string, etc.) will produce an error — CSV only makes sense for tabular data.

How are nested objects handled?

Nested objects and arrays are JSON-encoded into a single cell. For example, {"address":{"city":"NYC"}} becomes the cell value "{\"address\":{\"city\":\"NYC\"}}". If you want flattened columns instead, use the JSON Flattener first.

Can I use a custom delimiter?

Yes. Choose comma, semicolon, tab (TSV), or pipe. For Excel in European locales, semicolon is often the correct choice.

Does it support Excel-compatible CSV?

Yes. The output follows RFC 4180 — values with special characters are quoted, quotes within values are doubled, and line endings are Unix newlines.