Excel stops loading at 1,048,576 rows, so a bigger file silently loses data and gives wrong totals. This guide shows how to pull a large file and a lookup file into Power Query, merge them, and summarise the result with the Data Model and a PivotTable. It suits anyone on Excel for Windows or Mac.
YouTube video: How to Handle Large Excel Files (Over 1 Million Rows)
Caption availability is unknown. Check the CC control in the YouTube player.
- Video length
- 4 min 49 s
- Time to do it
- 20 minutes
- Difficulty
- Medium
- Steps
- 10
What you need
Steps
Check the row count of your file first. A worksheet holds 1,048,576 rows, and anything past that is dropped without a warning, so totals look fine but are wrong.
Open a blank workbook and go to Data, then Get Data, then From File, then From Text/CSV. Pick the large file and click Transform Data rather than Load.
In the Power Query Editor, set the data type on each column and delete the columns you do not need. The status bar shows the full row count, well past the sheet limit.
Repeat the import for the lookup file so you have two separate queries in the editor.
Select the large query, then Home and Merge Queries. Click the matching key column in each table, choose a Left Outer join, and press OK.
Use the expand icon on the new column to bring in only the lookup fields you want, then rename the result.
Click Close and Load To, choose Only Create Connection, and tick Add this data to the Data Model. The full data now lives in the model, not on a sheet.
Go to Insert, then PivotTable, and pick the Data Model as the source. Build your summary as usual, since the model has no 1,048,576 row cap.
On a Mac, Power Query works the same way but there is no Data Model. Load the merged result to a worksheet if it fits, or export it to CSV instead.
To get every row out as one file, export the merged query to a single CSV. Ternlux can also join the files, add columns described in plain English, and export all rows.
Tips and common mistakes
Never double-click a huge CSV to open it in Excel, because it will truncate on load and you may not notice.
Set column types in Power Query before merging, or the key columns may fail to match.
Keep the key column the same type in both files, for example both as text, to avoid missing matches.
Save the workbook as.xlsx before loading to the Data Model, since older formats do not support it.
Questions
Why does Excel cut off my data at 1,048,576 rows?
That is the hard limit for a single worksheet. Rows past it are not loaded, so any formula or PivotTable built on that sheet is incomplete.
Can Power Query handle more rows than a worksheet?
Yes. Power Query reads and transforms the whole file, and the Data Model can hold far more rows than a sheet. Only the final PivotTable output is limited by the grid.
Do I need the Data Model on a Mac?
No. Excel for Mac has Power Query but not the Data Model, so load the merged result to a sheet if it fits or export it to CSV.
The notes are drafted automatically from video details and general task knowledge. How the guide was prepared
Report a correction


