How to Delete a File in Use in Windows [2024] (2024)

Amy Dennis

Jul 17, 2024 • Filed to: Recover Files • Proven solutions

When working on Microsoft Windows, how many times have you seen a message telling that the particular file you are attempting to delete is already in use and that the program using the file must be stopped before Windows allows you to remove the file from the PC?

Annoying!! Isn’t it?

Well, not anymore.

Here are the three genius ways that you can use to force delete a file that is in use and Windows doesn’t allow you to remove it normally.

  • Force Deleting a File in Use in Windows
  • Delete a File From Command Prompt
  • Using a Third-Party Tool – Unlocker
  • Restore a File If It Has Been Deleted Accidentally

Solution 1. Force Deleting a File in Use in Windows

This method works most of the time. All you need to do is to force terminate the program that is using the file. Assuming that you already know which program is using the file that you want to remove, this is how you delete the file:

Note:Windows 7 is used here as a reference PC.

Force terminating a process shuts down the entire program and you may lose any unsaved data that any other file that relies on the program may have. It is advisable to save all your work progress before proceeding.

1. On your desktop screen, right-click the taskbar.

2. From the context menu that appears, clickStart Task Manager.

How to Delete a File in Use in Windows [2024] (2)

3. In the Task Manager box, if not already there, go to theProcessestab.

4. From the displayed list of running processes, right-click the one that you know is using the file that you want to delete.

5. From the context menu, clickEnd ProcessorEnd Process Tree. (End process treeis clicked here.)

How to Delete a File in Use in Windows [2024] (3)

6. On the confirmation box that pops up, click theEnd process treebutton from the bottom.

How to Delete a File in Use in Windows [2024] (4)

7. Once the process has been forcefully terminated, you can easily remove the file as it is no longer used until the process starts running again.

Note:In some cases, you need to be quick in deleting the file after force terminating the process. This is because some processes are stubborn and even if you terminate them forcefully, they restart automatically after a few seconds.

More Related Articles:

  • How to Use Powershell to Force Delete File and Folder
  • How to Delete Undeletable Files
  • How to Delete Search History in Windows 10

Solution 2. Delete Files in Use From Command Prompt

This method requires you to open Command Prompt on your Windows PC. For the files used by some local processes (the processes that can be started and closed by a standard – non-administrator user account), opening Command Prompt on a standard user account would suffice. However, if the file is used by any system process, the elevated Command Prompt must be initialized. An elevated Command Prompt is the command window that has all the administrator rights and all the administrative tasks can be performed via commands in its interface.

This is what you need to do:

Note:A Windows 7 PC is used in this example.

1. On your Windows PC, locate the folder that contains the file in use that you want to delete. (Do not enter into the folder.)

2.Shift + right-clickthe folder.

3. From the advanced context menu that appears, clickthe Open command window hereor press theWkey on the keyboard.

How to Delete a File in Use in Windows [2024] (5)

Note:This method does not allow you to open an elevated command window.

Note:To start elevated Command Prompt, click the Start button, typeCMDin the search box at the bottom of the Start menu, right-clickCMDfrom the suggested programs’ list, clickRunas administrator from the context menu, and on theUser Account Controlconfirmation box, type the password for the admin account (or clickYesif Windows doesn’t ask you for the password) to provide your consent to continue. After the elevated command window opens up, you must use the DOS commands likeCDandDIRto locate the directory where the file you want to delete is placed and to check the presence of the file respectively.

4. In the command window, type theDEL /F file namecommand and pressEnterto force delete the file that is in use.

Note:In the above command,the file namemust be replaced by the name of the file along with its extension that you want to delete. For exampledel /f TestFile.txt.

WARNING!!– A file deleted using theDELcommand does not move it to the Recycle Bin but deletes it permanently. Use theDELcommand with caution.

How to Delete a File in Use in Windows [2024] (6)

5. Once the file is deleted, you can close Command Prompt by clicking theClosebutton from the top-right corner of the window or by typingEXITin the command window and pressingEnter.

Solution 3. Delete Files in Use with a Third-Party Tool – Unlocker

Even though you can use any of the two methods described above to remove a file that is in use, a third-party tool such as Unlocker makes your task extremely simple. The best part is that Unlocker is a freeware and is free to download and use. This is how Unlocker works:

Note:A Windows 7 computer is used for reference.

1. Log on to your Windows PC.

2. Ensure that it is connected to the Internet.

3. Open any web browser of your choice and open your preferred search engine. (Google, Yahoo!, Bing, etc.)

4. Using the search engine, search for Unlocker.

5. Once found, download Unlocker’s installable file and install the program using the normal installation method, or get its portable version.

Note:Unlocker is installed on this referencePC.

6. After this, locate the file that you want to delete but is in use.

7. Right-click the file.

8. From the context menu that is displayed, clickUnlocker.

How to Delete a File in Use in Windows [2024] (7)

9. On theUser Account Controlconfirmation box, clickYesto provide your consent to continue launching the program.

10. On the displayed interface, from the available list of files in use, click to select the one that you want to unlock.

11. From the bottom of the interface, clickUnlockto unlock the file while leaving the corresponding application open. Alternatively, you can also click theKill Processbutton to force terminate the running process that is responsible for engaging the file.

How to Delete a File in Use in Windows [2024] (8)

12. Once the file is unlocked, you can right-click the file and clickDeletefrom the context menu.

13. ClickYeson theDelete Fileconfirmation box when/if displayed.

How to Restore a File If It Has Been Deleted Accidentally

Even if the file has been forcefully unlocked using any of the methods, it is moved to the Recycle Bin when deleted (except for when deleted using the command line). That being said, restoring the file from the Recycle Bin is simple. This is what you need to do.

1. On your Windows desktop screen, double-click the Recycle Bin’s icon.

2. Once inside theRecycle Bin, right-click the file that you want to restore.

3. From the context menu, clickRestore.

How to Delete a File in Use in Windows [2024] (9)

Note:If a file has been deleted permanently (e.g. when removed with the DEL command), you need an efficient file recovery software such as RecoveritData Recoveryto recover the file back.

How to Delete a File in Use in Windows [2024] (10)

  • Recover lost or deleted files, photos, audio, music, emails from any storage device effectively, safely and completely.
  • Supports data recovery from recycle bin, hard drive, memory card, flash drive, digital camera, and camcorders.
  • Supports to recover data for sudden deletion, formatting, hard drive corruption, virus attack, system crash under different situations.

Free Download | Win Free Download | Mac

Although the above-mentioned tricks work almost every time, you must take the utmost care while deleting any file that is in use. Deleting a wrong file may cause consequences like permanent or temporary system failure or data loss. To avoid this, before force deleting your files, make sure you have thoroughly verified the following:

  1. The file in use does not contain any important data.
  2. Force terminating the process to unlock the file doesn’t cause any permanent damage to its corresponding program.
  3. You have backed up the file before deleting it.
  4. You have tried (and failed) other ways to do what you want to do, and that force deleting the file is the only option left.

Video Tutorial on How to Recover Deleted Files on Windows 10/8/7 Easily?

How to Delete a File in Use in Windows [2024] (11)

Recent Videos from Recoverit

View More >

Free Download | Win Free Download | Mac

Rescue & Fix Files

Recover Document Files
  • Unsaved Word Document
  • Damaged Word Files
  • PDF File Recovery
Repair Document Files
  • Repair Excel Error
  • Get Free Word Repair Tool
  • Word Not Found?
  • Corrupt Word File Is Fixed
Recover & Repair More
  • Permanently Deleted Files
  • Delete Files Command
  • Restore Sticky Notes
  • Undo Deleted Files
  • Get Back Laptop Files
  • Undelete User Profile
Clear & Delete File
  • Clear Skype Chat History
How to Delete a File in Use in Windows [2024] (2024)
Top Articles
QQQ – Performance – Invesco QQQ Trust
When to give money to your parents (and when not to)
Evil Dead Movies In Order & Timeline
Gamevault Agent
South Park Season 26 Kisscartoon
Us 25 Yard Sale Map
Pitt Authorized User
Dr Klabzuba Okc
The Best English Movie Theaters In Germany [Ultimate Guide]
Self-guided tour (for students) – Teaching & Learning Support
Costco in Hawthorne (14501 Hindry Ave)
Canelo Vs Ryder Directv
Magic Mike's Last Dance Showtimes Near Marcus Cedar Creek Cinema
Premier Boating Center Conroe
The Rise of Breckie Hill: How She Became a Social Media Star | Entertainment
Cool Math Games Bucketball
Mlb Ballpark Pal
Identogo Brunswick Ga
Dallas’ 10 Best Dressed Women Turn Out for Crystal Charity Ball Event at Neiman Marcus
Ts Lillydoll
How do I get into solitude sewers Restoring Order? - Gamers Wiki
Army Oubs
623-250-6295
Jbf Wichita Falls
Publix Super Market At Rainbow Square Shopping Center Dunnellon Photos
Indiana Wesleyan Transcripts
Kashchey Vodka
Dcf Training Number
What Is The Lineup For Nascar Race Today
Horn Rank
Strange World Showtimes Near Savoy 16
Harrison 911 Cad Log
Maisons près d'une ville - Štanga - Location de vacances à proximité d'une ville - Štanga | Résultats 201
Tamil Movies - Ogomovies
Ts Modesto
897 W Valley Blvd
Plato's Closet Mansfield Ohio
Watchdocumentaries Gun Mayhem 2
The Best Carry-On Suitcases 2024, Tested and Reviewed by Travel Editors | SmarterTravel
Indiana Wesleyan Transcripts
Police Academy Butler Tech
Quake Awakening Fragments
Greater Keene Men's Softball
Puffco Peak 3 Red Flashes
What Does Code 898 Mean On Irs Transcript
Cl Bellingham
Academic Notice and Subject to Dismissal
Syrie Funeral Home Obituary
tampa bay farm & garden - by owner "horses" - craigslist
1Tamilmv.kids
What Are Routing Numbers And How Do You Find Them? | MoneyTransfers.com
Latest Posts
Article information

Author: Madonna Wisozk

Last Updated:

Views: 5623

Rating: 4.8 / 5 (68 voted)

Reviews: 91% of readers found this page helpful

Author information

Name: Madonna Wisozk

Birthday: 2001-02-23

Address: 656 Gerhold Summit, Sidneyberg, FL 78179-2512

Phone: +6742282696652

Job: Customer Banking Liaison

Hobby: Flower arranging, Yo-yoing, Tai chi, Rowing, Macrame, Urban exploration, Knife making

Introduction: My name is Madonna Wisozk, I am a attractive, healthy, thoughtful, faithful, open, vivacious, zany person who loves writing and wants to share my knowledge and understanding with you.