How I Convert JSON to Excel Without Uploading My Data

2026-11-07来源 dev.toEnglish

I once received a data file in JSON format. When I opened it in Excel, it showed up as a confusing mess instead of a clean table. The online converters I tried were full of ads, and some asked me to upload my data to their servers.

So I built a small free tool that converts JSON to CSV right in the browser. Here is the simple method I use now.

What JSON works best in Excel?

Excel works with rows and columns, so JSON converts cleanly when it is a list of objects with the same keys:

[ {"name": "Ali", "city": "Lahore", "age": 28}, {"name": "Sara", "city": "Karachi", "age": 25}, {"name": "Usman", "city": "Faisalabad", "age": 31} ] 

Each object becomes a row, and each key becomes a column.

Method 1: Convert to CSV, then open in Excel

  1. Paste your JSON into a JSON to CSV converter.
  2. Convert it and download the CSV file.
  3. Double-click the CSV to open it in Excel.
  4. Use File > Save As > Excel Workbook (.xlsx) to keep it as an Excel file.

The JSON above becomes:

name,city,age Ali,Lahore,28 Sara,Karachi,25 Usman,Faisalabad,31 

When I tested my tool with these three records, the CSV was ready in about a second.

Method 2: Power Query (newer Excel)

In Excel for Microsoft 365, go to Data > Get Data > From File > From JSON, then click To Table and expand the columns. This is useful for nested JSON.

Common problems

  • Everything in one column: import with Data > From Text/CSV and choose comma as the separator.
  • Strange characters: choose UTF-8 as the file origin when importing.
  • Converter shows an error: your JSON is probably invalid. Run it through a JSON validator first.

Links

Your data stays in your browser and is not uploaded. I'd love feedback on what would make it more useful!

This post was written with the help of AI, based on my own experience building the tool.

原文:https://www.a8q9.cn/en/article/how-i-convert-json-to-excel-without-uploading-my-data-88e1bd.html

相关文章