Skip to content

CSV Splitter: Split a Large CSV into Smaller Files

By rows, size or column, any size. Free, and nothing is uploaded.

Split a CSV into smaller files

Drop a file here or choose one. CSV, TSV or TXT, any size. Every part keeps the header row.

The sample: a year of made-up hourly weather for six UK cities, 52,560 rows.

Your file never leaves your device. It is read and split by your browser, on your device. Nothing is uploaded.

At a glance

Split by
Rows (1,000,000 by default, so every part opens in Excel), size (for example 100 MB), or one file per value of a column.
Every part
Starts with the header row and keeps every row exactly as it is in your file: quotes, line breaks inside quotes, numbers and dates untouched.
Files
CSV, TSV and TXT, separated by commas, semicolons, tabs or pipes, with Windows or Unix line endings, of any size.
You get
One ZIP of the parts, named after your file (weather-part-001.csv, weather-part-002.csv and so on), or, in Chrome and Edge on a computer, the parts saved straight into a folder you choose.
Processing
Runs in your browser. Your file is never uploaded, not even its name.
Price
Free. No account or sign-up.

How to split a CSV file

  1. Choose your file. Drop it onto the splitter at the top of this page, or click “Choose a file”. CSV, TSV and TXT files of any size work. No file to hand? “Try it with sample data” loads a year of made-up UK weather.
  2. Choose how to split it. By rows (1,000,000 rows per part by default, so every part opens in Excel), by size in MB, or by a column, which makes one file per value, such as one per city.
  3. Split and download. Click “Split & download”. The parts come as one ZIP file; in Chrome and Edge on a computer you can save them straight into a folder instead. The list shows every part with its rows and size.

Split by rows, by size or by a column

By rows: parts that open in Excel

Every part gets the same number of rows under the header, and the last one what is left. The default, 1,000,000 rows, opens in Excel, which stops at 1,048,576 rows. Blank lines stay where they are, but they don’t count as rows.

By size: parts under a limit

Each part is at most the size you choose, the header included: handy for email attachments and upload limits. Parts end between two rows, never in the middle of one. A single row bigger than the limit gets a part of its own, and the tool tells you.

By a column: one file per value

Pick a column such as a city, a product or a month, and every value gets its own file, named after it: weather-London.csv, weather-Leeds.csv. The rows keep their order within each file. Up to 1,000 different values: a column with more, such as a timestamp, is refused with a message instead of making thousands of files.

Your rows, exactly as they were

The splitter never rewrites a row. Numbers, dates, leading zeros, quotes and line endings stay exactly as they are in your file, and a quoted value with a comma or a line break in it stays whole, because a part only ends at the end of a row. Lines above the header, such as a logger’s notes, and a units row under it are repeated with the header. Split by rows or by size, the parts put back together without their repeated headers are your original file, byte for byte.

A worked example: a year of UK weather

The sample behind “Try it with sample data” is a year of made-up hourly weather for six UK cities (London, Manchester, Leeds, Cardiff, Edinburgh, Belfast): 52,560 rows, 2.16 MB, one row per city per hour. Its first lines:

time,city,temperature,humidity,sky
2025-01-01 00:00,London,3.1,90,Cloudy
2025-01-01 00:00,Manchester,3.5,89,"Rain, light"
2025-01-01 00:00,Leeds,1.7,91,Showers
2025-01-01 00:00,Cardiff,2.6,98,"Rain, light"
2025-01-01 00:00,Edinburgh,2.2,92,Cloudy
2025-01-01 00:00,Belfast,2.3,91,Clear

Split by rows, 10,000 per part, it makes 6 files, each with the header on top:

FileRowsSize
uk-weather-hourly-2025-part-001.csv10,000407 KB
uk-weather-hourly-2025-part-002.csv10,000411 KB
uk-weather-hourly-2025-part-003.csv10,000417 KB
uk-weather-hourly-2025-part-004.csv10,000416 KB
uk-weather-hourly-2025-part-005.csv10,000410 KB
uk-weather-hourly-2025-part-006.csv2,560104 KB

Split by the city column instead, it makes 6 files of 8,760 rows each, one per city, the rows still in time order:

FileRowsSize
uk-weather-hourly-2025-London.csv8,760350 KB
uk-weather-hourly-2025-Manchester.csv8,760385 KB
uk-weather-hourly-2025-Leeds.csv8,760340 KB
uk-weather-hourly-2025-Cardiff.csv8,760358 KB
uk-weather-hourly-2025-Edinburgh.csv8,760375 KB
uk-weather-hourly-2025-Belfast.csv8,760357 KB

The sky column holds values such as "Rain, light", with a comma inside the quotes: they stay one value in every part.

Why split a CSV for Excel?

Excel opens at most 1,048,576 rows per sheet, and a longer CSV is cut off at that row. Splitting it into parts of 1,000,000 rows gives you files that each open whole. Our guide CSV too large for Excel? explains the limit and the other ways around it.

Don’t need Excel at all? The large CSV viewer scrolls, sorts and filters every row of the whole file. To know how many parts you will get, the CSV row counter counts the lines of any file in seconds. And to put parts back together, or combine exports, use Merge CSV files.

Private by design: nothing is uploaded

Online CSV splitters that upload your file send a copy to their server. MegaRows does not: the splitting runs entirely in your browser, on your device, and neither the file nor its name is sent anywhere. Read the privacy statement for details.

Other ways to split a CSV

macOS and Linux: split

split -l 1000000 big.csv part-

Fast and built in, but the header ends up in the first part only, and a quoted value with a line break in it can be cut in two between parts.

Python: pandas

import pandas as pd
for i, part in enumerate(pd.read_csv("big.csv", chunksize=1_000_000)):
    part.to_csv(f"part-{i + 1:03}.csv", index=False)

Repeats the header in every part, but every value is read and written again: numbers can change their format and leading zeros disappear unless you read every column as text with dtype=str.

Frequently asked questions

How do I split a large CSV file into smaller files?

Choose the file in the splitter at the top of this page, keep “By rows” with 1,000,000 rows per part (or pick a size or a column) and click “Split & download”. You get a ZIP of the parts, each starting with the header row. It runs in your browser: nothing to install, nothing uploaded.

How many rows can Excel open?

At most 1,048,576 rows per sheet, the header included; a longer CSV is cut off at that row. Parts of 1,000,000 rows, the splitter’s default, stay well under the limit, so every part opens whole.

Does every part keep the header row?

Yes. Every part starts with the header row exactly as it is in your file, and so do any lines above it (a logger’s notes, for example) and a units row under it. Untick “Repeat the header row in every part” if your file has no header.

Will splitting change my data?

No. Rows are copied exactly as they are: numbers, dates, leading zeros, quotes and line endings stay the same. A quoted value with a comma or a line break in it is never cut in two, because a part only ends at the end of a row.

Is my file uploaded?

No. Your browser reads and splits the file on your own device, and neither the file nor its name is sent anywhere. That makes it safe for customer lists, financial exports and other data that must not leave your computer.

How big a file can I split?

There is no fixed limit on the size of the file or the number of rows: the practical limit is your device. In our tests, a 423 MB CSV split into ten parts of 1,000,000 rows, as one ZIP, in about a second (Chrome on an Apple M4 laptop, October 2026). Split by rows or by size, memory use stays small however big the file is. In Chrome and Edge on a computer, saving the parts into a folder is the best choice for the biggest files.

Can I split by the values of a column?

Yes. Choose “By a column” and pick the column: you get one file per value, named after it, such as weather-London.csv and weather-Leeds.csv, with the rows in their original order. A column with more than 1,000 different values, such as a timestamp, is refused with a message instead of making thousands of files.

Can I split an Excel (.xlsx) file?

Not yet: the splitter reads text files (CSV, TSV and TXT). Save the sheet as “CSV UTF-8” in Excel first, then split the CSV.

Coming soon to MegaRows: CSV to Excel and PDF reports · Compare CSV versions.

MegaRows processes files locally in your browser. Nothing is uploaded, not even the file name.