How to split a CSV file
- Choose or drop the CSV file on the box. Excel files work too: the first sheet is split.
- Choose how to split it. Every N rows (say 50,000 rows per file), into N files of the same size, or by the value in a column.
- Choose CSV or Excel files, and whether every file gets the header row (on by default).
- Select Split file. The list shows each file with its number of rows; download them all as one ZIP.
Three ways to split
| Split | What you get | Example |
|---|---|---|
| Every N rows | Files of N data rows each; the last one has the rest. The header row is not counted. | An upload form that takes 10,000 rows at a time |
| Into N files | N files with the same number of rows, give or take one file. | Sharing a list between 4 people |
| By column value | One file per different value in the column you choose, named after the value. Capitals and spaces around the value are ignored, so "North" and "north " go in the same file. | One file per region, store, month or sales rep |
File names are the original name plus the part number (customers_part001.csv) or the value
(customers_North.csv). Characters that file names cannot hold, such as / or :,
become _. Splitting by column stops at 1,000 different values, so a column of IDs does not create
thousands of files by mistake.
How each file is read
- Encoding. A file that starts with a byte order mark is read as UTF-8 or UTF-16. Any other file is read as UTF-8, and if it contains a byte that is not valid UTF-8, it is read again as Windows-1252, the encoding of older Windows and Excel exports. The result is always UTF-8, so accents from every file come out right.
- Separator. Comma, semicolon, tab or | bar, detected per file from its first lines. The file list shows what was detected.
- Quotes. Values in double quotes may contain the separator, quotes written twice and line breaks, as RFC 4180 describes. They stay one value.
- Big files. The file is read in 4 MB pieces by a background thread of the page (a Web Worker), so the page does not freeze. In our test (Chrome 152 on a Mac with an Apple M5 chip, 17 Oct 2026), a 104 MB file of 1.7 million rows was split into 4 files of 500,000 rows in about 1.5 seconds, ZIP included.
We tested splitting by lines: records cut in half
A common way to split a CSV file is a line splitter such as split -l on Mac and Linux. It counts lines,
not records, and a CSV record can hold a line break inside quotes, typically in an address or a comment. We split a
5-line file of 4 customers, two of them with an address on two lines, with split -l 2 on macOS 26.6:
| Part | What it held |
|---|---|
| part_aa | The header, then customer 1 cut after "12 Oak St: an open quote with no end |
| part_ab | Apt 4", the rest of customer 1's address, as the first line, then customer 2, and no header |
| part_ac | Customer 3 whole, by luck, since its two lines fell in the same part; no header |
| part_ad | Customer 4; no header |
Two of the four files are broken: a CSV reader that opens part_aa reads the open quote to the end of the file, and part_ab starts with a stray quote. Three files have no header row. This tool reads the quotes, so a record is never split, and it writes the header into every file. The Example files button loads a file with addresses on two lines, so you can check it.
Can Excel split a CSV file?
Excel has no split command. By hand, you open the file, select a block of rows, copy it into a new workbook and save that as CSV, then repeat; to split by a value, filter the column (Data, Filter) and copy the visible rows each time. That works for a few files.
It does not work for files Excel cannot open whole: a worksheet holds at most 1,048,576 rows by 16,384 columns. A CSV file with more rows than that is a common reason to split it in the first place. This page reads past that limit, because it never puts the file in a sheet.
Related tools
Guides
Questions
How do I split a CSV file into multiple files?
Open it on this page, choose Every N rows, Into N files or By column value, select Split file and download the ZIP.
How do I split a CSV file by the value in a column?
Choose By column value and pick the column. You get one file per value, named after it, each with the header row.
Does every file keep the header row?
Yes, by default. Switch off Header row in every file to keep it in the first file only.
How do I split a CSV file that is too big for Excel?
Open it here: the file is read in pieces in your browser, not in a sheet, so it can have more than 1,048,576 rows. Split it into files of, say, 1,000,000 rows each.
Can I get Excel files instead of CSV files?
Yes. Choose Excel files, and each part is saved as an .xlsx file in the ZIP. Each part must stay under 1,048,576 rows.
What about values with line breaks or commas?
They are kept whole. Quoted values are read as one value, as RFC 4180 describes, so no record is ever cut in two.
Is my file uploaded?
No. It is read and split by this page on your device, and the ZIP is made there too.