FormatterHQ

JSON to Excel Converter

Build a genuine .xlsx workbook from JSON records, with numbers stored as numbers, text kept as text and one worksheet per array when your JSON holds several.

Input JSON
Output CSV
Ready.

How to use the JSON to Excel Converter

  1. Paste your JSON, drop or upload a .json file, use Load URL, or click Sample.
  2. Type a Sheet name and choose whether to Flatten nested objects into separate columns.
  3. Click Convert to Excel. The output panel shows a CSV preview and the status bar reports the workbook size.
  4. Click Download to save the .xlsx file and open it in Excel, Google Sheets, LibreOffice or Numbers.

JSON to Excel as a real workbook, not a renamed CSV

This JSON to Excel converter writes an Office Open XML workbook (.xlsx) directly in your browser. Because the file carries cell types, Excel does not have to guess: numbers arrive as numbers you can sum, booleans as TRUE and FALSE, and text such as ZIP codes or invoice numbers stays exactly as written. That avoids the classic CSV surprises of lost leading zeros and dates invented from ordinary strings.

Example

{
  "invoices": [
    { "number": "INV-0042", "customer": "Ava Martinez", "zip": "02134",
      "total": 1249.5, "paid": true, "issued": "2024-06-30" },
    { "number": "INV-0043", "customer": "Noah Kim", "zip": "94105",
      "total": 80, "paid": false, "issued": "2024-07-02" }
  ]
}

With Sheet name set to Invoices, the status bar reads Excel workbook ready (1 sheet, 8.8 KB) — click Download, and the output panel previews the sheet as CSV:

number,customer,zip,total,paid,issued
INV-0042,Ava Martinez,02134,1249.5,true,2024-06-30
INV-0043,Noah Kim,94105,80,false,2024-07-02

In the downloaded workbook, total is a numeric column, paid holds Excel booleans, and zip keeps 02134 because it was a JSON string. The invoices wrapper was unwrapped automatically, since it was the only key.

How cells are typed

JSON valueExcel cell
NumberNumeric cell, ready for formulas
true / falseBoolean cell (TRUE / FALSE)
StringText cell, unchanged, including leading zeros
Date-like string such as "2024-06-30"Text cell; convert it with DATEVALUE or Text to Columns if you need a real date
null or missing keyEmpty cell
Nested object or array (flattening off)Text cell with compact JSON

The first row always contains the column names. Column widths are set from the header and the longest value in the first 200 rows, between 8 and 60 characters, so the sheet is readable the moment it opens.

Several arrays become several sheets

If the top level is an object with two or more keys and every value is an array of objects, the workbook gets one worksheet per key, named after the key. A backup-style export like {"customers": [ … ], "orders": [ … ]} therefore becomes a two-sheet file, and the Sheet name option is not used. The status bar tells you how many sheets were created.

In that case the CSV preview is only a rough view: it squeezes the whole object into one flattened row. Trust the downloaded file, or open it in the Excel viewer to check each sheet.

Options

  • Sheet name – the tab name for a single-sheet workbook, Sheet1 by default. Excel allows at most 31 characters and forbids \ / ? * [ ] :, so those characters are removed and longer names are cut; Q3 / Sales: [draft] becomes Q3 Sales draft.
  • Flatten nested objects – on by default. Nested fields get their own columns (customer.address.city) and array entries are numbered (items.0, items.1). Turn it off to keep one column per top-level field.

The download is named json-to-excel.xlsx; rename it after saving if you like.

Limits worth knowing

  • Long numeric IDs. JSON numbers are parsed as double-precision values, and Excel itself displays at most 15 significant digits. Keep IDs such as order numbers or card-like references as strings in the JSON so they become exact text cells.
  • Formulas are not evaluated. A string like "=SUM(A1:A3)" is stored as text, not as a formula.
  • Very wide data. Flattening an array with hundreds of entries creates hundreds of columns. Switch flattening off, or reshape the JSON so the list becomes its own array of records.

Excel workbook or CSV file?

.xlsx from this pageCSV
Opens without an import dialogYesDepends on locale and separator
Numbers, booleans and text kept apartYes, per cellNo, the reader guesses
Several tables in one fileYes, one sheet per arrayNo
Readable by scripts and command-line toolsNeeds a spreadsheet libraryYes
Easy to diff in version controlNo, it is a zipped binaryYes

Choose the workbook when a person will open the file, and CSV when another program will read it. Need a plain text file instead? JSON to CSV gives you control over delimiter and quoting. To go back from a spreadsheet to JSON, use Excel to JSON.

Privacy

The workbook is assembled in your browser with a JavaScript spreadsheet library, so your JSON is not uploaded. Only Load URL and Save & Share involve our server.

Convert JSON to Excel in Python

Python has no built-in .xlsx writer, so use openpyxl: create a Workbook, append the keys as the header row, then append one list of values per object. Numbers, booleans and strings keep their types in the sheet. What trips people up is nested data: a cell cannot hold a list or a dictionary, and ws.append() raises ValueError: Cannot convert ['new', 'sale'] to Excel. Flatten those values or store them as JSON text, as below.

# pip install openpyxl
import json

from openpyxl import Workbook

data = """[{"sku": "A-100", "price": 24.5, "tags": ["new", "sale"]},
           {"sku": "B-220", "price": 89, "tags": []}]"""
rows = json.loads(data)

wb = Workbook()
ws = wb.active
ws.title = "Products"
ws.append(list(rows[0]))                      # header row from the keys
for row in rows:
    # a cell cannot hold a list or dict, so store those as JSON text
    ws.append([json.dumps(v) if isinstance(v, (list, dict)) else v for v in row.values()])
wb.save("products.xlsx")

print(ws.dimensions, [cell.value for cell in ws[2]])

For a one-off export, the converter above builds the same kind of workbook in your browser.

Frequently asked questions

Why does the output panel show CSV instead of a spreadsheet?
The editor can only display text, so it shows the sheet contents as CSV. The .xlsx workbook is generated at the same time and saved when you click Download.
How do I export JSON to multiple Excel sheets?
Give the converter an object whose keys each hold an array of records, such as {"users": [...], "orders": [...]}. Each key becomes its own worksheet with the key as the tab name.
Why are my dates text in Excel?
JSON has no date type, so dates arrive as strings and are stored as text cells. Select the column in Excel and use Text to Columns or DATEVALUE to turn them into real dates.
Will the file open in Google Sheets or LibreOffice?
Yes. The download is a standard .xlsx workbook. Upload it to Google Drive or open it directly in LibreOffice Calc or Apple Numbers.
Is there a size limit?
There is no fixed limit, but everything happens in your browser memory. Files of a few megabytes convert quickly; very large exports may be slow on older devices.

Last updated October 3, 2026

Related tools