A #SPILL! error occurs when Excel cannot output the result of a dynamic array formula into the specified range. This is commonly caused by blocked output ranges, merged cells, or incompatible data types.