Spreadsheet Converter: Excel to JSON and CSV avatar

Spreadsheet Converter: Excel to JSON and CSV

Pricing

from $0.15 / 1,000 row converteds

Go to Apify Store
Spreadsheet Converter: Excel to JSON and CSV

Spreadsheet Converter: Excel to JSON and CSV

Convert Excel to JSON, CSV to JSON, JSON to CSV and Excel to CSV. Reads XLSX, XLS, ODS, CSV, TSV, JSON and Apify datasets. Writes CSV, XLSX, JSON, JSON Lines or dataset rows. Detects headers, numbers and dates, flattens nested JSON, picks sheets and removes duplicates.

Pricing

from $0.15 / 1,000 row converteds

Rating

0.0

(0)

Developer

Malik Said

Malik Said

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

4 days ago

Last modified

Share

Spreadsheet Converter: Excel, CSV and JSON

Spreadsheet Converter turns spreadsheet and data files into the format you need. Convert Excel to JSON, CSV to JSON, JSON to CSV, Excel to CSV or CSV to Excel in one run. It also turns any Apify dataset into an Excel or CSV file. It finds the header row, reads numbers and dates, flattens nested JSON, and can merge many files into one.

Spreadsheet converter: what it does

  • Reads XLSX, XLS, ODS, XLSB, CSV, TSV, JSON, JSON Lines and Apify datasets.
  • Writes dataset rows (JSON), CSV, TSV, XLSX, JSON or JSON Lines files.
  • Converts every sheet of a workbook, or only the sheets you name.
  • Finds the header row and skips title rows above it.
  • Turns CSV text into numbers, true and false, and ISO dates. Codes such as 008 stay text.
  • Converts Excel dates to ISO dates (2026-01-31), in UTC.
  • Flattens nested JSON into parent.child columns for CSV and Excel.
  • Keeps, orders and renames columns.
  • Removes duplicate rows by one or more columns.
  • Merges many files and sheets into one output with all columns.
  • Detects the delimiter (comma, semicolon, tab or pipe) and the text encoding.

Files are converted inside the Actor. They go to no outside service.

Input: URLs, your own files or datasets

You can give files in four ways:

  1. File URLs. Paste links, one per line.
  2. Key-value store. Upload files to one of your Apify key-value stores and pick it. The Actor only reads that store.
  3. Datasets. Pick one or more Apify datasets, for example the results of another Actor. Each dataset becomes one file.
  4. Pasted data. Paste CSV, TSV, JSON or JSON Lines text, or a base64 file such as an XLSX, into Pasted data. This suits API, n8n and Make users who hold the data in a variable. Up to 4 MB. For larger files, use a URL or a key-value store. The result row shows source: "pasted" and the file name you set, with the detected extension.

How to convert Excel to JSON or CSV

  1. Paste your file links in File URLs, or pick a key-value store or a dataset.
  2. Pick the Output format. Dataset rows give you JSON you can also export from Apify as CSV, Excel or XML.
  3. Optional: name the Sheets, pick Keep only these columns, set Remove duplicates by, keep only some rows with Keep only rows that match, or Sort by a column.
  4. Click Start.
  5. Open the Converted files tab for file outputs, or the dataset for rows.

Output

Dataset rows. With the default output format, every row of your file becomes one dataset item, with your column names as fields. Row from a test run (the ISO 4217 currency list):

{
"Entity": "AFGHANISTAN",
"Currency": "Afghani",
"AlphabeticCode": "AFN",
"NumericCode": "971",
"MinorUnit": 2,
"WithdrawalDate": null
}

NumericCode stays text because the same column holds codes with a leading zero, such as 008.

Files. With CSV, TSV, XLSX, JSON or JSON Lines, the converted files go to the run's key-value store. The dataset then holds one summary record per input file:

FieldMeaning
status, errorok or failed, and why it failed
fileUrl, keyValueStoreKey, datasetIdWhere the file came from
fileName, inputFormat, inputBytesThe input file
sheetsFound, sheetsEvery sheet name, and per converted sheet the header row, rows read and saved, empty rows and duplicates skipped
rowsRead, rowsSaved, duplicatesRemoved, rowsFilteredOutRow counts for the file. Filtered rows are free
columns, columnTypesOutput columns and the type found in each: number, string, date, boolean, object, mixed or empty
outputFilesEach output file: sheet, key, download URL, rows and bytes
truncatedTrue when a row limit or your maximum cost per run stopped the file early

Summary record from a test run (the currency list, CSV to XLSX):

{
"status": "ok",
"fileUrl": "https://raw.githubusercontent.com/datasets/currency-codes/main/data/codes-all.csv",
"fileName": "codes-all.csv",
"inputFormat": "csv",
"inputBytes": 17853,
"rowsRead": 449,
"rowsSaved": 449,
"duplicatesRemoved": 0,
"rowsFilteredOut": 0,
"columns": ["Entity", "Currency", "AlphabeticCode", "NumericCode", "MinorUnit", "WithdrawalDate"],
"columnTypes": {
"Entity": "string",
"Currency": "string",
"AlphabeticCode": "string",
"NumericCode": "string",
"MinorUnit": "mixed",
"WithdrawalDate": "string"
},
"outputFormat": "xlsx",
"outputFiles": [{ "sheet": "codes-all", "key": "codes-all.xlsx", "rows": 449, "bytes": 24476 }],
"truncated": false,
"processingMs": 705
}

The record also has url in each output file, plus id, sheets, finalUrl and scrapedAt. In every mode, the SUMMARY record of the key-value store lists the same summaries.

Output files

Output formatFiles
CSV, TSV, JSON, JSON LinesOne file per sheet. A one-sheet file keeps its name: report.csv. Several sheets: report-Sales.csv, report-Notes.csv
XLSXOne workbook per input file, one worksheet per sheet. A sheet with more than 1,048,575 rows continues on a second worksheet
Merge onOne file, merged.csv or merged.xlsx, with every column of every input

CSV files use a comma, UTF-8 and Windows line ends. Turn on Add a byte order mark when you open them in Excel and they hold accents, Arabic or Chinese.

Input options

OptionDefaultMeaning
File URLsOne sample CSVLinks to the files
Key-value store, Record keysNoneYour store with files, and optionally which records
Datasets to convertNoneApify datasets to turn into files
Pasted data, Pasted data file nameNone, pastedCSV, JSON or base64 file text pasted into the input
Output formatDataset rowsDataset rows, CSV, TSV, XLSX, JSON or JSON Lines
Merge all files into one outputOffOne output for the whole run
Maximum rows per file0 (all)Stop each file after this many rows
SheetsAllSheet names or tab numbers
Header rowAuto-detectAuto, first row, none, or a row number
Input formatAuto-detectForce a format when auto-detection is wrong
CSV delimiterAutoComma, semicolon, tab or pipe, or type your own
Text encodingAutoUTF-8, Latin-1 or UTF-16
JSON path to the recordsEmptyFor example data.items
Detect numbers, dates and true/falseOnFor CSV and TSV text
Numbers use a decimal commaOffFor European files: 1.234,5
Day and month order in text datesLeave as textDay first or month first
Keep only these columnsAllNames in the order you want
Rename columnsNone{"old name": "new name"}
Remove duplicates byNoneColumn names, or * for whole rows
Keep only rows that matchNoneOne rule per line, such as Price >= 10, Country = Jordan, Name contains ltd, Email is not empty
Rows must matchAll rulesAll rules, or any one rule
Sort byNoneColumn names; add desc for largest first. Holds rows in memory (about 1,000,000 short rows at 512 MB)
Flatten nested JSONAutoFlattens for CSV, TSV and XLSX
Lists inside JSON recordsJoinJoin, one column per position, or JSON text
Skip empty rows, Trim spacesOnCleaning
Add source columnsOffAdds _file, _sheet and _row
Maximum file size100 MBUp to 500 MB

Limits and memory

  • CSV, TSV, JSON Lines and XLSX are read as streams, one row at a time. A 105 MB CSV with 1.16 million rows converts in 512 MB.
  • XLSX keeps its shared text in memory. At 512 MB that is about 500,000 distinct text values per workbook.
  • XLS, ODS and XLSB are read whole. At 512 MB the limit is 2.5 MB for XLS and XLSB and 1.7 MB for ODS. Save bigger files as XLSX or CSV.
  • JSON files are read whole. At 512 MB the limit is 8 MB. Use JSON Lines for bigger files.
  • Formulas give their last saved result. The Actor does not recalculate them.
  • Merged cells give their value in the first cell only.
  • Password-protected workbooks are not supported.
  • One run converts at most 1,000 files.

Pricing

You pay per file converted and per row saved, plus a small fee per run. See the Pricing tab for current prices. Failed files cost nothing. A run stops when it reaches your maximum cost per run, and the last file then says truncated: true.

Privacy and fair use

  • The Actor only fetches the files you list.
  • It reads robots.txt on each host and skips files that the host does not allow.
  • It refuses local and private network addresses.
  • It does not log in and does not get around access controls.
  • Converted files stay in your own Apify storage.
  • Use only files you have the right to process.

FAQ

Where are my files? In the run's key-value store. Each summary record has a direct url for each output file.

Why is a number column text? At least one value in that column has a leading zero or more than 15 digits, so the column holds codes. Converting them to numbers would lose digits.

Why are my dates text? CSV dates such as 31/12/2026 stay text until you pick Day and month order in text dates. ISO dates such as 2026-12-31 are read as dates.

Can I convert results of another Actor? Yes. Pick its dataset in Datasets to convert.

Other Actors by the same developer

Support

Report a problem in the Issues tab. Include the run link.