If you already run PowerToys and only need to see which process holds a file now and then, File Locksmith is free and does that job, and its command-line tool is great for build scripts. LockGhost is the better fit if file locks are a weekly problem and you want a standalone app that names the locker in plain language, color-codes how risky it is to end, blocks you from ending critical system roles, and keeps a local history of past locks. Both run from the File Explorer right-click menu.
This comparison sticks to what each tool’s own documentation says.
See which app is holding your file, by name, with guardrails before you end anything.
Get it from Microsoft
What is PowerToys File Locksmith?
Microsoft describes File Locksmith as “a PowerToys utility that helps you identify which processes are using specific files or directories in Windows.” It is part of PowerToys, the free Microsoft utility suite.
How it works, per the documentation:
- Turn on Enable File Locksmith in PowerToys.
- Select files or folders in File Explorer. Selecting a folder scans “all of its files and subdirectories” too.
- Right-click, choose Show more options, then Unlock with File Locksmith.
- Review the list of processes and choose End task, or expand an entry for details.
Two details matter. First, “processes that are being run by a different user cannot be accessed and may be missing from the list,” so you need Restart as administrator to scan everything. Second, the entry sits in the classic menu behind Show more options on Windows 11.
File Locksmith also has a CLI, FileLocksmithCLI.exe, with --kill, --json, and --wait options. The --wait flag “blocks execution and waits until the specified files are released,” which Microsoft notes is “useful in build scripts.”
What is LockGhost?
LockGhost is a standalone Windows utility from Automata Labs that answers one question: what is holding this path? From the LockGhost product page:
- Built on the Windows Restart Manager API.
- Paste, drag, or right-click a path from File Explorer.
- Shows “every process holding the path, by friendly name, with color-coded severity instead of cryptic PIDs.”
- Guarded End Process that “confirms before you end a process and hard-blocks critical system roles.”
- Local lock history in an on-disk database, with no telemetry and no network calls.
- Tray icon, a custom global hotkey, and settings in eleven languages.
- One-time purchase on the Microsoft Store.
How do they compare side by side?
| PowerToys File Locksmith | LockGhost | |
|---|---|---|
| Price | Free, part of PowerToys | One-time purchase |
| Install | Part of the PowerToys suite | Standalone app |
| Explorer right-click | Yes, under Show more options | Yes |
| Folder scan | Yes, including subfolders | Paste, drag, or right-click a path |
| Process names | Process list with expandable details | Friendly names |
| Risk guidance | Not listed in the docs | Color-coded severity |
| Ending a process | End task | Confirmation, and critical system roles blocked |
| Lock history | Not listed in the docs | Yes, stored locally |
| Command line | Yes, with JSON, kill, and wait | Not listed |
| Global hotkey and tray | Not listed in the docs | Yes |
| Offline | Yes | Yes, no network calls |
“Not listed” means the feature is not in that tool’s documentation, not that it is impossible.
When is File Locksmith the right choice?
- You already use PowerToys. It costs nothing to switch it on.
- You need automation.
--jsonoutput and--waitare designed for scripts and CI. LockGhost is built around a GUI. - You lock files rarely. If this happens once a month, free and good enough wins.
Fair is fair: for a build script that must wait until an output file is free, File Locksmith’s CLI is the right tool.
When is LockGhost the right choice?
- You do not want the whole PowerToys suite. Some managed PCs restrict PowerToys, and some people simply want one small tool.
- You are not sure what is safe to end. Severity colors and the hard block on critical system roles reduce the chance of ending something that crashes Explorer or the session.
- Locks keep coming back. Lock history lets you see which app keeps grabbing a folder, so you can fix the cause, such as a sync client or indexer setting.
- You want it one keystroke away. A global hotkey and tray icon bring it up without digging through menus.
A standalone file unlocker with severity colors and lock history, fully offline.
Get it from Microsoft
What do both tools have in common?
Neither tool can stop the cause. They both show you a locker and let you end it. If OneDrive, Windows Search, or antivirus holds the file, the better fix is often to pause sync or wait for the scan rather than end the process.
Both are limited by permissions too. File Locksmith says so directly, and any tool needs administrator rights to inspect processes owned by other users or services.
Microsoft’s Restart Manager documentation explains the API LockGhost uses. Installers call it so that “all but the critical applications and services” can be shut down and restarted, which “frees the files that are in use.” The same documentation notes that “shutdown across sessions is not supported,” which is one more reason to close a locking app yourself when you can. Our guide to using Restart Manager to find a file lock goes deeper.
How do I unlock a file with either tool?
With File Locksmith:
- Install PowerToys and enable File Locksmith.
- Right-click the file, choose Show more options, then Unlock with File Locksmith.
- If the list looks incomplete, choose Restart as administrator.
- End the task you recognize, then retry your delete or save.
With LockGhost:
- Install LockGhost from the Microsoft Store.
- Right-click the file or folder, or paste the path into LockGhost.
- Read the friendly name and severity color.
- End the process with the guarded button, or close the app yourself, then retry.
Which one should I pick for my situation?
| Your situation | Better pick |
|---|---|
| Build script must wait for a file to be released | File Locksmith CLI with --wait |
| You need JSON output for automation | File Locksmith CLI with --json |
| You already run PowerToys every day | File Locksmith |
| PowerToys is not allowed on your work PC | LockGhost |
| You are not sure which process is safe to end | LockGhost |
| The same folder gets locked again and again | LockGhost, for its lock history |
| You want a hotkey to open the unlocker | LockGhost |
Common mistakes with file unlockers
- Ending Explorer or a system process. You will lose open windows or more. Prefer closing the app normally.
- Killing a sync client mid-upload. Pause sync instead.
- Not running as administrator. Service-owned locks may not show.
- Fixing the symptom every day. If the same app keeps locking a folder, change its settings or exclude the folder.
Frequently asked questions
Is File Locksmith safe?
It is a Microsoft PowerToys utility. The risk is in what you choose to end, not the tool.
Does LockGhost need PowerToys?
No. It is a standalone app.
Can I use both?
Yes. Many people use the File Locksmith CLI in scripts and LockGhost for day-to-day lock problems.
Why does Windows not tell me which app has the file open?
The standard “file in use” message often does not name the process. See cannot delete a file in use on Windows for the full set of causes, and our LockHunter alternative guide for other tools.
Try LockGhost
Get LockGhost from the Microsoft Store or read the LockGhost overview.
Find the locker, end it safely, and finish the delete you started.
Get it from Microsoft
Microsoft, Windows, PowerToys, and OneDrive are trademarks of the Microsoft group of companies. Other product names are trademarks of their owners. LockGhost is not affiliated with or endorsed by any of them.
Last updated 17 October 2026. Published by Automata Labs, a software company in Canada.