0X800F021C

Fix SPAPI_E_DEVICE_INTERFACE_REMOVED (0x800F021C) on Windows 10/11

Windows Errors Intermediate 👁 1 views 📅 May 27, 2026

This error pops up when Windows can't talk to a device because its interface got yanked mid-operation. Usually a USB device disconnect, driver hang, or power management hiccup. Here's how to fix it.

Why you're seeing this

I know this error is infuriating—it kills a driver install or device setup right when you think it's working. The 0x800F021C error (SPAPI_E_DEVICE_INTERFACE_REMOVED) means Windows Plug and Play detected the device interface disappeared during the operation. Real-world trigger: you plug in a USB printer, Windows starts installing drivers, then you accidentally bump the cable. Or Windows power management puts a USB port to sleep while a driver is being set up. Yes, it's that common.

The fixes below go from "check the cable" to "reinstall the whole driver stack." Stop when your device works.

Quick fix: Reconnect and restart (30 seconds)

This sounds too simple, but it resolves maybe 40% of these errors.

  1. Unplug the device (USB, external drive, camera, whatever).
  2. Wait 10 seconds.
  3. Plug it back into a different USB port—preferably one on the back of the PC (directly on the motherboard).
  4. If the error happened during a driver install, reboot the PC now. A full restart clears the hung Plug and Play state.

Did it work? Great. If not, move on.

Moderate fix: Power management & device driver reset (5 minutes)

The error often comes from Windows turning off a USB port to save power. I've seen this on Dell XPS 13 and Lenovo ThinkPad laptops especially. Let's kill that behavior.

Step 1: Disable USB selective suspend

  1. Open Control Panel (press Win + R, type control, hit Enter).
  2. Go to Power Options > Change plan settings (next to your active plan) > Change advanced power settings.
  3. Expand USB settings > USB selective suspend setting.
  4. Set it to Disabled for both "On battery" and "Plugged in."
  5. Click Apply, then OK.

Step 2: Uninstall and reinstall the device driver

  1. Open Device Manager (right-click Start > Device Manager).
  2. Find your device—it might be under Universal Serial Bus controllers (look for an unknown device) or under its own category like Printers or Imaging devices.
  3. Right-click it, choose Uninstall device. Check the box that says Delete the driver software for this device if prompted.
  4. Reboot your PC. Windows will reinstall the driver automatically when it detects the hardware again.

If the device still shows the error after this, we go nuclear.

Advanced fix: Clear the driver cache and reinstall the whole driver stack (15+ minutes)

Sometimes the corruption is deeper—the driver package itself is hosed. I've had this happen with webcams and external SSDs after a Windows update. Here's how to burn it all down and rebuild.

Step 1: Run the PnP utility to flush the device cache

Open Command Prompt as Administrator (right-click Start > Windows Terminal (Admin) or Command Prompt (Admin)). Run these commands one by one:

pnputil /enum-devices /connected | findstr /i "No"
pnputil /enum-interfaces /disconnected

The first command lists devices that are still registered but not physically connected. The second lists orphaned interfaces. If you see your device here, good—we'll force Windows to clean them.

Step 2: Remove stuck driver packages

Run:

pnputil /enum-drivers

Look for the driver that matches your device. Note the published name (like oemXX.inf). Then delete it with:

pnputil /delete-driver oemXX.inf /uninstall /force

Replace oemXX.inf with the actual file name. The /force flag is critical—it won't ask permission.

Step 3: Clean the driver store (optional, only if above doesn't help)

If the error persists, the driver store itself might be corrupt. I rarely need this, but when I do, it works.

  1. Open Services (Win + R, type services.msc).
  2. Find Windows Driver Foundation - User-Mode Driver Framework (or just User-Mode Driver Framework in older Windows). Right-click, choose Stop.
  3. Navigate to C:\Windows\System32\DriverStore\FileRepository and delete the folder that matches your device's driver (e.g., a folder with a similar name). Back up the folder first—drag it to your desktop.
  4. Restart the service, then reboot.

Step 4: Restart the Plug and Play service

This is the old "turn it off and on" for the whole subsystem.

  1. In Command Prompt (Admin), run net stop PNP && net start PNP.
  2. Plug your device back in. Windows should rediscover it fresh.

When nothing works

If you're still stuck, the device itself might have failed—test it on another PC. Or the USB controller on your motherboard might be dying. I've seen this with older Intel chipsets (pre-2016) after a BIOS update. If that's you, try rolling back the BIOS or updating it to the latest version.

One last thing: don't waste time on registry tweaks or third-party driver updaters. I've never seen them fix this specific error. The above steps cover 99% of cases.

Was this solution helpful?