DoneInTab
Data & Spreadsheet Guide

How to Open and Convert JSON Files to Excel

Step-by-step methods to open .json files in Microsoft Excel using Power Query or convert flat and nested JSON into clean .xlsx workbooks directly in your browser.

By DoneInTab Editorial TeamPublished Updated 8 min read

Microsoft Excel cannot open a raw .json file as a clean spreadsheet by double-clicking it. Because JSON stores hierarchical objects and arrays rather than a flat row-and-column grid, you either need Excel's built-in Power Query importer or a converter that flattens objects into an .xlsx workbook.

Want an instant spreadsheet without configuring Power Query? Use our free browser-based JSON to Excel Converter (.xlsx) to flatten nested objects, preserve leading zeros, and neutralize spreadsheet formula injection with zero server uploads.

Download Sample JSON Test Files

Free static downloads. No sign-up required.

Method 1: Open a JSON File Directly in Excel Using Power Query

Supported desktop versions of Microsoft Excel include Power Query's native JSON connector:

  1. Open a blank workbook in Excel and go to Data > Get Data > From File > From JSON.
  2. Select your .json file and click Import to launch the Power Query Editor.
  3. If your JSON root is an array of objects, click To Table on the Transform tab, then click the double-arrow expand icon on the column header to choose fields.
  4. For nested objects or nested arrays, click the expand icon on each nested Record or List column individually before clicking Close & Load.
Version & Platform Limitations: Excel 2016 and Excel 2019 for Mac do not support Power Query's From JSON connector (Microsoft 365 for Mac or Excel for Windows 2016+ is required). Even on supported versions, deeply nested objects require manual column-by-column expansion, and automatic type detection can strip leading zeros from ZIP codes unless you explicitly set column types to Text.

Method 2: Convert JSON to .xlsx in Your Browser (DoneInTab)

If you are on macOS without Microsoft 365, need quick nested flattening, or want strict leading-zero preservation without uploading sensitive API payloads to a remote server:

  1. Open DoneInTab JSON to Excel Converter.
  2. Paste JSON text or upload a .json file (processed 100% in local browser memory).
  3. Choose your flattening separator (default .), array handling (JSON string or comma-joined), smart type detection, and OWASP formula escaping.
  4. Download the generated OpenXML .xlsx workbook and open it in Excel, LibreOffice Calc, or Google Sheets.

How Flat Objects, Nested Objects, and Arrays Map to Excel Columns

How DoneInTab maps JSON structures to .xlsx spreadsheet columns
JSON StructureExample InputResulting .xlsx Column / Cell
Flat object array[{"id":"001","total":42.5}]Columns: id (Text '001'), total (Number 42.5)
Nested object (flattened){"customer":{"zip":"00501"}}Column: customer.zip (Text '00501')
Nested array (JSON mode){"tags":["priority","vip"]}tags: ["priority","vip"]
Nested array (Join mode){"tags":["priority","vip"]}tags: priority, vip
Single object root{"status":"ok","count":3}1-row table with columns status, count

Leading-Zero Preservation & Formula Injection Protection

  • Leading Zeros Preserved: String values matching leading-zero patterns (such as "00501" or "00081") are written as explicit OpenXML String cells even when Smart Types is enabled, preventing Excel from turning them into 501 or 81. (Learn more in How to Keep Leading Zeros in CSV Files.)
  • Formula Injection Defense: When enabled, cells beginning with =, +, -, @, tab, or carriage return are safely escaped with a leading apostrophe so untrusted JSON strings cannot execute formulas when opened in Excel.

Supported Formats, Limits & Related Tools

  • Output Format (.xlsx only): DoneInTab generates modern OpenXML .xlsx workbooks. Legacy binary .xls output is not supported.
  • Browser Bounds: Designed for client-side workbooks up to 100,000 rows and 1,000 columns (capped by available browser memory and Excel's 32,767-character cell limit).
  • Going the other direction? Use Excel to JSON Converter (reads .xlsx worksheets into flat JSON arrays of objects or arrays without nested JSON reconstruction), CSV to Excel, or CSV & Excel Standards Guide.

Troubleshooting & Frequently Asked Questions

Why does Excel show “Record” or “List” instead of my data?

In Power Query, nested objects appear as clickable Record links and arrays appear as List links until you expand them. Using DoneInTab's flattening option expands nested objects into dot-separated columns automatically.

Can I convert a JSON file to legacy .xls format?

No. DoneInTab exports modern OpenXML .xlsx files only, which are supported by Microsoft Excel (2007 and newer), Apple Numbers, Google Sheets, and LibreOffice Calc.

What if my JSON root is a single object or a primitive array?

A single root object converts into a 1-row worksheet, and an array of primitive values converts into a single value column. Top-level primitive strings or numbers alone are rejected because they have no tabular structure.

Related In-Browser Tools