How to Delete Undeletable Files in Windows?

It?s important to keep your system clean from junk or irrelevant files occupying unnecessary space on the drive. Despite having admin privileges in Windows, users sometimes face this issue where they are not able to delete some files or folders.

This can be caused by a virus, malware, spyware, adware, Trojan horse, or corrupt/damaged system files and permissions that locks the files, thereby making them undeletable.

In few cases, the file can?t be removed or deleted as it is being used by another application or essential program. Some frequent errors that appear in Windows when trying to delete undeletable or locked files are:

  1. The file is in use by another program
  2. There has been sharing violation
  3. Cannot delete file: Access is denied
  4. The source or file destination is in use
  5. The file or directory is corrupted or unreadable.

This could be frustrating when you are struggling to free up some space and a few troublesome files stop you from proceeding. These files can vary from a few bytes to sometimes gigabytes.

How to Delete Undeletable Files

If you have also come across a similar situation, you can forcibly delete and get rid of these undeletable files and folders either manually or by using a software.

  1. Reboot the System

First, try a reboot. It?s possible that the file or folder location might be in use by a software or essential Windows programs in the background. When you shut down the system, these processes stop. After reboot, open File Explorer and browse the file or folder location. Try deleting it. If this doesn?t work, boot into ?Safe Mode? in Windows by following these steps:

In Windows XP & 7

In Windows 10, 8.1, and 8

When you have successfully booted in Safe Mode, open the File Explorer and try deleting the files or folders or proceed to the next solution if this doesn?t work.

  1. Using Command Prompt

Command Prompt or cmd can help you get rid of most troublesome files and folders from your Windows PC. Follow these instructions to permanently delete undeletable files and folders.

WARNING: Be very careful with these commands. Confirm the location of the file or folder at least two to three times before executing these commands. You may accidentally delete some important files.

/F Force deleting of read-only files.
/S Delete specified files from all subdirectories.
/Q Quiet mode, do not ask if ok to delete on global wildcard
/A Selects files to delete based on attributes

Followed by the location of file or folder

  1. Using a Software

If command prompt fails to delete undeletable files and folders, you can use a reliable tool like Stellar File Eraser that can delete undeletable and locked (or infected) files and folders from your PC and helps you free up unnecessarily used space on your system. Follow these steps:

The selected undeletable files and folders are permanently removed from the system after reboot.

Moreover, this tool can also help you to clean up your internet activities, system traces, application traces, and other files and folders permanently beyond the scope of recovery and helps safeguard your privacy.

It erases data securely using 17 International erasure standards like NATO, U.S. Department of Defense (DOD Standard 5220.22-M) 3 Pass/7 Pass, etc.

Conclusion:

Remove or delete your files cautiously and securely or else you may regret deleting some important files or folders accidentally. Use a reliable and trusted antivirus and anti-malware program to protect your system and files from infection.

It will also help you avoid data loss situations due to virus or malware attacks like Ransomware. Also, run schedule cleanup tasks to remove unnecessary files and folders from your system.

You can use Stellar File Eraser to delete undeletable files and folder and to schedule or automate erasure process (once, daily, weekly, monthly, on first boot, or on every boot).

Related Post