Shrink the Size of Winsxs in Windows 7

Microsoft has never met a gigabyte of storage space it didn’t like for underlying operating system needs. As hard drive capacities have increased, this has gotten worse. While I normally wouldn’t care, the introduction of solid state drives have changed the game. Now costs for storage space have gone back up and limits have contracted.

Once you move to an SSD, you won’t go back. I have the luxury of having a 256 GB SSD in both my home and work laptops. If you threatened to take either from me, I may shoot you.

This evening I was doing some drive clean up using my favorite disk space analyzer WinDirStat. It showed that besides my ridiculously huge Users directory (I have a couple of virtual machines in there), the Windows directory itself was consuming 31.9 GB of space. Good gravy that’s crazy!

The worst offender was the Winsxs directory. To read more about what Winsxs actually does, go here.

I did a bit of googling to try to figure out if and how that folder could be pared down. Most posts mentioned that it is critical to the OS, don’t try to delete it or your sky will fall and your Windows will crash with it. Other sites mentioned a tool that came out with Vista, that Microsoft neglected to include with Windows 7 SP1.

Then I came across this forum.

Which pointed me to this post.

Which gave me this command:

dism /online /cleanup-image /spsuperseded

What this command does is remove superseded updates that are no longer needed after the installation of Service Pack 1. These updates are still kept around in case you want to uninstall SP1. As I have no plans on doing so, these files serve no purpose other than aggravating my quest to have more free hard drive space.

And that command gave me back 5 GB of space. A 6.5 GB winsxs is still crazy, but just not as stupid crazy as 11.5 GB. I’ll take a 43% reduction whenever I can get it.

Now to shrink the size of the rest of the Windows directory!