sodcalculator

10 Tech How-To

Fix AnyDesk Disconnected Network Errors on Windows

Guide 10-47243 · Updated · Step by step

The most reliable fix for “Disconnected from the AnyDesk network” on Windows is to switch the connection from the default UDP-based AnyDesk relay to a direct TCP connection, then adjust the Windows Firewall rules that block AnyDesk’s ports. This resolves the vast majority of cases because the error almost always stems from network address translation (NAT) issues or firewall interference, not a problem with your AnyDesk account or the remote machine itself.

What to Look For

When troubleshooting AnyDesk disconnections, focus on these factors in order of likelihood:

  • Network type – Are you on a public, corporate, or home network? Corporate networks often block the UDP ports AnyDesk uses.
  • Firewall and antivirus – Windows Defender Firewall, third-party firewalls, and security suites frequently block AnyDesk’s incoming connections.
  • NAT and router settings – Strict NAT, carrier-grade NAT (CGNAT), or missing port forwarding can prevent a stable relay connection.
  • AnyDesk settings – The default “Automatic” connection mode may choose an unstable path; forcing TCP or direct connection helps.
  • Version mismatch – Older AnyDesk versions may have bugs fixed in newer releases, but this is less common.
  • Internet stability – Intermittent Wi-Fi or high packet loss can trigger disconnects, but this is usually obvious.

Option 1: Force TCP Connection Mode

AnyDesk’s default “Automatic” mode tries UDP first, which can fail on restrictive networks. Switching to TCP-only often stabilizes the connection.

How to do it: In the AnyDesk window, click the menu button (three horizontal lines) → Settings → Connection → under Network, set Connection type to TCP (or “TCP only” if available). Restart AnyDesk.

Strengths: Simple, no router access needed, works on most networks that block UDP.

Trade-offs: TCP can be slightly slower than UDP on high-latency links, and some networks still block the TCP ports AnyDesk uses.

Best for: Users on corporate or campus networks with strict UDP filtering, and anyone who wants a quick fix before touching firewalls.

Option 2: Allow AnyDesk Through Windows Firewall

Windows Defender Firewall often blocks AnyDesk’s incoming connections, especially after a Windows update. Allowing the app through both private and public profiles is a common fix.

How to do it: Open Windows Security → Firewall & network protection → Allow an app through firewall → click Change settings → find AnyDesk in the list → check both Private and Public boxes → OK. If AnyDesk isn’t listed, click Allow another app and browse to C:\Program Files (x86)\AnyDesk\AnyDesk.exe.

Strengths: Directly addresses the most common cause of disconnects on Windows; works for both incoming and outgoing connections.

Trade-offs: If you have a third-party firewall (Norton, McAfee, etc.), you must also add an exception there. Some security suites require disabling “advanced protection” temporarily.

Best for: Most home users and anyone who has recently updated Windows or installed a new security tool.

Option 3: Enable Direct Connection (Port Forwarding)

If you control the router of the remote machine, forwarding the AnyDesk ports (TCP 7070, UDP 7070, and TCP 50000-50003) to the remote PC’s local IP can bypass the relay server entirely, eliminating relay-related disconnects.

How to do it: On the remote PC, note its local IP (e.g., 192.168.1.50). Log into your router’s admin page (often 192.168.1.1 or 192.168.0.1), find Port Forwarding or Virtual Server, and add rules for the ports above, pointing to that IP. Then in AnyDesk on the remote PC, go to Settings → Connection → enable Direct connection (or set “Direct” as the preferred method).

Strengths: Most stable and fastest connection, especially for file transfers or remote gaming; removes dependence on AnyDesk relay servers.

Trade-offs: Requires router admin access, which many users don’t have on corporate or public networks. Also, the remote PC’s IP must be static or reserved in DHCP, or the port forward will break.

Best for: Advanced users, IT administrators, and anyone connecting to a home PC from outside on a regular basis.

Option 4: Disable UDP and Use AnyDesk’s “Relay” Fallback

Sometimes the issue is that AnyDesk’s automatic negotiation picks UDP, but your ISP or router corrupts or drops UDP packets. Forcing the client to use the relay server (which is TCP-based) can help.

How to do it: In AnyDesk settings, under Connection, set Connection type to Relay (or “Relay only”). This makes AnyDesk use its own servers to relay traffic, which is more compatible but slower.

Strengths: Works behind strict NAT and CGNAT where direct TCP fails; no router configuration needed.

Trade-offs: Higher latency and bandwidth usage; if the relay server itself is congested, you may still see disconnects.

Best for: Users on mobile hotspots, hotel Wi-Fi, or any network where you cannot change router settings.

Option 5: Reinstall AnyDesk with Clean Settings

Corrupted configuration files or an outdated installation can cause persistent disconnection issues. A clean reinstall resets all network settings to default.

How to do it: Uninstall AnyDesk via Settings → Apps → Apps & features → select AnyDesk → Uninstall. Then delete the leftover folder C:\Users\<username>\AppData\Roaming\AnyDesk (if it exists). Download the latest version from the official website and install. Re-enter your AnyDesk ID and password.

Strengths: Fixes issues caused by corrupted settings, missing DLLs, or version conflicts.

Trade-offs: You’ll need to reconfigure your preferences (e.g., security settings, permissions).

Best for: Users who have tried other fixes and still see disconnects, or who have recently upgraded from an old version.

Option 6: Adjust Router NAT and QoS Settings

Some routers have aggressive NAT timeouts or QoS (Quality of Service) rules that drop long-lived UDP connections, which AnyDesk uses for its default relay. Adjusting these can prevent idle disconnects.

How to do it: In your router’s admin panel, look for NAT settings and increase the UDP timeout (e.g., from 30 seconds to 300 seconds). Also, disable any “SIP ALG” or “Symmetric NAT” features if present. For QoS, either disable it or prioritize AnyDesk traffic.

Strengths: Addresses the root cause of disconnects that happen after a few minutes of inactivity.

Trade-offs: Router interfaces vary widely; you may need to consult your router’s manual. Some ISP-provided routers don’t expose these settings.

Best for: Users who experience disconnects after a few minutes of idle time, not immediately upon connecting.

How to Choose

Start with the cheapest and easiest fixes first. If you’re a home user, try Option 2 (firewall) and Option 1 (TCP mode) before anything else. If you’re on a corporate network, jump to Option 1 and Option 4, since you likely can’t change firewall or router settings. If you control the remote router and need maximum stability for daily use, invest time in Option 3 (port forwarding). For intermittent disconnects after idle periods, focus on Option 6. Budget is rarely a factor—all these fixes are free—but your time and access level matter most.

Frequently Asked Questions

Why does AnyDesk disconnect after a few seconds?

This usually indicates a firewall or NAT timeout. Check Windows Firewall first, then try forcing TCP mode. If it still drops, your router’s UDP timeout is likely too short.

Does reinstalling AnyDesk delete my computer’s address?

No, your AnyDesk ID is tied to the machine’s hardware, not the installation. It will remain the same after reinstall. You may need to re-set a password for unattended access.

Can I use AnyDesk without the relay server?

Yes, if you set up port forwarding and use “Direct” connection mode. This requires a public IP or a router that supports port forwarding. Without it, AnyDesk falls back to the relay.

Is it safe to allow AnyDesk through the firewall?

Yes, as long as you only allow the official AnyDesk executable. Avoid allowing “AnyDesk” from unknown paths. Also, ensure your AnyDesk password is strong and two-factor authentication is enabled if available.

Why does AnyDesk work on my phone but not on Windows?

Windows has a more restrictive firewall and often runs third-party security software. The phone app may use different network paths. Apply the same TCP and firewall fixes on the Windows machine.

Will changing to TCP mode affect speed?

TCP is slightly slower than UDP on high-latency connections because of error correction, but for most remote desktop tasks the difference is negligible. If you need maximum speed, use direct TCP with port forwarding.

Bottom Line

For most Windows users, the fastest and most effective fix is to allow AnyDesk through Windows Firewall and switch the connection type to TCP. If that doesn’t work, move to the relay-only option or reinstall. For persistent, long-term use, setting up direct port forwarding is the most robust solution, but it requires router access. Start with the firewall and TCP changes—they solve the majority of disconnection issues without any downside.

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 →