Skip to content
Free · Runs in your browser

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.

Works with
CSVTSVCSVZIP
Opens inExcelGoogle Sheets

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
  • Arla Foods logo
  • Bacardi logo
  • British American Tobacco logo
  • Everest Detection logo
  • Golden Acre logo
  • Handlangers logo
  • Inspired Learning Group logo
  • Kantar logo
  • MUFG logo
  • NielsenIQ logo
  • PTI Digital logo
  • RethinkFirst logo
  • Starbucks logo
  • The Specialist Works logo
What you get

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 it works

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. 1

    Add your CSV

    Drop a .csv file on the box or choose one. Nothing is uploaded.

  2. 2

    Choose the size

    Rows per file, Excel's limit, or a set number of files.

  3. 3

    Download

    Save every part in one .zip, or download the parts one by one.

Your options

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
With code

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.

Mac or Linux terminal
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.

Python with pandas
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.

How we handle your data

Once the page has loaded, it works with your internet switched off.

Every month

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.

Try Mammoth free

Weekly export

Northnorth view
Southsouth view
Westwest view
DriveDropboxOneDriveSFTP
Orders by regionUp to date
Nov 02Leeds store4,120.00
Nov 02Bristol store3,875.50
Nov 02Cardiff store2,940.25
Nov 09Leeds store4,388.10
Nov 09Bristol store3,702.00

Illustration. Every new file in the folder is added to the same table.

Questions

CSV splitter questions

Is my file uploaded?
No. The file is read and split inside your browser, and the parts are saved from there. Once the page has loaded, it works with your internet switched off.
How large a file can it split?
Up to 2 GB. The file is read in pieces as it is split, never loaded whole, so a file Excel refuses to open still splits.
Does every part get the header row?
Yes, while First row is a header is ticked. Untick it for a file with no header, and every line is treated as data.
How do I split a CSV for Excel?
Choose Excel's limit, 1,048,575 rows per file. Excel opens 1,048,576 rows, and the header takes one of them.
Can a row be cut in half?
No. A value in quotes can hold a line break, so the splitter cuts only at line breaks outside quotes. A plain line-count split, like the command-line split tool, can cut such a row in two.
Is anything in my data changed?
No. Each part holds the original text of its rows: the same quoting, separators and line endings.
How do I get the files?
Download all of them in one .zip, or each part on its own from the list. They are named after your file: orders-part-001.csv, orders-part-002.csv and so on.
Can I split into a set number of files?
Yes. Choose Number of files, and the rows are shared out evenly. The splitter counts the rows first, which takes a moment on a large file.
Is it free?
Yes, with no account and no email.