Software has a way of accumulating on your Windows machine, and for the sake of security, system performance, and disk space, it's a good idea to clear out junk files every so often. Sometimes Windows may make you do an in-place upgrade (which happens frequently for members of the Insider program). This means that the operating system is completely re-installed, but you keep your files and installed programs. A side-effect of this process is a lot of leftover files that you may never use again, including an archived copy of the old Windows build that you just upgraded from. If you find yourself doing one of these upgrades, or if you just want to check for stuff you can get rid of, there are a few easy things you can do that don't require installing special software.
The Disk Cleanup tool
Every storage device in your computer has access to the Disk Cleanup tool. Find it by clicking the Start button, typing "disk cleanup" (without the quotes), and clicking the Disk Cleanup shortcut in your search results. (Click and drag this shortcut to your desktop or taskbar for easier access next time.) You can also find the tool by right-clicking a storage device in File Explorer, selecting Properties, and clicking the Disk Cleanup button to the right of the pie chart.
Sometimes the shortcut doesn't show up in your search results. If this is the case, instead of typing "disk cleanup," type "free up disk space" (without the quotes). A phrase may work when the name of the program doesn't.
If you have a lot of stuff to clean up, it may take the tool several minutes to analyze your situation and get your cruft organized for deletion. Once that's done, you'll get a new window listing separate deletable elements. Some boxes are pre-checked, such as the one next to Temporary Internet Files.
Browser and thumbnail caches
Browser and thumbnail caches can consume several gigabytes if you use Internet Explorer or Edge as your main browser. When you load a webpage, it gets stored here for quicker access later, so cleaning out the cache can make future browsing slower.
Chrome and Firefox caches get cleaned from within those apps through a menu accessed by pressing Ctrl-Shift-Del when the browser is open. This shortcut also works for IE and Edge, and it's preferable to do it within the browser, since you can elect to keep things like cookies and passwords while deleting everything else. (Microsoft Edge is exclusive to Windows 10, so don't be alarmed if you can't find it in Windows 7 or 8.1.)
Since you're likely to reuse the contents of the cache on a regular basis, and it will gradually bloat up again, you may not want to clear the cache unless you're uninstalling the browser. You might also want to clear cache if you have security concerns -- an unauthorized user who gets access to the device can access these caches and possibly extract private information.
The Thumbnails item is for all the small images that File Explorer creates when you tell it to display media files using the icon view. Pictures and videos don't have thumbnails by default, so Windows generates them. As a result, the Thumbnails category in the Disk Cleanup tool can grow over time. But if you clear it out, Windows will have to re-generate those images the next time you view a folder that's set to view by icons. Each thumbnail can take a second to create, which adds up if you're a photographer or videographer. So we recommend leaving the Thumbnails item in Disk Cleanup unchecked, unless its size is creating issues.
The biggest hoarders of your disk space are probably system files, so click the "Clean up system files" button to access them. This will perform another analysis, which can take a few minutes, especially if it detects Windows Update items that can be cleaned up. Then it will load a window that looks exactly like the analysis results window you saw in Disk Cleanup. This time, however, there are additional items in the list. If you're using Windows 7, you may find several gigabytes of Service Pack Backup Files listed. In theory, this archive can be used to undo a service pack.
Windows Update Cleanup also frequently has several gigabytes of files you can delete. These are the update files themselves, which Windows may archive for easier access later, if needed. Checking boxes next to these and clicking the OK button will delete all these files. If you do that, however, keep in mind that Windows may not be able to roll back to the older versions of the system files that the updates have changed, unless you made an external backup image of your C: drive first. And unfortunately you can't pick which Update Cleanup files you want to keep -- it's all or nothing.
Windows uses System Restore to preserve system files in case they're accidentally deleted or corrupted. A system restore is like a bookmark or snapshot that the operating system can go back to. It's not a full backup, so it may not help you if you can't boot Windows at all, but Windows 7 makes periodic bookmarks that can end up using a lot of space. In Windows 8.1 and 10, System Restore is disabled by default, so you shouldn't need to mess with its settings unless you've enabled the feature yourself.
Unfortunately, Windows doesn't let you choose which restore points you want to keep, nor does it easily tell you how much disk space your restore points are taking up. The Disk Cleanup tool lets you delete all but the most recent one.
To do so, go to the Disk Cleanup tool. Click "Clean up system files," click the More Options tab, go down to the System Restore and Shadow Copies section, click the Clean Up button, and click the Delete button to confirm.
To delete the most recent restore point as well, you need a different tool. Click the Start menu button, right-click Computer, select Properties, click the System Protection link on the left-hand side, and click the Configure button to access your System Restore settings. If you don't have a Computer shortcut on your Start menu or your desktop, click the Start button, type "computer" without the quotes to get it to come up in your search results, right-click it, select Properties, and you will be at the window where you click System Protection. Then click Configure.
You can disable System Restore altogether, tell Windows what percentage of disk space you want to dedicate to System Restore, and click the Delete button to delete all restore points. This window also shows you how much space your System Restore points are taking up. By default, Windows 7 sets aside about 5 percent of your Windows drive for restore points.
When you turn off your device, Windows stores the programs you're running and your open files in a large file, the hibernation cache. Sleep mode, by contrast, keeps this material in your system RAM and puts the device in a low-power mode. Hibernation mode doesn't draw battery power, but it takes longer to boot up than restoring from sleep mode, which is more or less instant. Unless you're using a mobile device that has trouble with battery life, you can usually disable hibernation, and the storage space that you save is roughly equal to the amount of system RAM.
To do so, click the Start button, type "cmd" (without the quotes), right-click cmd.exe, select Run as Administrator, and click Yes to confirm. This is the Windows command prompt. Paste the "powercfg.exe /hibernate off" (without the quotes) into the command prompt. Ctrl-V doesn't work here, though. Instead, you have to right-click in the window and select Paste. Then hit Enter. If you want to re-enable hibernation mode later, paste "powercfg.exe /hibernate off" without the quotes. The change will take effect immediately.
The Recycle Bin
When you delete a file, Windows doesn't erase it by default. The file just goes to the Recycle Bin, where it will stay until you tell Windows to empty the bin. So the bin needs to be checked periodically to make sure your disk space isn't being used up by things that you no longer need.
You can also adjust how the Recycle Bin behaves. To do so, open the File Explorer (press Windows-E), find the bin in the left-hand pane, right-click it, and select Properties. The bin might not be displayed by default, in which case you need to right-click the left-hand pane and select Show All Folders.
In the Recycle Bin properties window, you can tell Windows the maximum amount of space you want to use for the bin. The default is 5 percent of your C: drive's storage capacity, and you can increase that to 10 percent. You can also tell Windows to skip the bin altogether, as well as disable the confirmation prompt that pops up when you attempt to delete a file. When you're done making your changes, click OK.
Automating system cleanup
We said at the beginning that you don't need special software to do any of this, but it can save you time. CCleaner is the go-to third-party tool for disk cleanup. It will analyze your system in a few seconds, itemize what that you can clean out, and delete it all with a click. Since it cleans out browser caches and other potentially useful items by default, you should tweak it to make sure that it's deleting the actual junk and not things that you might reuse later. If you like how CCleaner works, you can get the Pro version for $24.95.