minecraftseverity: can-fix
NETTY

Minecraft io.netty.channel.ConnectTimeoutException — can't connect to server

Can't connect to server — connection timed out

85% fixable~5 mindifficulty: beginner

Verified against Minecraft Wiki — Tutorials/Setting up a server, Mojang Support — Multiplayer connection issues, r/Minecraft troubleshooting megathread · Updated June 2026

> quick_fix

Verify the server IP and port are correct, then check if the server is online using mcsrvstat.us. If it is online, temporarily disable your firewall or antivirus and retry. Most ConnectTimeoutException cases are a wrong address or blocked port 25565.

# Test if the server port is reachable (replace with your server IP)
nc -zv play.example.com 25565

# Windows: allow Minecraft through firewall
netsh advfirewall firewall add rule name="Minecraft" dir=in action=allow program="%appdata%\.minecraft\runtime\java-runtime-gamma\bin\javaw.exe" enable=yes

What causes this error

Minecraft uses Netty for all multiplayer network communication. ConnectTimeoutException means your client sent a TCP SYN packet to the server's IP and port but never received a SYN-ACK within the 30-second default timeout. The server is either offline, the IP/port is wrong, a firewall is blocking outbound connections on port 25565, or your ISP is dropping the packets. On self-hosted servers, the most common cause is forgetting to port-forward 25565 on the router.

> advertisementAdSense placeholder

How to fix it

  1. 01

    step 1

    Confirm the server is online

    Visit mcsrvstat.us and enter the server address. If it shows offline, the problem is server-side — contact the server admin. If you're hosting, check that the server process is running.

  2. 02

    step 2

    Verify IP address and port

    Double-check the server address in Minecraft's multiplayer menu. A common mistake is typing the internal LAN IP (192.168.x.x) when connecting from outside the network, or forgetting a non-default port. The format is play.example.com:25565.

  3. 03

    step 3

    Check your firewall and antivirus

    Windows Defender, Norton, Bitdefender, and Kaspersky all block Java networking by default. Temporarily disable your firewall, try connecting, and if it works, add javaw.exe to the allowed list.

    Windows: Control Panel → System and Security → Windows Defender Firewall → Allow an app → Add javaw.exe
    macOS: System Settings → Network → Firewall → Options → Add java
  4. 04

    step 4

    Port-forward if you're hosting

    Log into your router (usually 192.168.1.1 or 192.168.0.1). Add a port-forwarding rule: external port 25565 → internal IP of your server machine → internal port 25565, protocol TCP. Save and restart the server.

    In server.properties, verify:
    server-port=25565
    server-ip=        (leave blank to bind all interfaces)
    online-mode=true
  5. 05

    step 5

    Try a direct IP connection

    If using a domain name, try the raw IP instead. DNS resolution failures look identical to connection timeouts. On Windows, run 'nslookup play.example.com' in Command Prompt to get the IP.

    nslookup play.example.com
    # Use the returned IP directly in Minecraft's server address field

How to verify the fix

  • Join the server successfully and see the world loading screen
  • Run 'nc -zv serverip 25565' and get 'Connection succeeded'
  • mcsrvstat.us shows the server as online with correct player count

Why NETTY happens at the runtime level

Minecraft's network stack is built on Netty, an asynchronous event-driven framework. When you click 'Join Server,' the client creates a Bootstrap with NioSocketChannel and calls connect() with a 30-second timeout. If the TCP three-way handshake (SYN → SYN-ACK → ACK) doesn't complete within that window, Netty's ConnectTimeoutHandler fires and throws ConnectTimeoutException. The failure happens at the transport layer — before any Minecraft protocol packets are exchanged — which is why the error contains no game-specific information, only the raw Netty class name.

Common debug mistakes for NETTY

  • Using the server's LAN IP (192.168.x.x) when connecting from outside the local network — you need the public IP or domain name.
  • Forgetting to port-forward 25565 on the router when hosting a server, then wondering why friends can't connect.
  • Restarting Minecraft repeatedly instead of checking if the server itself is actually online.
  • Assuming the error means the server banned you — bans show a completely different message after the connection succeeds.
  • Not checking if antivirus software quarantined javaw.exe, which silently blocks all Java networking.

When NETTY signals a deeper problem

If ConnectTimeoutException happens on every server you try, the issue is local. Your Java runtime's networking may be broken — especially if you installed a modded launcher that ships its own JRE. Corporate and school networks often run deep packet inspection that blocks non-HTTP traffic on non-standard ports, making 25565 completely unreachable. In these environments, no amount of client-side configuration will help; you need a VPN or the server admin needs to run on port 443. Persistent timeouts to a single server you previously connected to fine often mean the hosting provider changed IP ranges or the server moved to a different machine without updating DNS.

Editor's take

ConnectTimeoutException is Minecraft's most misleading error because it tells you nothing about why the connection failed — only that it did. The Netty stack trace looks alarming to non-technical players, with its Java package names and channel pipeline references, but the actual problem is almost always mundane: wrong IP, server offline, or a firewall eating packets on port 25565.

The most frustrating variant hits players hosting servers for friends. They test locally, everything works, they share their IP, and nobody can connect. The missing step is always port forwarding. Every consumer router ships with inbound ports blocked by default, and 25565 is not in any router's default allowed list. The player Googles the error, finds forum posts about DNS and Netty buffer sizes, and goes down a rabbit hole when the fix is a 30-second router configuration.

School and corporate networks are the second-largest source. These environments run egress firewalls that whitelist ports 80 and 443 and block everything else. Port 25565 never makes it out. A VPN solves it, but many school networks also block VPN protocols. The real workaround is a server running on port 443 with a TCP proxy — the school firewall sees HTTPS-shaped traffic and lets it through.

For server operators: if players report intermittent ConnectTimeoutException, check your hosting provider's DDoS protection. Many budget Minecraft hosts (OVH, Hetzner, etc.) have automatic DDoS mitigation that occasionally false-positives on legitimate player connections, especially from mobile networks with carrier-grade NAT that share IPs across thousands of users.

By Bikram Nath · Curator · Updated June 2026

Frequently asked questions

Why do I get this error on only one server but others work fine?

That specific server is either offline, has changed its IP/port, or has banned your IP. It can also mean the server has a whitelist enabled and you're not on it — though whitelist rejection usually shows a different message after the connection succeeds.

Can a VPN fix ConnectTimeoutException?

Yes, if your ISP is blocking port 25565 or throttling gaming traffic. A VPN routes around the ISP's firewall. This is common in school and university networks that block game server ports.

Does this error mean I'm banned from the server?

No. A ban shows 'You are banned from this server' after the connection succeeds. ConnectTimeoutException means the connection never reached the server at all — it's a network-level issue, not an account-level one.

disclosure:Errordex runs AdSense, has zero third-party affiliate or sponsored links, and occasionally links to the editor’s own paid digital products (clearly labelled). Every fix is cross-referenced against the official sources listed in the “sources” sidebar before it ships. If a fix here didn’t work for you, please email so we can update the page.