How To Fix The #SPILL! Error In Excel (2026)
The #SPILL! error means Excel cannot fit the results of a formula into the cells it needs.
Most of the time something is sitting in the way, and Excel will highlight it for you.
The fixes below come from Microsoft Support and go from the most common cause to the least.
Table of Contents
- Quick answer: what the #SPILL! error means
- What spilling means in Excel
- Fix 1: clear the cells in the spill range
- Fix 2: unmerge cells in the spill range
- Fix 3: take the formula out of an Excel table
- Fix 4: stop the spill running past the edge of the sheet
- Fix 5: check formulas whose size keeps changing
- Fix 6: shrink an array that is too large
- Fix 7: when Excel cannot say why
- PivotTable #SPILL! errors
- Why older VLOOKUP formulas now spill
- Where the error applies
- Which fix to try first
- Official sources
- More Word, Excel and PowerPoint guides
Quick answer: what the #SPILL! error means
Excel shows #SPILL! when a formula returns several results and Excel cannot place all of them in the cells below or beside it.
| Cause | Quick fix |
|---|---|
| Something is in the spill range | Select the error cell, open the error alert, choose Select Obstructing Cells, then clear or move what is there |
| Spill into merged cells | Unmerge the cells or move the formula |
| Formula inside a table | Move the formula out, or convert the table to a range |
| Whole-column reference | Reference only the cells you need |
| Result runs past the sheet edge | Move the formula up or shrink its references |
| Array too large for memory | Point the formula at a smaller range |
What spilling means in Excel
A dynamic array formula writes its answers into a block of cells that Excel calls the spill range.
When you select the formula cell, a dashed border outlines the range Excel wants to fill.
If anything stops Excel from filling that block, the formula cell shows #SPILL! instead of the results.
Microsoft lists this error for Excel for Microsoft 365, Excel 2024, Excel 2021, Excel 2019, Excel 2016 and the mobile and web versions.
Fix 1: clear the cells in the spill range
This is the most common cause, and Excel can point you straight at it.
- Select the cell that shows #SPILL!.
- Look at the dashed border to see where the results are meant to go.
- Select the error checking alert that appears next to the cell.
- Choose Select Obstructing Cells to jump to whatever is in the way.
- Delete or move those entries.
Once the block is empty, the formula spills on its own.
Fix 2: unmerge cells in the spill range
A spilled array cannot spill into merged cells.
Use Select Obstructing Cells to find the merged cell, then unmerge it.
The other option Microsoft gives is to move the formula to a range that does not touch any merged cells.
If merging came from an old report layout, our guide to hiding and unhiding rows and columns in Excel helps you tidy the area around the formula.
Fix 3: take the formula out of an Excel table
Spilled array formulas are not supported inside Excel tables.
You have two ways to fix it.
- Move the formula to a cell outside the table.
- Select the table, then choose Table Design > Tools > Convert to range.
Converting removes the table features, so move the formula first if you want to keep the table.
Fix 4: stop the spill running past the edge of the sheet
Excel can also return #SPILL! when the result would run off the last row or column of the worksheet.
A formula such as =SORT(D:D) in cell F2 fails because it tries to return the whole column starting one row down, and moving it to F1 clears the error.
The same problem appears with =VLOOKUP(A:A,A:C,2,FALSE) in E2, because modern Excel looks up all 1,048,576 values in the column.
| Option | Formula example | Works in tables | Returns a spill |
|---|---|---|---|
| Reference only the values you need | =VLOOKUP(A2:A7,A:C,2,FALSE) | No | Yes |
| Reference one row value and copy down | =VLOOKUP(A2,A:C,2,FALSE) | Yes | No |
| Use the @ operator and copy down | =VLOOKUP(@A:A,A:C,2,FALSE) | Yes | No |
Microsoft says to use the first option if you want a spill and the second or third if you work inside a table.
Fix 5: check formulas whose size keeps changing
A volatile function can make the result a different size on each calculation pass.
Microsoft gives =SEQUENCE(RANDBETWEEN(1,1000)) as an example, and RAND and RANDARRAY act the same way.
If the size never settles, Excel returns #SPILL!.
Microsoft notes that OFFSET, INDIRECT and TODAY do not cause this particular error.
Its page gives no fix steps for this cause, so the practical step is to remove the function that changes the array size.
Fix 6: shrink an array that is too large
Excel returns #SPILL! when a spilled array is too big for the memory available.
Microsoft says to reference a smaller array or range.
If Excel slows down or stops while you do this, see our guide to fixing Excel not responding or freezing.
Fix 7: when Excel cannot say why
Microsoft lists an Unrecognized or Fallback cause for cases where Excel cannot identify the problem.
Check that the formula includes every required argument for its function.
If other errors appear in the same sheet, our guide to #N/A, #VALUE! and #REF! errors covers those separately.
PivotTable #SPILL! errors
Microsoft says a PivotTable can also return #SPILL! when its range is not blank.
Its page states that the PivotTable version is currently available only to Microsoft 365 Insider program participants.
The cause and fix match the first one above: find the obstructing cells and clear them.
Why older VLOOKUP formulas now spill
Older versions of Excel used only the lookup value on the same row as the formula.
Dynamic array Excel considers every value you give it, so a full column passed as the lookup value is treated as a list of more than a million lookups.
That is why a formula that worked for years can show #SPILL! after a file moves to a newer version of Excel.
The @ operator tells Excel to use only the value on the formula's own row, which restores the old behavior.
Where the error applies
| Excel version | Listed by Microsoft |
|---|---|
| Microsoft 365 (Windows and Mac) | Yes |
| Excel 2024 and 2021 | Yes |
| Excel 2019 and 2016 | Yes |
| Excel for the web, iPad, iPhone and Android | Yes |
| PivotTable #SPILL! | Microsoft 365 Insider participants only |
Microsoft lists the same causes for every version on that list.
After you clear the cause, select the formula cell again to confirm the dashed border now shows results inside it.
Which fix to try first
| What you see | Try this |
|---|---|
| A dashed border with content inside it | Fix 1 |
| Merged cells nearby | Fix 2 |
| Formula sits in a table | Fix 3 |
| Formula uses A:A or D:D | Fix 4 |
| Formula contains RAND or RANDBETWEEN | Fix 5 |
| Huge ranges, Excel is slow | Fix 6 |
Work down the list from the top, because an obstructing cell is the cause far more often than the others.
Official sources
This guide follows Microsoft Support pages, and you can read them for the latest wording.
- How to correct a #SPILL! error (Microsoft Support)
- #SPILL! error: extends beyond the worksheet edge (Microsoft Support)
More Word, Excel and PowerPoint guides
- Excel Error: There Isn't Enough Memory To Complete This Action
- How To Combine Data From Multiple Sheets In Excel (2026)
- How To Keep Leading Zeros In Excel (2026)
- How To Round Numbers In Excel With ROUND (2026)
- How To Use AutoSum And The SUM Function In Excel (2026)
- How To Find And Replace In Excel (2026)