How to Delete Temporary Files in Windows 11

Temporary or Temp Files take up lots of storage space on your Windows storage and due to this you may experience a system lagging issue. Well, one of the best methods to free up space on Windows 11, 10, 8, and 7 is to delete temp files. But first of all, you must know about the temporary files and why they exist on your PC.

What are Temporary (Temp) Files on Windows?

Technically, the Temporary files were created by the Windows operating system as the backup file for certain programs but usually, they are temporary files and they occupy large storage space on your computer or laptop.

Mostly the temporary files were stored on the temp folder on Windows. But the location of the folder is different in various computers or laptops along with the windows version. You can easily get rid of the temp files and increase your PC performance in less than a minute.

Here in this article, we are going to explain how you can delete temporary files using different methods.

how to delete temporary files windows 10
Image Credit:

How To Delete Temporary Files on Windows 11, 10, 8 and 7

There is more than one way to delete temp files on Windows and in this article, we are going to cover all the methods that you can apply in order to clear temp files without having a hassle.

In this guide, we are showing how to delete temporary files on Windows 10 and technically you can follow these steps on older versions of Windows such as Windows 8, 8.1, 7 XP, and Vista in order to delete them.

Delete Temporary Files Windows 11,10,8 and 7

Follow the below-given steps to delete temporary files in less than a minute.

Press the Windows + R keys together to open the RUN dialog box.

windows + r keys

In the dialog box, Enter the following command line and hit enter button.


This is one of many Windows Environment Variables that are used to access or operate programs in lesser time with the help of the command prompt or RUN dialog box.

clear temp files windows 10
How to Delete Temporary Files in Windows 11

Temp Folder will be pop-up on your screen. The path of the Temp folder will be like this C:\Users\[username]\AppData\Local\Temp that you can also use to open the Temporary Folder on Windows from My Computer address bar.

You need to Press the CTRL+A button to select all the files and folders within the temp folder in order to delete them.

Note: If you’re thinking are these Temp Files were important for the Windows. Then you must know that, if any Temp files are still in use then Windows will not allow you to delete them. It’s simple is that.

windows 10 temporary files

Once you’ve selected all temp files and folders you can easily delete them using the Delete button from the keyboard or the right click on the screen to open the menu list and select the “Delete” option from it.

Select the Skip option if the File in Use message will pop up during the process of deleting the files.

Basically, this message tells you that that particular files or folder in use by the system that you’re trying to delete to you need to select the SKIP button in order to leave those files and continue the deleting process.

The deleting process may take a few seconds if you have got a few temp files but in case you’ve got a larger number of temp files then it could take a few minutes. Once the deleting process is complete you’ll eventually see the empty folder and you can freely close the temp folder window.

Note: But if you’re deleting a massive amount of temp files or folders then these files will be gone to the Recycle Bin. To make the confirmation you need to access the Recycle Bin from the desktop icon.

You need to empty the Recycle Bin. To do so, you need to right-click on the Recycle Bin icon to open the menu options and select “Empty the Bin”. It takes a few seconds to clear the recycle bin in less than a minute.

Delete Temporary Files or Folders on Windows Using Command

As we said, there are multiple methods to delete temporary files on Windows and this is one of the fastest ways to delete temp files. In this method, you need to use the Command Prompt and enter the command line and all temporary files and folders will be deleted in a second.

Follow the below given step-by-step instructions in order to delete temp files using cmd.

Technically, in this method, you need to create your own mini-program to delete all temporary files automatically once you execute the command.

Open the Notepad or Text Editor enter the following command line and save the file with the . BAT extension. Remember you need to save the file .Bat in the end, not .txt extension.

rd %temp% /s /q

“q” parameter in the command line bypasses the confirmation message. Whereas the “S” parameter will delete all files and subfolders within the temp folder.

what are temp files

Once you save the file on the preferred location. Double click on the file and all the temp files will be automatically deleted.

Alternatively, in case if %temp% variable does not for you.

Then you can place the variable with the temp folder address

rd "C:\Users\USERNAME\AppData\Local\Temp" /s /q

In place of the USERNAME, you need to enter your PC name and save the file with .BAT extension. Again run the file to delete all the temp files automatically.

Delete Temporary Files Using Third-Party Utility

You can also use third-party programs to delete all temporary files along with other useless files to boost your PC performance. For Windows 10 or later versions of the operating system, we recommend you to use the CCleaner program. Which is one of the best clean-up tools for Windows.

What is Ccleaner?

CCleaner is a tool developed by Piriform for removing possibly unwanted files and invalid Windows Registry entries from a computer. It was first released in 2004 and is one of the most well-known system cleaners. It was designed originally for Microsoft Windows, but a macOS version was launched in 2012.

how to delete temp files
How to Delete Temporary Files in Windows 11

Follow the step-by-step instructions to delete temp files along with all unwanted files on Windows without having a hassle.

1. Firstly, you need to download the CCleaner from its official website.

2. Install the CCleaner into your computer system and launch it from the desktop icon.

3. Now, Go to the Custom Clean from the left side panel and choose “Temporary Files” given under the System section.

Tip: You can also select other unwanted files such as Clipboard, Memory Dumps, chkdsk file, and windows log files.

4. Hit the “Run Cleaner” button to delete all temporary files.

This is the end of this short guide, hopefully, you find this article helpful.

Related Articles:

How To Change DHCP Lease Time In Windows 10

How To Change DNS Server on Windows 10

How To Password Protect File or Folder in Windows 10

How To Access Steam Screenshot Folder on Windows

Avast Won’t Open – 8 Ways To Fix It on Windows 10

Ultimate Mouse Cursors To Use In Windows 10

Best Android Emulators for Windows and Mac

Best Password Managers For Windows 11

Your Location Is Currently In Use

Windows Stop Code What and How to Fix It

Windows 10 Taskbar Not Working