CSV splitter for large files
Split a CSV into smaller files by rows or by number of files, with the header in every part. Files up to 2 GB, and nothing is uploaded.
Drop a CSV file here
CSV, TSV or TXT, up to 2 GB. It stays on your computer.
- No sign-up
- Nothing uploaded
- Files up to 2 GB
Parts that open, each with its header.
Files too big for Excel
The file is read in pieces as it is split, so a 1 GB export with millions of rows splits in your browser.
The header in every part
Each file starts with your column names, so every part opens as a proper table on its own.
No row cut in half
A quoted value with a line break inside stays whole. The split falls only between complete rows.
How to split a CSV file
The splitter reads your file from start to end, counts complete rows, and starts a new part each time one fills.
- 1
Add your CSV
Drop a .csv file on the box or choose one. Nothing is uploaded.
- 2
Choose the size
Rows per file, Excel's limit, or a set number of files.
- 3
Download
Save every part in one .zip, or download the parts one by one.
Other ways to do it
On a Mac or Linux, the split command does most of it.
split on the command line
Simple files, Mac or Linux
- Header in every partNo
- Never cuts a quoted rowNo
- No code or installNo
- Runs on a scheduleYes
Python with pandas
A job you script once
- Header in every partYes
- Never cuts a quoted rowYes
- No code or installNo
- Runs on a scheduleYes
- This page
This splitter
Large files, no setup
- Header in every partYes
- Never cuts a quoted rowYes
- No code or installYes
- Runs on a scheduleNo
How to split a CSV file on the command line
On a Mac or Linux, split cuts a file every N lines. It doesn't know about headers or quotes, so the header has to be put back on each part. pandas handles both, reading the file in chunks.
Need the reverse? The CSV merger combines several files into one.
tail -n +2 orders.csv | split -l 10000 - part_ for f in part_*; do (head -n 1 orders.csv; cat "$f") > "$f.csv"; rm "$f"; done
Splits every 10,000 lines and puts the header back on each part. A quoted value with a line break inside can be cut in two.
import pandas as pd
for i, chunk in enumerate(pd.read_csv("orders.csv", chunksize=10000), start=1):
chunk.to_csv(f"orders-part-{i}.csv", index=False)Reads 10,000 rows at a time, so it handles large files. pandas rewrites the values, so 129.50 comes out as 129.5.
Your file stays private
The splitter runs inside this page. Your file is read and split on your computer, and nothing is sent to Mammoth. That makes it safe for full customer or transaction exports.
Once the page has loaded, it works with your internet switched off.
Splitting an export so each team gets its part?
Mammoth can send each team its own rows. Filter one table into a view per team, and each view is emailed to that team on a schedule.
Weekly export
| North | Nov 02 | Leeds store | 4,120.00 | |
| South | Nov 02 | Bristol store | 3,875.50 | |
| West | Nov 02 | Cardiff store | 2,940.25 | |
| North | Nov 09 | Leeds store | 4,388.10 | |
| South | Nov 09 | Bristol store | 3,702.00 |
Illustration. Every new file in the folder is added to the same table.