What is SQL Server memory grant spill and how does it impact query execution?
Updated May 17, 2026
Short answer
Memory grant spill occurs when a query receives insufficient memory and spills intermediate data to tempdb.
Deep explanation
Operators like sort and hash join require memory grants. If the granted memory is insufficient, SQL Server spills intermediate results to tempdb worktables. This introduces IO overhead and slows execution significantly. Spills often occur due to poor cardinality estimation or parameter sniffing. SQL Server may later adjust grants using memory grant feedback, but initial executions can still suffer.
Unlock with a Pro subscription to view this section.
View pricingReal-world example
No real-world example available yet.
Unlock with a Pro subscription to view this section.
Upgrade to ProCommon mistakes
No common mistakes listed yet.
Unlock with a Pro subscription to view this section.
Upgrade to ProFollow-up questions
No follow-up questions available yet.
Unlock with a Pro subscription to view this section.
Upgrade to Pro