sodcalculator

10 Tech How-To

Fix RDP Error 0x80004005: Step-by-Step Guide

Guide 10-59493 · Updated · Step by step

Remote Desktop Connection (RDP) error 0x80004005 is a generic “Unspecified Error” that typically appears when Windows cannot establish or maintain a remote session. It affects both Windows 10 and Windows 11 users and is often caused by network configuration issues, outdated credentials, or corrupted RDP settings. This guide walks through the most reliable fixes, from quick resets to deeper system adjustments.

What You’ll Need

  • Administrator access on both the local and remote Windows machines
  • The exact IP address or hostname of the computer you’re trying to reach
  • Valid login credentials for the remote system
  • Ability to restart services or reboot the remote machine (if you have physical or console access)

Step-by-Step

  1. Verify the Remote Desktop service is running. On the target computer, press Win + R, type services.msc, and press Enter. Scroll to Remote Desktop Services (TermService). If its status is not “Running,” right-click it and select Start. Also set the Startup type to Automatic by double-clicking the service, changing the dropdown, and clicking OK.

  2. Clear cached RDP credentials on your local machine. Open Credential Manager (search for it in the Start menu). Under Windows Credentials, look for entries that start with TERMSRV/ followed by the remote computer’s name or IP. Click the arrow next to each one and select Remove. This clears any stale or corrupted login data that triggers 0x80004005.

  3. Reset the RDP connection cache. Press Win + R, type regedit, and press Enter. Navigate to HKEY_CURRENT_USER\Software\Microsoft\Terminal Server Client\Default. In the right pane, delete any values under MRU (Most Recently Used) that reference the problematic server. Also go to HKEY_CURRENT_USER\Software\Microsoft\Terminal Server Client\Servers and delete the subkey matching the remote computer’s name or IP. Close the registry editor and try connecting again.

  4. Check Network Level Authentication (NLA) settings. On the remote machine, press Win + R, type sysdm.cpl, and press Enter. Go to the Remote tab. Ensure “Allow remote connections to this computer” is checked. If “Allow connections only from computers running Remote Desktop with Network Level Authentication” is checked, try unchecking it temporarily. This resolves compatibility issues where the client and server negotiate NLA differently.

  5. Flush DNS and reset the network stack. On your local machine, open Command Prompt as Administrator (right-click Start > Terminal (Admin) or Command Prompt (Admin)). Run these commands one at a time, pressing Enter after each:

    ipconfig /flushdns
    netsh int ip reset
    netsh winsock reset

    Restart your computer after running these commands. This clears corrupted network state that can block RDP handshakes.

  6. Adjust RDP encryption level via Group Policy. Press Win + R, type gpedit.msc (Pro/Enterprise editions only), and press Enter. Navigate to Computer Configuration > Administrative Templates > Windows Components > Remote Desktop Services > Remote Desktop Session Host > Security. Double-click Set client connection encryption level, select Enabled, and set the encryption level to High (or Low if High fails). Click OK and restart the Remote Desktop service or reboot the machine.

  7. Verify firewall rules are not blocking port 3389. On the remote machine, open Windows Defender Firewall with Advanced Security. Click Inbound Rules and ensure both “Remote Desktop – User Mode (TCP-In)” and “Remote Desktop – User Mode (UDP-In)” are Enabled. If they are disabled, right-click each and select Enable Rule. If you use a third-party firewall, add an exception for TCP and UDP port 3389.

  8. Test with a different RDP client or protocol version. Open the Remote Desktop Connection app (mstsc). Click Show Options, go to the Experience tab, and set the connection speed to LAN (10 Mbps or higher). On the Advanced tab, try changing the authentication method from “Always ask” to “Connect and don’t warn me.” If the issue persists, try using the Microsoft Remote Desktop app from the Store or the mstsc /admin command (which connects to the console session).

  9. Update network and graphics drivers. On both machines, open Device Manager (right-click Start > Device Manager). Expand Network adapters, right-click your adapter, and select Update driver > Search automatically. Do the same under Display adapters. Outdated drivers, especially GPU drivers, are a known trigger for 0x80004005 during RDP session establishment.

  10. Reboot the remote machine. If you have physical or console access, restart the target computer. This clears any hung RDP listener processes. After reboot, verify the Remote Desktop service is running again (Step 1) before attempting a connection.

Common Mistakes

  • Skipping the credential cache clear. Many users only restart services and never clear stored credentials. The cached password is often the root cause.
  • Editing the registry without backing it up. Always export the registry key before deleting anything. A wrong deletion can break other RDP features.
  • Changing NLA settings permanently. Unchecking NLA reduces security. Re-enable it after testing to keep the connection safe.
  • Forgetting to restart after network resets. The netsh commands only take full effect after a reboot.
  • Assuming the error is always on the client. The problem can be on the remote server’s configuration, so test both sides.

Tips

  • Use the IP address instead of the hostname if DNS resolution is flaky. If the IP works but the name doesn’t, the issue is DNS, not RDP.
  • Create a new local user account on the remote machine and try connecting with it. This isolates whether the problem is tied to a specific user profile.
  • Check the Event Viewer on the remote machine under Windows Logs > System for events with source TermDD or RemoteDesktopServices. The error details often point to the exact failing component.
  • If you are connecting over a VPN, disconnect and try a direct LAN connection to rule out VPN MTU or routing issues.
  • Keep both machines updated with the latest Windows patches. Microsoft has released specific fixes for 0x80004005 in cumulative updates.

Troubleshooting

If the error persists after all steps, try these additional measures:

  • Check for third-party antivirus interference. Temporarily disable the antivirus firewall on both machines (not just the Windows firewall) and test. If the connection works, add RDP (mstsc.exe and svchost.exe) to the antivirus exclusions.
  • Verify the remote machine is actually reachable. From your local machine, run ping [remote-IP] and then Test-NetConnection [remote-IP] -Port 3389 in PowerShell. If the port test fails, the remote machine is not listening, which points to a service or firewall issue on that side.
  • Try a different user account. If possible, log in to the remote machine with a different admin account. A corrupted user profile can cause this error.
  • Check for RDP listener issues. On the remote machine, open Command Prompt as Administrator and run qwinsta. If the listener shows a state other than “Active” or “Connecting,” restart the Remote Desktop service.
  • Disable IPv6 temporarily. On the remote machine, open Network Connections, right-click your adapter, select Properties, and uncheck Internet Protocol Version 6 (TCP/IPv6). Test the connection. Re-enable it afterward if it doesn’t help.
  • Perform a system file check. On the remote machine, run sfc /scannow in an elevated Command Prompt. Corrupted system files can break the RDP stack.

Frequently Asked Questions

Q: Does error 0x80004005 mean my computer is hacked?
A: No. It is a standard Windows error code meaning “Unspecified Error.” It indicates a communication or configuration failure, not a security breach.

Q: Will these steps work for Windows 11?
A: Yes. The steps apply to both Windows 10 and Windows 11. The service names, registry paths, and Group Policy locations are the same.

Q: Why does this error happen only sometimes?
A: Intermittent occurrences often point to network instability, VPN reconnects, or the remote machine’s RDP service restarting. The credential cache and DNS flush steps help with sporadic cases.

Q: Do I need to be an administrator to fix this?
A: Yes, for most steps. Changing services, editing the registry, and modifying Group Policy require admin rights on the respective machine.

Q: Can I fix this without rebooting the remote machine?
A: Yes, many fixes (clearing credentials, flushing DNS, adjusting NLA) do not require a reboot. A reboot is only suggested as a last resort if services hang.

Q: What if I don’t have physical access to the remote machine?
A: You can still fix the client-side issues (credential cache, DNS, network stack). For server-side fixes, you will need console access, a remote management tool like PowerShell Remoting, or help from someone at that location.

Related

General steps for current mainstream versions; menus can differ by device and version. See the disclaimer or report an error.

More in this bed

The whole Tech How-To bed →