1What the message says
Minecraft shows it under "Failed to connect to the server". The words after the Java class name depend on the system and the Java the game runs on:
Windows, Minecraft 1.18 and newer
io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: getsockopt
Windows, Minecraft 1.16 and older
io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: no further information
Linux
io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: /203.0.113.10:25565
All three mean one thing. The game reached a machine at that address, and it answered at once that nothing takes connections on that port. Minecraft itself hasn't spoken yet: it's the network saying no.
The ending is Java's. On Windows, Java 8, which Minecraft 1.16 and older ran on, adds "no further information" when it has nothing more to say; Java 17 and 21 name the call that failed, getsockopt.
2Refused, or timed out
On 29 Sep we connected to each kind of address with Netty 4.1.97 on Java 21, the network library and Java that Minecraft 1.21 uses:
| At that address and port | What the game gets | How fast |
|---|---|---|
| A Minecraft server, online | It connects | 57 ms |
| Nothing listening: the server is off, still starting or on another port | Connection refused | 61 to 65 ms |
| A firewall that rejects the connection | Connection refused | 62 to 67 ms |
| A firewall that drops it, or no machine at all | io.netty.channel.ConnectTimeoutException: connection timed out | 30 seconds |
30 seconds is Netty's own limit. On Windows the same wait can also end as Connection timed out: getsockopt, the system's own time-out. A connection that goes quiet once you're in the game ends differently, as Timed out.
3The causes, most likely first
- The server isn't running, or hasn't opened its port yet. A server opens its port only after it has loaded, mods included. Our Paper 1.21.1 test refused connections until its log said
Starting Minecraft server on *:25565, and FTB StoneBlock 4 loads its mods for more than a minute before that. Wait forDonein the log, or for Online in your dashboard. - The address has the wrong port. A Java server listens on 25565 unless it's set otherwise, and any other port goes after a colon, like
play.example.com:25566. - A firewall rejects it. A rule that rejects gives Connection refused, and one that drops gives the time-out. On a VPS, allow the port in the provider's firewall, the one in its web console, and in ufw or firewalld on the machine itself.
server-ipis set in server.properties. The server then listens on that one address. Our test server withserver-ip=127.0.0.1loggedStarting Minecraft server on 127.0.0.1:25565and refused everyone else, and one set to an address the machine doesn't have fails to bind its port and stops. Leave it empty. The server.properties guide explains every setting.- At home, the router doesn't pass the port on. Players from outside reach your router, not your PC, until the router forwards port 25565 to it. Depending on the router, they then see refused or timed out. The port forwarding guide goes step by step.
4Check the port yourself
From a machine outside the server's network, ask whether the port takes connections:
nc -vz -w 5 play.example.com 25565
| What nc says on Linux | What it means |
|---|---|
Connection to 203.0.113.10 25565 port [tcp/*] succeeded! | The port is open. If the game still can't join, check the address it uses. |
connect to 203.0.113.10 port 25565 (tcp) failed: Connection refused | Nothing takes the connection: the causes above. |
connect to 203.0.113.10 port 25565 (tcp) timed out: Operation now in progress | Nothing answered in 5 seconds: a firewall drops it, or the address is wrong. |
On Windows, PowerShell's Test-NetConnection play.example.com -Port 25565 asks the same. On the server, sudo ss -ltnp 'sport = :25565' shows what listens on the port; no line means nothing does.
5On a Playkeeper server
- The Overview says whether the server is online, and its Join card shows the address and port to share.
- The installer allows TCP 25565 in ufw or firewalld when one is on. The provider's firewall needs its own rule: 25565 for the first server, and one more port from 25566 for each further server.
- A stopped server refuses connections, like any other. Its public page tells visitors whether it's online.
Questions
Why does it say no further information?
Java 8 on Windows, which Minecraft 1.16 and older ran on, ends the message that way. Java 17 and 21 end it with getsockopt instead. Both mean nothing took the connection.
What's the difference between Connection refused and connection timed out?
Refused: a machine answered at once that nothing takes connections on that port. Timed out: nothing answered at all, usually a firewall that drops the connection or a wrong address. Netty gives up after 30 seconds.
Why can I join my server but my friends can't?
You connect from the same machine or network, while their connection has to pass your router or your provider's firewall. Check that the port is open from outside, as above.
Does server-ip=127.0.0.1 block other players?
Yes. The server then listens only for connections from its own machine, and everyone else gets Connection refused. Leave server-ip empty.