Skip to content
PCFixWorkbench

USB · Storage

Fix a PC that cannot eject a USB drive because it is always 'in use'

Written December 3, 2026

Windows refuses to eject a USB drive while any program, window, or background service is touching a file on it — and something almost always is, from a forgotten Explorer window to the search indexer. Close the real holder, and if the message outlives everything you can see, sign out or restart rather than pulling the drive and risking the file that was open.

What you need

Read the problem before you touch it

  1. Understand what 'in use' protects. Ejecting tells Windows to finish every write and close every open file on the drive before you remove it, as Microsoft sets out in Safely remove hardware in Windows. The refusal means at least one handle is still open. Pulling the drive anyway can corrupt the file that was open — the warning is doing its job, so the fix is finding the holder, not bypassing the check.
  2. Check the obvious holders first. Look for a File Explorer window showing the drive, a document or photo open from it, a media player pointed at it, or a backup or sync program mid-job. Explorer windows count even minimized and forgotten — and Microsoft's File Explorer in Windows is where to look for them, including the preview pane, which holds a file open just by showing it.

The simple fixes, in order

  1. Wait a minute, close the drive's windows, and try again. Close every File Explorer window showing the drive or any folder on it, click on the desktop so Explorer's focus moves elsewhere, wait a full minute for writes to finish, then eject from the system tray again. This clears the majority of cases.
  2. Close the program that used the file. If you opened anything from the drive — a document, a video, an installer — close that program completely, not just the file. Many programs keep the folder or file locked until the program itself exits.
  3. Sign out and back in if nothing visible is holding it. Signing out closes every program and handle in your session at once. Sign back in and eject the drive before opening anything. If it ejects now, a background process in your session was the holder — annoying, but the drive and PC are both healthy.

The advanced route

  1. Restart if signing out does not release it. A service or a crashed program can hold a handle outside your session. A restart clears every handle on the PC. Eject the drive early after the restart, before launching the apps that usually touch it. If one app reliably re-locks the drive, you have found your culprit by timing — Microsoft's guidance on the drive side is in Disk Management in Windows, where the drive's state can also be checked.
  2. Stop the indexer and antivirus from scanning it, if it happens every time. If this drive is refused on every eject, Windows Search indexing or an antivirus scan is the likely permanent holder. In Indexing Options, exclude the drive's letter, and let any antivirus scan of the drive finish before ejecting. The pattern to recognize is timing: a drive that ejects fine after ten idle minutes was being scanned, not broken.
  3. Check the drive's health if files on it also misbehave. A drive that will not eject and also throws errors opening files may be failing. Copy everything you need off it first — before any repair attempt — and only then consider checking it. Data first, diagnosis second, on any drive that holds the only copy of anything.

End state

When it goes wrong

Related fixes

Sources