Disk Cleanup Not Deleting Files (Temp/Windows Update Files?)

Summary

What can we do when Disk Cleanup not deleting files, such as the temporary files, the Windows update files, etc. Here are several ways to run Disk Cleanup or remove files with free tools.

Andrew Wright

Updated on March 5, 2023

by Andrew Wright

Follow @IM-Magic

How to delete temp/log/trash files when Disk Cleanup failed?

Disk cleanup is a built-in Windows utility that helps users remove unnecessary files and free up space on their hard drives. However, some users have reported that they are unable to delete files using Disk Cleanup, even though they have followed all the steps correctly. In this article, we will explore some potential solutions to this problem.

Before we begin, it is important to note that Disk Cleanup is designed to remove temporary files, old logs, and other items that are no longer needed by the system. It is not intended to delete personal files, such as documents, music, or videos. If you are trying to delete personal files, you should do so using File Explorer or another file management tool.

With that said, here are some potential solutions to the problem of Disk Cleanup not deleting files:

Video - 2 ways to delete files when Disk Cleanup not working

This following video includes 2 ways to efficiently removing files that can save disk space when Disk Cleanup is not working.

#1 Run Disk Cleanup as an Administrator

One reason why Disk Cleanup may not be able to delete certain files is that it does not have the necessary permissions to do so. To overcome this, you can try running Disk Cleanup as an administrator. Here's how:

  • Right-click on the Disk Cleanup icon in the Start menu or on the desktop and select "Run as administrator".
  • When prompted, click "Yes" to allow the program to make changes to your computer.
  • Follow the prompts to select the drive you want to clean up and the types of files you want to delete.
  • Check the boxes next to the items you want to delete and click "OK".
  • Wait for Disk Cleanup to complete the cleanup process.

By running Disk Cleanup as an administrator, you give it the necessary permissions to delete files by using the following command lines in the cmd window. (You may copy and paste the following cmd in the cmd window)

This following cmd may save hundreds of MB space depending on how many temporary files the os holds.

%SystemRoot%\System32\Cmd.exe /c Cleanmgr /sageset:65535 & Cleanmgr /sagerun:65535

cmd to run disk cleanup when its not deleting files

 

#2 Configure storage sense and delete previous versions of Windows (system restore points)

It may save up to dozens of GB free disk space by deleting some previous Windows restore points.

To delete previous versions of Windows, open Disk Cleanup, select the drive you want to clean up, click "Clean up system files," check the box next to "Previous Windows installations," and click OK. Finally, confirm the deletion by clicking "Delete Files."

Delete previous version of Windows under Storage Sense

If it's not working, not deleting the previous Windows installation files, you may try it under Storage sense.

To delete previous versions of Windows in Configure Storage Sense, go to Settings > System > Storage > Configure Storage Sense. Turn on the toggle switch for Storage Sense and select "Clean Now" under "Free up space now." Check the box next to "Previous Windows installation(s)" and click "Remove files."

delete previous versions of windows

Windows Previous Versions is a feature that allows users to restore previous versions of files or folders that were accidentally deleted or modified. These previous versions can take up significant amounts of storage space on your computer's hard drive. If you need to free up space, you can delete Windows Previous Versions by following these steps:

  1. Open the Start menu and type "Disk Cleanup" in the search bar.
  2. Select the Disk Cleanup app from the search results.
  3. Choose the drive that you want to clean up and click OK.
  4. Click the "Clean up system files" button.
  5. Check the box next to "Previous Windows installations" and any other items you want to delete.
  6. Click OK and then click Delete Files to confirm.

This process will delete all previous versions of Windows and free up space on your computer's hard drive.

Delete System restore points in Disk Cleanup window

Another Way to Delete Windows System Restore Points (How to delete all restore points except the most recent one?)

Disk Cleanup window offers MORE OPTIONS that you may delete old system restore points to release free space.

delete restore points

Note: If right click C drive property does not show More options to delete restore points, you may open it by the following way:

Search column, type 'Disk Cleanup' -> Select c drive and run -> Click clean system files -> Choose c drive again -> Wait for the c drive cleaning up to be finshed, and then the window that has More options would show up.

#3 Disable User Account Control (UAC)

User Account Control is a security feature in Windows that prevents unauthorized changes to the system by requiring users to confirm any actions that require elevated privileges. However, this feature can sometimes interfere with Disk Cleanup's ability to delete files. To see if this is the case, you can try disabling UAC temporarily and running Disk Cleanup again. Here's how:

  • Click the Start menu and type "UAC" in the search box.
  • Click on "Change User Account Control settings" in the search results.
  • Move the slider to the bottom to turn off UAC and click "OK".
  • Restart your computer.
  • Run Disk Cleanup again and see if it is able to delete the files.

If this solution works, you may want to consider turning UAC back on after you have finished cleaning up your disk.

#4 Use a Disk Cleanup alternative

If Disk Cleanup still isn't able to delete the files you want to get rid of, you can try using a third-party disk cleanup tool. There are many such tools available online, and they can often be more effective than Disk Cleanup at removing files that are no longer needed. Some popular options include CCleaner, Glary Utilities, and Wise Disk Cleaner.

When using a third-party disk cleanup tool, be sure to choose one from a reputable source and read reviews from other users to ensure that it is safe and effective.

#5 Check file permissions

If Disk Cleanup is unable to delete a specific file, it may be because the file has restrictive permissions that prevent it from being modified or deleted. To check the file permissions, you can do the following:

  • Navigate to the location of the file in File Explorer.
  • Right-click on the file and select "Properties".
  • Click on the "Security" tab.
  • Check to see if your user account has permission to modify or delete the file. If not, click "Edit" and grant yourself the necessary permissions.
  • Try running Disk Cleanup again and see if it is able to delete the file.

#6 Check for file corruption

Sometimes files can become corrupted, which can prevent them from being deleted by Disk Cleanup or other tools.

Solution: Find these corrupted files and delete them manually.

How to delete Windows system update files when Disk Cleanup failed?

Here is the place where the system update folder is placed and you may manually delete all of them when Disk cleanup or other third party clean software failed.

file:///C:/Windows/SoftwareDistribution/Download/

You may copy and paste the above address in your browser or file explorer to reach the update folders and get them deleted.

How To Clear Windows Update Cache and Fix Windows Updates

Add 100+GB space to C drive with free tool

When disk cleanup did not clean as much free space as you expected, you may redistribute disk spaces from one to another using free tool Partition Resizer without losing data.

The data and OS are totally protected during the resizing. Watch the following video to know how to shrink a volume and add space to another.

Video: how to shrink a volume and expand another one without losing data

download free windows 10 partition software

Related Product