Our maintenance plan shrinks the database every night so the file stays small. A colleague says that is bad. Is it?
Should I shrink my SQL Server database files regularly?
Resolved
SQL
IA
Ivan Arnold October 21, 2026
2 replies
2,571 views
Reviewed by moderators
2 participants
Yes, a regular shrink is bad practice.
Shrinking moves pages from the end of the file to free space near the start. That causes heavy fragmentation, so the indexes get worse and queries slow down. After the shrink the database grows again at the next busy time, and growth costs time as well. You pay for the same space twice.
Better approach:
• Leave enough free space in the file for normal growth, and set a fixed autogrowth size.
• Shrink only once in special cases, like after a one time purge of a huge amount of data. Then rebuild the indexes.
• Keep an eye on the log file with log backups, so it does not grow in the first place.
Remove the nightly shrink from the plan.
Removed the shrink step and set the file to a sensible size. Thanks.