Skip to content

How-ToGPU

How to Fix DXGI_ERROR_DEVICE_REMOVED and DXGI_ERROR_DEVICE_HUNG Game Crashes in Windows 11

Game crashing with DXGI_ERROR_DEVICE_REMOVED or DXGI_ERROR_DEVICE_HUNG? Here's what Microsoft says the 0x887A codes mean, why Windows resets a stalled graphics card, and the fixes to try in order: patch the game, read the logs, undo overclocks, clean-install the driver, then check heat, power and VRAM.

By , Systems & Technical Editor

5 min read

How to Fix DXGI_ERROR_DEVICE_REMOVED and DXGI_ERROR_DEVICE_HUNG Game Crashes in Windows 11

If a game closes with a message that mentions DXGI_ERROR_DEVICE_REMOVED, DXGI_ERROR_DEVICE_HUNG or a code beginning 0x887A, the game has lost contact with your graphics card. It's a frustrating crash message, and in our view it can come from the graphics driver, the game itself, an unstable overclock, heat, power or, less often, a failing card. This guide explains what Microsoft says the codes mean, what usually sits behind them, and the order we'd work through the fixes. The technical detail comes from Microsoft Learn, credited below, and where something is our advice rather than Microsoft's, we say so.

What the DXGI error codes mean

DXGI is the part of DirectX that sits between a game and your graphics driver. Microsoft's list of DXGI error codes describes the three you're most likely to see like this:

Error

Code

Microsoft's description

DXGI_ERROR_DEVICE_REMOVED

0x887A0005

"The video card has been physically removed from the system, or a driver upgrade for the video card has occurred."

DXGI_ERROR_DEVICE_HUNG

0x887A0006

"The application's device failed due to badly formed commands sent by the application."

DXGI_ERROR_DRIVER_INTERNAL_ERROR

0x887A0020

"The driver encountered a problem and was put into the device removed state."

Your graphics card obviously hasn't been pulled out mid-game. In practice, "device removed" is what a game sees when Windows has had to reset the graphics driver underneath it, and Microsoft's description of DEVICE_HUNG points at the game sending commands the GPU couldn't handle. That's why the same message can be caused by a buggy game patch on one PC and by a flaky overclock on another.

Why Windows resets the graphics card

In our view, the usual trigger is a Windows feature called timeout detection and recovery (TDR). Microsoft explains that TDR "detects when the graphics card takes longer than expected to complete an operation" and then "resets the graphics card to prevent the entire system from becoming unresponsive." The default timeout is two seconds: if the GPU "can't complete or preempt the current task within the TDR timeout period, the OS diagnoses that the GPU is frozen."

When Windows recovers successfully, it shows the message "Display driver stopped responding and has recovered" and logs it in Event Viewer. Microsoft says well-written DirectX applications "that handle Device Remove technology continue to work correctly", because they "release and then re-create" their Direct3D device after the reset. In our view, a game that shows a DXGI error message is one that didn't recover this way and quit with a DXGI error. Microsoft also says that, by default, Windows bug-checks the PC "on the sixth (or more) GPU hang" when five or more hangs and recoveries happen within one minute, which is when a game crash becomes a blue screen.

So the question to answer is: why is the graphics card stalling for more than two seconds?

Step 1: Check whether it's one game or every game

If only one game crashes, start with the game. Check its official support page or patch notes for known DXGI crashes, install the latest update and verify its files with our guide to verifying game files on PC. In our view, it's also worth trying the game's other graphics API if it offers one (DirectX 11 instead of DirectX 12, for example) and turning off its newest features, such as ray tracing or frame generation, to see whether the crashes stop.

If several games crash, or you also see the "Display driver stopped responding" message on the desktop, the driver or the hardware is more likely. Our guide to fixing display driver stopped responding errors covers that message in more detail.

Step 2: Read the logs

Open Event Viewer and look under Windows Logs > System for errors logged at the time of the crash, particularly from your graphics driver (for example nvlddmkm for NVIDIA cards). Our guide to using Event Viewer in Windows 11 shows where to look, and Reliability Monitor gives an easier timeline of crashes. If the PC has blue-screened, our guide to analysing a BSOD minidump with WinDbg explains how to read the dump.

Step 3: Undo overclocks and recent driver changes

An unstable overclock is one of the easiest causes to rule out. In our view, you should return the graphics card, its memory and your CPU and RAM to stock settings before testing anything else, including factory OC profiles you've switched on in a tuning app. If you've undervolted the card, undo that too, because a too-aggressive undervolt can also cause timeouts. Our guide to undervolting a GPU explains how to reset it.

If the crashes started right after a new graphics driver, roll it back with our guide to rolling back a graphics driver.

Step 4: Clean-install the graphics driver

If nothing changed recently, a clean reinstall of the graphics driver is the next step. Download the current driver for your card from NVIDIA, AMD or Intel, remove the old one completely, then install the new one. Our guide to clean-installing graphics drivers with DDU walks through it, and how to update graphics drivers covers each vendor's app.

Step 5: Rule out heat and power

A GPU that overheats or runs short of power can stall long enough to trigger a reset. Watch its temperature during a game with our guide to checking GPU temperature in Windows 11. On a desktop, make sure every power connector on the card is fully seated, using separate cables where the PSU maker recommends it: see how to check PSU and GPU power connectors. If the crashes only happen under heavy load, how to tell if your PSU is failing lists the warning signs.

Step 6: Test the graphics card's memory

If the crashes carry on through a clean driver install at stock settings, test the card's own memory. Our guide to testing GPU VRAM with memtest_vulkan shows how. Errors there, or crashes that follow the card into another PC, point to a hardware fault, and it's time to contact the retailer or manufacturer while it's under warranty.

Should you change the TDR registry settings?

You'll find plenty of forum advice to raise the TdrDelay value in the registry so Windows waits longer before resetting the GPU. We don't recommend it. Microsoft lists the TDR registry keys "for testing or debugging purposes only during the driver development process", and says plainly: "End users shouldn't manipulate these registry keys." Raising the timeout doesn't fix whatever is making the GPU stall; at best it hides the symptom.

The bottom line

DXGI_ERROR_DEVICE_REMOVED (0x887A0005) and DXGI_ERROR_DEVICE_HUNG (0x887A0006) mean a game lost its graphics device, usually because Windows reset a GPU that stopped responding for more than its two-second timeout. Check whether one game or every game is affected, patch and verify the game, read Event Viewer, return overclocks and undervolts to stock, and clean-install the graphics driver. If it keeps happening, check temperatures, power connectors and the card's memory. Don't edit the TDR registry keys: Microsoft says end users shouldn't.

Sources

  1. 01DXGI_ERROR (Microsoft Learn)
  2. 02WDDM support for timeout detection and recovery (Microsoft Learn)
  3. 03Testing and debugging TDR during driver development (Microsoft Learn)

About the author

Marcus Thorne

Systems & Technical Editor

Marcus writes Forge PC's step-by-step build, troubleshooting and system optimisation guides. His background spans Windows kernel and power-state diagnostics, UEFI/BIOS configuration, NVMe storage arrays, ATX 3.1 power delivery and running local AI and LLM workloads on consumer graphics cards.

More from Marcus Thorne

Read next

How to Run the Windows Malicious Software Removal Tool (MSRT)

How-To

How to Run the Windows Malicious Software Removal Tool (MSRT)

Windows Update runs Microsoft's Malicious Software Removal Tool every month, but you can also run it yourself. We explain what MSRT can and can't remove, how to download and run it, what its results mean, where mrt.log lives and which command-line switches Microsoft documents.

Marcus Thorne4 min

How to Use Microsoft Safety Scanner to Check a Windows PC for Malware

How-To

How to Use Microsoft Safety Scanner to Check a Windows PC for Malware

Microsoft Safety Scanner is a free, portable second-opinion malware scanner for Windows. We explain what it is and isn't, how to download the right version, choose a quick, full or customised scan, read msert.log, run it from the command line and remove it afterwards.

Marcus Thorne4 min