What is Disk Cleanup?
Disk Cleanup scans a drive for files Windows can safely remove and lists them by category, with the space each would free. It is a quick first step when a drive is nearly full, which on its own can cause failed updates, slow sign-ins and app crashes. Microsoft has been moving the same functions into the Settings app (Storage Sense and Cleanup recommendations), but cleanmgr is still included in Windows 11.
How to run it
- Press Win+R and type
cleanmgr, search Start for Disk Cleanup, or right-click a drive in File Explorer and choose Properties > Disk Cleanup. - Pick the drive if asked. Windows calculates how much it can free.
- Tick the categories you want, reading each description, then click OK and Delete Files.
The first pass covers only files the current user can remove. Click Clean up system files, which needs admin approval, to rescan with system categories added.
Common categories
| Category | Notes |
|---|---|
| Temporary files and Temporary Internet Files | Safe to remove |
| Thumbnails | Rebuilt automatically when folders are viewed |
| Recycle Bin | Permanently deletes what the user discarded; confirm first |
| Delivery Optimization Files | Cached update data shared with other PCs |
| Windows Update Cleanup (system files) | Superseded update files; often the largest item |
| Previous Windows installation(s) (system files) | The Windows.old folder kept after a feature update; deleting it removes the option to go back to the earlier version |
| Error reports and upgrade log files | Logs that may help troubleshooting; keep them until the problem is solved |
Some versions also list the user's Downloads folder. Leave it unticked unless the user has approved deleting it, because it holds personal files. Disk Cleanup is for system clutter, not user data.
More Options tab
After Clean up system files, a More Options tab appears. Programs and Features opens the uninstall list, and System Restore and Shadow Copies deletes every restore point except the most recent one.
Command-line switches
cleanmgr /d C:opens Disk Cleanup for a specific drive.cleanmgr /sageset:1lets you choose categories and saves them as profile 1.cleanmgr /sagerun:1runs that profile without prompting, so it can be scheduled with Task Scheduler.
Disk Cleanup vs. look-alike tools
- Storage Sense (Settings > System > Storage) cleans temporary files and the Recycle Bin automatically on a schedule, and shows cleanup recommendations.
- Optimize Drives (
dfrgui) defragments hard drives and sends TRIM to SSDs. It frees no space. - chkdsk checks and repairs file-system errors. It does not remove clutter.
- Disk Management (
diskmgmt.msc) creates, resizes and formats partitions and volumes.
Disk Cleanup on the CompTIA A+ exam
Disk Cleanup is one of the Windows tools in Core 2 (220-1202) objective 1.4. Know the cleanmgr command, the Clean up system files button, and which categories carry risk: Recycle Bin, Downloads and Previous Windows installation(s). Cues: low disk space warning or an update that fails for lack of space, think Disk Cleanup with system files; the user may want to roll back a recent feature update, do not delete Previous Windows installation(s); the question says defragment or optimize, think dfrgui, not cleanmgr.