| Previous | Next |
| WSAEHOSTDOWN | WSAENOTEMPTY |
WSAEHOSTUNREACH
WSAEHOSTUNREACH means that a socket operation was attempted to a host that cannot be reached. Unlike WSAENETUNREACH, the network route may exist while the particular host remains unreachable.
Useful distinction
Use the resolved destination address, route, and interface in diagnostics. A hostname that resolves successfully can still lead to this error because name resolution and packet delivery are separate stages.
What to check
- Confirm that the address belongs to the intended remote system.
- Check reachability from the local network and from the selected IPv4 or IPv6 path.
- Compare the result with another host on the same subnet or route.
- Do not report this as a connection refusal; a refusal implies that the target was reached and rejected the connection.
Microsoft: connect · Microsoft: Windows Sockets Error Codes
Looking for a different code? Search another status or error code.