Fix SPAPI_E_INVALID_REG_PROPERTY (0X800F0209) in 2 Steps
Corrupted device registry keys cause this error. We're deleting them. Takes 5 minutes.
Your device driver install just hit this error and you're stuck.
I've seen SPAPI_E_INVALID_REG_PROPERTY (0x800F0209) a hundred times. It's not a driver problem — it's a registry corruption problem. The culprit is almost always a leftover or malformed registry property under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum. Here's the fix.
Step 1: Find the offending device
Open Device Manager. Look for the device with a yellow bang. Usually it's a USB device, a Bluetooth adapter, or a phantom device that doesn't show up in normal view. Right-click it, choose Properties, go to the Details tab, and select Device instance path from the dropdown. Copy that string — it looks like USB\VID_XXXX&PID_XXXX\SOMESERIAL.
If you don't see a yellow bang, open a Command Prompt as admin and run:
devcon find *Devcon is part of the Windows Driver Kit. If you don't have it, grab it from Microsoft's site. Search for devices with a status that says CM_PROB_FAILED_INSTALL or CM_PROB_INVALID_DATA.
Step 2: Delete the corrupted registry key
Open Regedit as admin. Navigate to:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\Under this, you'll see the device path you copied earlier. For example, if your instance path is USB\VID_1234&PID_5678\ABC123, you'll find:
HKLM\SYSTEM\CurrentControlSet\Enum\USB\VID_1234&PID_5678\ABC123Delete the entire key for that device — the one that matches the serial number. Don't delete the parent VID/PID folder unless you're sure no other devices use it. Right-click the serial subkey, choose Delete, confirm.
Now restart your computer.
Step 3: Reinstall the device
After reboot, Windows will redetect the device and create a fresh registry entry. Open Device Manager, right-click the device (it'll show as unknown or with a bang again), and choose Update driver > Browse my computer > Let me pick from a list. Select the correct driver. If you don't have it, let Windows search automatically — it'll pull from Windows Update.
In 90% of cases, that's it. The error disappears.
Why does this work?
The registry hive under Enum stores device-specific properties like hardware IDs, compatible IDs, and device capabilities. When a property is corrupted — usually due to a partial uninstall, a failed update, or a system restore that left stale data — the setup API can't parse it. The error code 0x800F0209 literally means “invalid registry property.” By deleting the key, you force Windows to rebuild it from scratch using the driver's INF file. No magic, just cleanup.
Less common variations of this issue
Variation 1: The device is internal (PCI, ACPI). You'll see instance paths like PCI\VEN_8086&DEV_...\.... Same fix — delete the subkey. But be careful: internal devices sometimes share a parent key with other components. Only delete the specific device's leaf key, not the parent.
Variation 2: The error appears during driver update, not first install. This happens when the old driver's registry properties conflict with the new driver's INF. Delete the device from Device Manager first (check “Delete the driver software for this device”), then scan for hardware changes. The error usually doesn't come back.
Variation 3: Multiple devices show the same error. Check for a corrupted class-level key. Navigate to HKLM\SYSTEM\CurrentControlSet\Control\Class and look for the ClassGUID that matches the failing devices. If you see weird characters or a mangled value, export the key as a backup, then delete it. Let Windows recreate it on next reboot.
Variation 4: The device is hidden or ghosted. Open Device Manager, go to View > Show hidden devices. Look for grayed-out devices. Right-click and uninstall them. Then delete their registry keys under Enum. Ghosted devices from disconnected USB hubs are common triggers.
Prevention
Stop pulling the USB cable out without safely ejecting. Seriously. That's the number one cause of corrupted Enum keys. Use Safely Remove Hardware or just shut down before unplugging.
Also, don't use third-party driver cleaners. CCleaner's registry cleaner has nuked Enum keys for years. If you must clean, stick to pnputil /delete-driver for driver removal.
Finally, keep a backup of your registry — not the whole thing, just the Enum branch. Run this from an admin prompt once a month:
reg export HKLM\SYSTEM\CurrentControlSet\Enum C:\Backup\enum_backup.regIf it happens again, a quick import saves 20 minutes of hunting.
One last thing: if you're on Windows 11 22H2 or later, Microsoft tightened security on Enum keys. You might need to take ownership of the key before deleting it. Right-click the key, Permissions, Advanced, change owner to Administrators, check “Replace owner on subcontainers and objects,” apply. Then you can delete.
Was this solution helpful?