sodcalculator

10 Tech How-To

Excel Spill Error: How to Fix a #SPILL! Error

Guide 10-39300 · Updated · Step by step

A #SPILL! error appears when an Excel formula needs to return several results but cannot place them in the cells it needs. Clear the obstruction or adjust the formula’s output range, then check for less obvious causes such as merged cells or a formula inside an Excel Table. These steps apply to current desktop versions of Excel; some menu labels may differ slightly on the web or Mac.

What You’ll Need

  • The workbook containing the error, preferably with a saved backup if it holds important data.
  • Access to the cells around the formula, so you can inspect and edit its intended spill range.
  • Optional: Excel’s error menu, which can identify the specific reason for the blockage.

Step-by-Step

  1. Find the formula that is returning #SPILL!. Select the cell showing the error. Excel usually outlines the range where the formula wants to return results with a dashed border. This is the spill range. The formula is normally entered in just one cell—the top-left cell of that range—and its results fill the other cells automatically.
  2. Read Excel’s explanation. Select the warning icon beside the error, if it appears, and review the message. In many desktop versions, choosing Select Obstructing Cells takes you to a cell that is blocking the result. The wording and available options can vary by version. If the icon is absent, inspect the outlined range manually.
  3. Check for occupied cells in the spill range. Look for values, formulas, spaces, or other content anywhere in the outlined area. A cell that looks blank may contain a space or a formula returning an empty string. Select likely blockers and inspect the formula bar or press Delete to remove content only when you are sure it is safe to do so. If you need the content, move it elsewhere instead.
  4. Check for merged cells. Dynamic array results cannot spill into a range containing merged cells. Select the obstructed area and look at Home > Merge & Center. If cells are merged, choose Unmerge Cells and try the formula again. Unmerging can change the layout, so check the affected worksheet before making the change.
  5. Make room for the full result. The formula may return more rows or columns than expected. Clear or move content in the entire spill range, not just the first cell. If the result could be very large, revise the formula to return fewer rows or columns—for example, filter the source data or narrow the referenced range.
  6. Check the worksheet edge. A formula cannot spill beyond the last row or column of a worksheet. If its results would extend past the grid, move the formula to a position with enough room or change the formula so it returns a smaller array.
  7. Check whether the formula is inside an Excel Table. Dynamic array formulas generally do not spill from cells within a table. If the formula is in a table column, place it in a normal worksheet cell outside the table, leaving a clear area for results. Alternatively, restructure the calculation to return a value for each table row rather than a spilled array.
  8. Review the formula for changing array sizes. Functions such as FILTER, UNIQUE, SORT, and SEQUENCE can return a different number of results as their inputs change. Confirm the source data and criteria are correct, and ensure the worksheet has space for the largest expected result. If the formula refers to a changing range, consider limiting it to the data you actually need.
  9. Retry and confirm the result. After removing the cause, press Enter in the formula cell or edit the formula and press Enter. Excel should recalculate and fill the spill range. Check that the results occupy the expected cells and that no existing content was overwritten or displaced.

Common Mistakes

  • Deleting the formula instead of the obstruction. The formula cell is usually not the problem. Identify and clear or relocate the blocked cell, while keeping the formula intact.
  • Clearing only cells that look nonempty. Spaces and formulas that display blank can still block a spill. Inspect the formula bar and the full outlined range.
  • Assuming the error means the formula is invalid. #SPILL! often means the formula is valid but Excel cannot display its results in the intended cells. Still, review the formula if its output is unexpectedly large.
  • Using Cut or deleting cells without checking dependencies. Moving or removing worksheet content can affect other formulas and layouts. Save a copy first when changes might have wider consequences.
  • Trying to force a spill inside a table. Moving the formula outside the table is usually simpler than repeatedly changing the formula while it remains in a location where dynamic arrays cannot spill.

Tips

  • Use the dashed outline as a map: it shows where Excel needs to place the results.
  • When a formula’s output can grow, keep the area below and to the right of it clear. This prevents future changes in the source data from creating a new error.
  • To remove cell contents without changing formatting, select the relevant cells and press Delete. Avoid deleting entire rows or columns unless you intend to change the worksheet structure.
  • If a large result is not useful, adjust the formula’s criteria or source range instead of clearing an extensive area of data.
  • Save a copy before unmerging cells or changing a table’s structure, especially in a shared or business-critical workbook.

Troubleshooting

The warning says the spill range is not blank, but the cells look empty. Select cells in the outlined area one at a time and inspect the formula bar. A space, apostrophe, or formula returning an empty string may be present. Remove it only if it is not needed.

The error returns after I clear the cells. Check whether the formula recalculates to a larger result when source data changes. Also check for a merged cell, a table location, or a spill range that reaches the worksheet edge. Read the warning again after each change; a different cause may become visible.

I cannot find an obstruction. Confirm that you are checking the entire dashed outline, including cells outside the visible area. Use the error menu’s obstruction-selection option if available. Also inspect merged cells and whether the formula sits inside a table.

I need to keep the cells that block the formula. Move the formula to a different clear area or move the existing content elsewhere. If neither is practical, change the calculation so it returns fewer results or use a different layout.

The formula still shows #SPILL! after the obvious fix. Save the workbook, select the formula cell, and review the current warning. Check for more than one obstruction and confirm the formula is in a location that supports a spilled array. If the workbook is shared, make sure another edit has not restored content in the spill range.

Frequently Asked Questions

What does #SPILL! mean in Excel?
It means a formula is trying to return multiple values, but Excel cannot place the complete result in the cells it needs.

Can I fix #SPILL! by deleting the formula?
You can, but that removes the calculation rather than fixing its cause. Usually, clear or move the obstructing content, or adjust the formula’s output.

Why does #SPILL! appear when cells look blank?
A cell may contain a space or a formula that displays an empty string. Those cells can still block the spill range.

Can a formula spill inside an Excel Table?
Dynamic array formulas generally cannot spill from within a table. Put the formula in a clear worksheet area outside the table or redesign it for row-by-row results.

Will clearing the spill range delete my formula?
Not if you select only the blocked cells and leave the formula cell alone. Check your selection before pressing Delete.

Does #SPILL! mean the formula is wrong?
Not necessarily. It commonly indicates a space or layout issue, though you should review the formula if it is producing an unexpectedly large result.

Related

General steps for current mainstream versions; menus can differ by device and version. See the disclaimer or report an error.

More in this bed

The whole Tech How-To bed →