Offer Why us? How it works?
Guide

Minecraft getsockopt Error: Fix Connection Refused and Timed Out

The message io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: getsockopt looks scary, but it only says one thing: your game couldn't open a connection to the server. We explain the difference between refused and timed out and go through the fixes in the order they usually work.

Updated: 10 min read
Table of contents
  1. What does the getsockopt error mean in Minecraft?
  2. 1. Is the server online and fully started?
  3. 2. Is the address and port correct?
  4. 3. Java or Bedrock – are you joining the right edition?
  5. 4. Firewall or antivirus on your PC
  6. 5. School, work, public Wi-Fi or a VPN
  7. 6. DNS and IP address problems
  8. 7. Hosting the server at home: port forwarding and the firewall
  9. Fixing getsockopt on a Spot.gg server
  10. Where is the address and port?
  11. Is the server running?
  12. Did the server's activity period end?
  13. FAQ
  14. What does "Connection refused: getsockopt" mean?
  15. What does "Connection timed out: getsockopt" mean?
  16. Is the getsockopt error caused by my mods or my Minecraft version?
  17. Why can I join my own server but my friends get getsockopt?
  18. Can I fix getsockopt by reinstalling Minecraft or Java?
  19. Does "no further information" mean something different?

What does the getsockopt error mean in Minecraft?

It means your game could not open a network connection (TCP) to the server – the problem is reaching the server at all, not your account, mods or game version. The full message usually looks like one of these:

  • io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: getsockopt
  • io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection timed out: getsockopt

io.netty is the networking library Minecraft Java uses, and getsockopt is just the name of the low-level system call where Java noticed that the connection failed. Neither part tells you much. The important words are in the middle: refused or timed out. On some systems the end of the message says no further information instead of getsockopt – it's the same error.

Message What happened Most likely causes
Connection refused Your connection reached the address, but nothing was listening on that port Server is off or still starting, wrong port, server crashed during startup
Connection timed out Your connection got no answer at all Wrong IP, firewall dropping traffic, blocked network, port not forwarded on a home server

In short: "refused" usually means right place, nobody home; "timed out" usually means you never got there. Go through the fixes below in order – the first three solve most cases.

1. Is the server online and fully started?

A server that is turned off, restarting or still loading refuses connections, so check this first. A Minecraft server only accepts players after it has finished loading; in the server console that is the line starting with Done ( – for example Done (12.345s)! For help, type "help". Before that line, players get "Connection refused". Big modpacks can take a few minutes to get there.

  • If it's someone else's server, ask the owner whether it's running, or wait a few minutes and try again.
  • If it's your server, open the console and wait for the Done line. If an error appears instead and the server stops or hangs, the server never opened its port – fix that error first (a missing mod or a wrong Java version are common reasons).
  • Refresh the server list in "Multiplayer". A server that shows a ping and a player count is reachable; one stuck on "Can't connect to server" is not.

2. Is the address and port correct?

A typo in the address or a missing port is the second most common cause. Check the address character by character and compare it with what the server owner gave you.

  • Port after the colon. If the server doesn't use the default port 25565, you must type the port: 51.75.10.20:25566. Without it the game tries 25565 and gets "Connection refused" or a timeout.
  • No extras. No http://, no spaces, no trailing slash, no full stop at the end.
  • Old entry in your server list. If the server moved or changed its address, the saved entry still points to the old one. Delete it and add the server again with the current address.
  • Domain vs IP. A domain like play.example.com keeps working when the server moves to a new IP; a hard-coded IP doesn't. If the owner gave you a domain, use it.

Where exactly to type the address and when the port is needed is covered step by step in how to join a Minecraft server.

3. Java or Bedrock – are you joining the right edition?

Minecraft Java Edition can't connect to a Bedrock server, and Bedrock can't connect to a Java server, unless the server owner set up crossplay. The two editions use different protocols and different default ports (Java: TCP 25565, Bedrock: UDP 19132), so a Java client pointed at a Bedrock server simply finds nothing to talk to and fails with "refused" or "timed out".

  • You get the io.netty / getsockopt message only in Java Edition on PC.
  • If the server is a Bedrock server, join it from Bedrock Edition (Windows, Xbox, PlayStation, Switch, phone).
  • For Bedrock players on a Java server, the server needs Geyser – see Minecraft crossplay.

4. Firewall or antivirus on your PC

If other players can join and only you can't, your own firewall or antivirus may be blocking Java. This mostly shows up as "Connection timed out".

  1. Open Windows Security → Firewall & network protection → Allow an app through firewall.
  2. Find the Java entries (javaw.exe / java.exe, or "OpenJDK Platform binary") and make sure they're allowed. If you were asked "Allow access?" the first time you launched the game and clicked "Cancel", this is where you undo it.
  3. If you use a third-party antivirus or "internet security" suite, temporarily turn off its firewall or network protection and try once. If the connection works, add an exception for Java instead of leaving protection off.

5. School, work, public Wi-Fi or a VPN

Many school, work and public networks only allow web traffic and block game ports, so the connection times out. A VPN can do the same, or route you through a server that blocks the port.

  • Test with a different network: turn on a hotspot on your phone and connect the PC to it. If the server works there, your normal network is the problem.
  • Turn off the VPN (or proxy) and try again.
  • On a managed network (school, office, dorm) you can't change this yourself – only the network administrator can.

6. DNS and IP address problems

If the address is a domain, your PC first has to translate it to an IP – an outdated or wrong answer sends you to the wrong place and the connection fails. This often happens right after a server changed its address or moved.

  • Flush the DNS cache on Windows: open Command Prompt and run ipconfig /flushdns, then restart the game.
  • Try the IP or a backup address if the server owner gave you one. If that works and the domain doesn't, it's a DNS issue.
  • Own domain behind Cloudflare? The DNS records for a game server must be set to "DNS only" (grey cloud). The Cloudflare proxy (orange cloud) doesn't pass Minecraft traffic.
  • Typing an IP? Use the server's public IPv4 address (four numbers separated by dots). Local addresses such as 192.168.x.x only work inside the same home network.

7. Hosting the server at home: port forwarding and the firewall

If you run the server on your own PC and friends get "timed out" while you can join, the connection is being stopped at your router or your firewall. You join through localhost, so you never notice the problem; everyone outside your home has to get through the router first.

  1. Forward the port. In your router's settings, forward TCP 25565 (or the port set in server-port in server.properties) to the local IP of the PC running the server.
  2. Allow Java in Windows Firewall on the PC with the server – the same steps as in point 4, for the Java the server runs on.
  3. Give friends your public IP, not 192.168.x.x. You can check it on any "what is my IP" website.
  4. Leave server-ip empty in server.properties. A wrong value there makes the server fail to start ("Failed to bind to port").
  5. Check for CGNAT. If the WAN/internet IP shown in your router is different from the IP on "what is my IP" websites (often a 100.x.x.x address), your provider uses carrier-grade NAT and port forwarding can't work. Ask the provider for a public IP or use a hosted server.

Also remember the server is only reachable while your PC is on. A full home setup is explained in how to make a Minecraft server, and why a hosted server is easier for friends in Minecraft server 24/7.

Fixing getsockopt on a Spot.gg server

On Spot.gg check three things: that you use the address from the panel, that the server shows "Online" and that the console doesn't show an error. Router settings and port forwarding don't apply – the ports are already open on our side.

Where is the address and port?

  • Top of the server panel. The server address is shown next to the server name – click it to copy. A Minecraft Java server's main address looks like yourname.spot.gs and works without a port. A Bedrock server shows the address and the port separately; type them into separate fields in the game.
  • "How to connect?" next to the address opens instructions for your server: which game version to launch, which address to type and, for modpacks, which pack to install.
  • "Network" in the server menu lists the "Custom address" and the "Basic address" (the technical one, in the form sID-xxxxx.spot.gs:port). The basic address is permanent and always works, even if you change the custom one – it's the best backup when a player gets "Connection refused".
  • Changed the custom address? The old address stops working right away and the new one may need a moment before every DNS server knows it. Give players the new address, or let them use the basic address in the meantime.

Is the server running?

  • The power button at the top of the panel shows "Online" when the server is running and "Offline" when it's stopped.
  • In "Console", a stopped server shows "The server is stopped. Start it to send commands." with a "Start server" button.
  • "Online" means the server process is running, not that it finished loading. Watch the console for the Done ( line. If the console shows an error before it (for example a missing mod or "Failed to bind to port") and players get "Connection refused", the server never opened its port – fix the error and restart.

Did the server's activity period end?

When a server's period ends – including a free server after its 24 hours – the server is stopped and locked until you extend it. A locked server can't be started, so players get "Connection refused" or "timed out" however correct the address is.

  • The panel then shows a red bar "Server locked — the activity period ended" with an "Extend activity" button, and only "Information", "Network" and "History" are available in the menu.
  • After the extension the server is unlocked, with your world, files and settings in place. Extend it before the date shown in the bar – after that the server and its data are deleted.

Paid servers on Spot.gg start from $3.90 per month.

FAQ

What does "Connection refused: getsockopt" mean?

Your connection reached the server's address, but nothing was listening on that port. Usually the server is off, still starting or crashed during startup, or you're using the wrong port.

What does "Connection timed out: getsockopt" mean?

Your connection got no reply at all. Usually the IP is wrong, a firewall or network (school, work, VPN) blocks the traffic, or a home server's port isn't forwarded on the router.

Is the getsockopt error caused by my mods or my Minecraft version?

No. Wrong mods or versions give other messages, such as "Outdated client" or a mod mismatch screen, because they're only detected after a connection is made. getsockopt means the connection never got that far.

Why can I join my own server but my friends get getsockopt?

You connect through localhost inside your own network; your friends have to come in from the internet. Forward TCP 25565 on your router, allow Java in Windows Firewall, give them your public IP, and check that your provider doesn't use CGNAT.

Can I fix getsockopt by reinstalling Minecraft or Java?

Rarely. Reinstalling doesn't change the server, the address or your network, which cause almost every case. Only reset Java's firewall permissions if you previously blocked it.

Does "no further information" mean something different?

No. "Connection refused: no further information" is the same error as "Connection refused: getsockopt" – only the end of the message differs between systems.

Other guides