How to remove locked files & folders on Windows 10 PC

Madalina Dinita
by Madalina Dinita
Managing Editor
Loading Comments
Download PDF
Affiliate Disclosure

  • Dealing with stubborn files and folders can be a nuisance.
  • But we have just the right fixes to help you remove those locked files in no time.
  • Perhaps the File is open in another program error is ruining your plans? Check out this quick Repair Guide.
  • Don't be shy to explore our File Removal Hub as well.
stop delete browser history

For a Windows user, it’s possible that at one time or the other, there might be a situation in which the computer’s disk space gets crowded.  There might be attempts by the user to get rid of unneeded files without success.

When trying to delete unneeded item, an annoying dialog box pops up, indicating that the action is not permitted as a result of a locked file.

 

The inability to delete a file or folder may either be because it’s locked (encrypted with a security code or password) or because the file is open in a program.

Sometimes no file has been accessed in any particular application, it may be a background program that is preventing the file from being deleted.

To completely get rid of the files/folders, follow the procedures listed below.

How can I remove locked files/ folders?

1. Delete the file from Command Prompt

A  locked file can be deleted from the Windows Command Prompt. All that is needed is to launch the Command Prompt by typing cmd into the Windows search bar from the Start menu.

  1. Start the Command Prompt as an Administrator to activate user privileges.
  2. Type CD to open the root folder
  3. Then type DEL filename (with extension) /F /Q where filename represents the name of the locked file to be deleted.
  4. Press Enter and the file will be gone.

Some locked files may not be this easy to remove. This might prompt going the extra mile by trying out the Windows Recovery method described below. Alternatively, you can download software to fix this.


Unable to run the Prompt as admin? Get that obstacle out of your way with this easy guide.


2. Install BitRaser

If you’re unable to delete user folders in Windows 10 using conventional methods, you might want to try a different, more professional approach.

Using dedicated file erasure software such as BitRaser comes with many advantages one of which is permanently erasing files that are beyond the scope of data recovery.

By securely erasing confidential data from all devices (running on Windows and Mac as well), servers, and partitions, this privacy safeguarding software meets all your media sanitization requirements.

Using it is as simple as a breeze too: all you need to do is download the .EXE file, install the tool, select the items you want to erase and Delete.

Let’s quickly look at its key features:

  • Permanent and secure erasure of single or multiple files, folders, partitions, app traces, sys files, and browsing history
  • Clear unused space and data from mapped drives
  • Schedule erasure tasks at regular intervals
  • Wipe data files with a single right-click
  • Password protection to prevent unauthorized erasure
  • Compliance with PCI DSS file-level data requirements
  • Obtain digitally-signed certificates with proof of erasure for audit purposes
  • Generate comprehensive reports with erasure process and results
BitRaser

BitRaser

Erase locked files and folders permanently with this excellent privacy safeguarding software!

3. Use Windows Recovery

Windows Recovery is another method by which locked files can easily be deleted.

  1. Switch the computer off and insert the windows re-installation disc into the disc drive.
  2. Turn the PC on, and let it boot (not from the hard disk this time but from the disc).
  3. Put the computer into the recovery console mode by pressing the key R on the keyboard: this mode is a troubleshooting option built into windows.
  4. In the recovery mode, go to the location of the locked file using the Command Prompt. For example, a command like cd C: Documents \Settings \My Documents \filename, the pattern given in this example should be followed using the directory of the locked file to be deleted.
  5. After locating the file, it can be removed by typing in del and to leave the recovery mode. Type the command exit and restart the computer.

4. Use dedicated software uninstallers

There are a number of software that can be downloaded and used to delete locked files from the PC. Here are a few options.

Process Explorer

A renowned software called the Process Explorer comes in a similar format to the Windows Task Manager.

It’s easy to use and doesn’t require installation, all that is needed is to run it and allow administrator permission, then follow these steps.

    1. Go the File menu on the menu tab and choose show details for all processes.
    2.  While still on the menu tab, select the Find option, and click on Find Handle or DLL.
    3. Enter the name of the locked folder in the search field of the process explorer task manager.
    4. Choose the locked file and check out the handle in the details section below the window.
    5. In the same manner that the process can be ended on the regular windows task manager: right-click on the filehandle and click on close handle.
    6. You would have effectively stopped it from running in the background and stop it from getting deleted. You can now go back to the file location and delete the file.

Check out these top file recovery software for Windows PCs and protect your assets from data loss.


ThisIsMyFile

This is a free software that perfectly helps to get rid of unwanted files and folders that are locked.

Apart from just removing the file, ThisIsMyFile also serves as a diagnostic tool that can help the user in figuring out exactly why the file or folder is not accessible.

Also, it doesn’t require any installation and quickly removes locked files without any hassles.

However, for difficult files, the PC  has to be rebooted after deleting the file.

Download ThisIsMyFile for free here

IOBit Unlocker

IObit Unlocker

This is a handy software that can unlock and manage the files and folders to keep them safe and available. What’s more, it’s incredibly easy to use.

Just drag and drop the locked file or folder into the software’s interface and choose the delete option (or unlock, rename, move, copy and so on, according to your specific needs).

It also provides details about the location of the file and directory alongside the details of the process.

Download IOBit Unlocker for free here

LockHunter

This comes in as a very helpful software. LockHunter also helps in identifying the particular program that is keeping the file locked.

Going forward, the processes can be stopped in an expedited manner before the file gets deleted.

Lockhunter doesn’t permanently remove the file. However, it sends the file to the recycle bin allowing the user the chance of restoring the file if need be.

Download LockHunter for free here

FileASSASSIN

This is an easy to use software, and its line of action is similar to 10bitunlocker. It is useful in deleting locked files especially those that are inaccessible due to a virus or other malware.

      1. Download FileASSASSIN and access it on the computer.
      2. Drag the locked file or folder into the FileASSASSIN text area.
      3. Select how exactly how the file or folder should be deleted from the various menu options and click on execute to get the file deleted.
      4. Access to the files will be possible using the FileASSASSIN thereafter.

Download FileASSASSIN for free here

TizerUnlocker

Tizer Unlocker can unlock files and folders that are in use as well as the process that is running them.

This software is easy to use, and it has a simple interface that requires a simple installation process. After installation, the file name has to be typed in and deleted.

Upon browsing for the desired file or folder, the tool also retrieves useful details such as the name, handle ID, process ID and location of the file/folder.

Download TizerUnlocker for free here


Depending on which of these options are a point of interest, deleting a locked file should not pose a problem anymore.

What software are you using to deal with locked folders in Windows 10? Share your experience with us via the comments section below.

Editor’s Note: This post was originally published in October 2017 and has been since revamped and updated in July 2020 for freshness, accuracy, and comprehensiveness.

Was this page helpful?
Thanks for letting us know! You can also help us by leaving a review on MyWOT or Trustpillot.
Get the most from your tech with our daily tips
Tell us why!