Summary

If you’re running out of storage on your PC, the best thing to do is to find and remove old, unwanted files. Windows 11 offers multiple ways to find those storage-hogging items, and we’ll show you what those ways are and how to use them in this guide.

Using Storage Sense

Storage Sense is a built-in Windows 11 feature that helps automaticallyclean up old files. You can configure various options in the feature so it only deletes the files using the specified criteria. You can run the feature manually, or you can set it to run automatically at the specified time.

To configure this feature, launch the Settings app by pressing Windows+i. From the left sidebar, select “System.” On the right pane, choose “Storage.”

‘System’ and ‘Storage’ highlighted in Windows 11 Settings.

In the Storage Management section, turn on the toggle next to “Storage Sense,” then click “Storage Sense.”

You’ll now configure Storage Sense’s behavior. At the top, enable the option in the “Cleanup of Temporary Files” section so that temporary files are automatically deleted.

‘Storage Sense’ highlighted in Windows 11 Settings.

Turn on the “Automatic User Content Cleanup” toggle. Then, configure various options as follows:

To run the feature now, click “Run Storage Sense Now.” It will start removing the chosen files.

Storage Sense configuration options in Windows 11 Settings.

With Microsoft PC Manager

PC Manager is a built-in Windows 11 appthat lets you analyze your storage space and remove downloaded files, large files, and duplicate files. It has a variety of filters that let you quickly find the files you want to let go of.

To use the app, open Windows Search, typePC Manager, and choose the app in the search results. When it opens, from the left sidebar, select “Storage.” On the right pane, in the Files Cleanup section, you’ll see various options.

File cleanup options in PC Manager.

The first option is “Downloaded Files,” which lets you remove the files you’ve downloaded using the installed web browsers. Click it, and it’ll open a window listing your recent file downloads. You can sort these files by their type using the tabs at the top.

Then, select the files you’re happy to let go of. At the bottom, you’ll see the storage space you’ll reclaim after deleting these files. To remove the files, click “Permanently Delete.”

Downloaded files and ‘Permanently Delete’ highlighted in PC Manager.

The second option in PC Manager is “Large Files.” As you can guess, it lets you find and remove large files. You can specify the file size here so it only finds files larger than that.

Click the option and use the “Size” drop-down menu to specify your file size.

‘Size’ drop-down menu highlighted for large files in PC Manager.

When you see the files listed, choose the ones you want to remove and click “Permanently Delete.”

And that’s it.

Another useful option is “Duplicate Files.” This option finds the duplicates on your storage and helps you remove them all at once. Use it by clicking the option, letting the feature find any duplicates, choosing the files you want to remove, and clicking “Permanently Delete.”

And you’re all set.

Using Command Prompt

If you prefer Command Prompt, use theForFilescommand to automatically find and deletefiles older than the specified number of daysfrom select locations. You can run the command each time you want to clean up your storage.

To use it, open Windows Search, search forCommand Prompt, and select “Run as Administrator.”

Large files and ‘Permanently Delete’ highlighted in PC Manager.

In the User Account Control prompt, choose “Yes.”

In Command Prompt, type the following command. Replace “FolderPath” with thefull path to the folderwhere you want to delete files. Replace “60” with the number of days a file must have existed on your storage for it to be deleted. (Make sure to keep the - (minus sign) before the day number.)

Duplicate files and ‘Permanently Delete’ highlighted in PC Manager.

Here’s what each parameter does in this command:

Note that Command Prompt will delete your files quietly, meaning it won’t ask for a confirmation. And that’s it.

If you want to use this command multiple times, instead of typing it each time,turn it into a batch script. This way, you simply run a file to execute the command and delete the specified files.

‘Run as Administrator’ highlighted for Command Prompt in Windows Search.

To do that,open Notepad, copy and paste your ForFiles command, and select File > Save As. Click the “Save as Type” drop-down menu and choose “All Files.” Select the “File Name” field, type a name for your script, add.batat the end of the name, and click “Save.”

When you want to run your command, right-click your batch script and choose “Run as Administrator.”

Save the ForFiles command as a batch file.

You can integrate this batch script with Task Manager, and Task Manager will run the script at your specified time. This basically automates the entire process of finding and removing old files from your specified folders.

And that’s how you get rid of the files sitting on your Windows 11 machine for too long. Enjoy using a decluttered computer!