Convert a worksheet to JSON and check the inferred structure
Excel to JSON reads a real .xlsx workbook and converts a selected worksheet to records. It provides a quick way to move a spreadsheet table into an API or JSON workflow.
When should you use it?
- Import a manually maintained data sheet.
- Preview worksheet records before sending them to an API.
- Convert a vendor workbook into a JSON file.
Example: a sheet becomes records
The first populated row supplies names. Actual JSON cell types depend on the workbook cell types.
name | score
Alex | 42
Sam | 38[{"name":"Alex","score":42},{"name":"Sam","score":38}]Prepare the header row before importing
Choose the worksheet that contains the records. Its first populated row supplies the property names, so a decorative report title is a poor header. A simple rectangular table with clear, unique column names produces a more useful result than a workbook arranged for printing. Remove unrelated headings and totals when they should not become records.
Cell formatting does not define a JSON contract
A spreadsheet date can be stored as a number with a date display format. This importer returns that underlying serial rather than guessing a timezone or date string. Formula cells are rejected instead of using a potentially stale cached value. Review identifiers, blanks, booleans, and dates in the output, then validate against a schema if the JSON will feed an API. Legacy .xls and encrypted workbooks are outside this importer.
Turn worksheet rows into JSON records.
Open a local .xlsx workbook, choose a sheet, and convert each data row to an object using the first row as headers.
Open XLSX
Choose a workbook on this device or use the sample.
Select a sheet
The first populated row supplies unique column names.
Export JSON
Copy or download the array of row objects.
How do I convert a worksheet to JSON without evaluating formulas?
Select a real .xlsx file and choose the worksheet. The first populated row supplies property names, and later rows become objects. The importer reads stored cell values; it rejects formula cells rather than calculating them.
Example JSON after importing two rows
json[
{"name":"Alex","score":42},
{"name":"Sam","score":38}
]The example assumes the workbook stores score as numeric cells. Text cells such as "042" remain strings.
Why does an Excel date appear as a number in JSON?
Spreadsheet dates are stored as serial numbers with formatting. The importer returns the underlying serial value rather than guessing a timezone or a date string.
What should you check before using the result?
Formula cells are rejected and date-formatted numbers are returned as spreadsheet serial values. Encrypted .xlsx and legacy .xls are unsupported; file, extracted XML, column, and cell limits apply.
What is imported
Text, booleans, and finite numeric cells are read. Blank cells become empty strings. Formula cells are rejected because cached results may be stale and formulas must not be executed. Date-formatted numbers remain their underlying serial values.
Workbook limits
The input .xlsx file is limited to 2 MiB compressed and 12 MiB of total extracted workbook XML. Import supports up to 100 columns and 200,000 cells. Encrypted and legacy .xls files are not supported.
Technical reference: JSON syntax and interoperability · RFC 8259