Skip to Content
RowSlice

Guide

Is There a CSV File Size Limit?

Published

The CSV format itself has no size limit. RFC 4180, the closest thing CSV has to a specification, says nothing about maximum file size, number of rows or length of a value. A CSV is plain text, and a text file can be as large as the disk that holds it.

So when a CSV is “too big”, something else has a limit: the spreadsheet you open it in, the email service you send it with, the drive you copy it to, or the system you import it into. Those limits are real, they vary a great deal, and most of them are published. Here they are, taken from each vendor’s own documentation.

Spreadsheets

ProgramLimitWhat happens over it
Excel (.xlsx)1,048,576 rows and 16,384 columns per sheet; 32,767 characters in a cellLoads the rows that fit and warns that the data set is too large for the grid
Excel 97–2003 (.xls)65,536 rows and 256 columns per sheetSame, at a much lower number
Excel Data Model1,999,999,997 rows per tableWorks well beyond the sheet limit, but the rows cannot be scrolled or edited in a grid
Google Sheets10 million cells, rising to 20 million from September 2026; 18,278 columns“This file is too large to import directly into Google Sheets”

Two details matter. Excel’s limit is on rows, so a 2 GB file of short rows fails where a 2 GB file of long rows might not. Google’s limit is on cells, so the number of rows you can have depends on the number of columns: at 20 columns, 10 million cells is 500,000 rows. Google announced on 10 September 2026 that the limit is doubling to 20 million cells for all accounts, with the rollout for some business accounts starting on 28 September, so check which limit yours has before relying on the larger one.

We checked the Excel behaviour with a 2.5-million-row CSV: Excel 2021 loaded exactly 1,048,576 rows. We also found a less obvious limit. A value longer than 32,767 characters did not produce an error: the rest of it spilled into a new row, shifting every column after it. Why a CSV won’t open in Excel shows the details.

Email and File Transfer

ServiceLimit
Gmail, personal account25 MB of attachments; larger files are sent as a Google Drive link instead
Outlook.com25 MB per attachment
Microsoft 365 (Exchange Online) mailboxes35 MB per message by default; administrators can set up to 150 MB
Google Drive5 TB per file

For email, zip the file first: in our test a 99.4 MB CSV compressed to 25.4 MB, which is still just over Gmail’s limit, so a file that size also needs splitting. Reducing a CSV’s size compares the other options.

Disks and USB Drives

A drive formatted as FAT32, still common on USB sticks, cannot store a file of 4 GiB or more; Microsoft’s comparison of file systems lists the maximum file size as 4 GiB for FAT32 and 264−1 bytes for NTFS and exFAT. Apple documents a 263-byte maximum for APFS. In practice, only FAT32 gets in the way. Apple’s Disk Utility recommends exFAT for Windows-compatible drives over 32 GB, and reformatting erases the drive, so for a one-off copy, zip or split the file instead.

Import Tools

Systems that import CSVs publish their own limits, in rows, in megabytes or both. A few current examples:

ToolPublished limit
Shopify product import15 MB per CSV
HubSpot512 MB and 1,048,576 rows per file on paid plans; 20 MB on free tools
Salesforce Data Import Wizard50,000 records at a time
Salesforce Data Loader150,000,000 records per file
MailchimpFiles over 200 MB, or about one million contacts, “may cause import errors”
Google BigQuery4 GB per compressed CSV; 5 TB uncompressed

Splitting a CSV to fit an import limit covers more tools and how to work out the right part size, including the daily allowances some of them add on top.

Memory: The Limit Nobody Prints

Many programs read the whole file into memory before showing any of it, so the limit is your computer’s RAM rather than a published number. Excel is one: Microsoft notes that “in any 32-bit application, there’s a 2-GB limitation,” while “the 64-bit version allows all available physical RAM on the machine to be used.” (On 64-bit Windows, a later change doubled 32-bit Excel’s allowance to 4 GB.) pandas is another; its documentation says it “provides data structures for in-memory analytics, which makes using pandas to analyze datasets that are larger than memory somewhat tricky,” and offers a chunksize option to read a file in pieces.

Tools that stream the file, reading a piece at a time, avoid this limit. DuckDB queries a CSV on disk without loading it first. The tools on this site read the file in chunks in your browser and write their output to disk as they go, so a 10 GB file needs no more memory than a 10 MB one; their limit is free disk space.

What to Do When a File Is Over a Limit

  1. Measure it: the size in megabytes, and the number of rows, which is not the same as the number of lines — counting the rows in a CSV explains why.
  2. Make it smaller if it can stay whole: remove columns the destination does not need, or zip it for email and storage.
  3. Split it if it cannot: the CSV splitter splits by rows, by maximum size or into a set number of files, with the header in every part.
  4. Test before the real run: a generated sample file of the same size shows whether an import or a script copes, without risking real data.

FAQ

Frequently Asked Questions

What is the maximum size of a CSV file?

The format has none. RFC 4180, the document that describes CSV, sets no limit on file size, row count or the length of a value. A CSV can be as large as the disk it is stored on allows. Every limit you run into belongs to a program: the spreadsheet that opens the file, the email service that carries it, or the tool that imports it.

How many rows can a CSV file have?

As many as you like; nothing in the format counts them. Excel is where most people meet a number, because a worksheet holds 1,048,576 rows, header included, and Excel loads only that many from a longer file. Excel’s row limit explains what happens to the rest.

Can Excel open a 2 GB CSV file?

Size in bytes is not what decides it. The questions are whether the file has more than 1,048,576 rows, which Excel cuts off, and whether Excel has the memory to hold it. Microsoft notes that 32-bit Excel gets 2 GB of memory, or 4 GB on 64-bit Windows, while the 64-bit version can use all the RAM in the computer. A 2 GB file usually has far too many rows for a sheet anyway; the Data Model, which holds up to 1,999,999,997 rows per table, is the Excel route for files that size.

Why can’t I copy a large CSV to my USB drive?

The drive is probably formatted as FAT32, which cannot store a file of 4 GiB or more, however much free space it has. Drives formatted as exFAT or NTFS do not have that limit. Reformatting erases the drive, so the quicker fixes are to zip the CSV, which often shrinks it to a quarter of its size, or to split it into parts under 4 GB.

How big a CSV can Google Sheets import?

Google limits Sheets by cells rather than bytes: rows multiplied by columns, across every tab of the spreadsheet. The limit was 10 million cells and Google is raising it to 20 million, rolling out from September 2026. When a file is too big you may see “This file is too large to import directly into Google Sheets”, and Google’s help points to Connected Sheets, which uses BigQuery. When a CSV is too large for Google Sheets covers the options.

How can I test whether a program copes with a large CSV?

Give it a test file before the real one. The sample CSV generator makes realistic files of any row count or size up to 20 GB, including a preset of 1,048,577 rows — one more than Excel holds — and can add awkward values such as commas, quotes and line breaks inside fields. Nothing is uploaded; the file is built on your computer.

Guides

See All 20 CSV Guides