How to Open Ports on Your Router for Your Server (Minecraft, Hytale, and more)
You've set up the server, installed Java, and everything works perfectly on your computer. But when your friend tries to connect, the "Connection Refused" error appears. The culprit? Your router's Firewall.
In this guide, we will explain how Port Forwarding works and what terms you should look for in your router's panel to grant access to your server.
1. The Concept: What is Port Forwarding?
Imagine your router as a building's doorman. When someone from outside sends a connection to your IP, the router doesn't know which computer in the house to send that information to. Port forwarding tells the router: "Everything that arrives on port 25565 should be sent to John's PC".
2. First Step: Find Your Local IP
The router needs to know your computer's internal address (Local IP) where it should send the data. To find this on Windows:
- Press Windows + R, type
cmd, and press Enter. - On the black screen, type the command:
ipconfig - Look for IPv4 Address (usually something like
192.168.1.15or10.0.0.5). Note this number. - Also, note the Default Gateway. This is your router's address that you will use in your browser.
3. Accessing the Router
Open your browser (Chrome, Edge, etc.) and type the Default Gateway number in the address bar. You will need the device's username and password (often printed on a label on the back of the router).
4. Common Terms to Look for in the Menu
Since each manufacturer (TP-Link, ASUS, Intelbras, D-Link) uses a different name, look for one of these tabs:
- Port Forwarding
- Virtual Server
- NAT / Gaming
- Advanced Setup > Port Triggering
5. Configuring the Rule
When you find the menu, you will see a form. Fill it out with your game's data:
| Field | What to put |
|---|---|
| Name/Service | Minecraft (or game name) |
| Start/End Port | 25565 (for Minecraft) |
| Protocol | TCP/UDP (or "Both") |
| Local IP Address | The IPv4 you noted in Step 2 |
6. What is DMZ? (Use with care)
Many routers have an option called DMZ (Demilitarized Zone). If you activate DMZ for your Local IP, the router will open all ports for your PC. It's a quick way to test if the issue is a port, but we do not recommend leaving it active for security reasons, as your computer will be fully exposed to the internet.
Final Tip: Public IP vs. Local IP
Remember: Your friends must use your Public IP to connect, not your Local IP (192.168...). To find your external IP, just search Google for "What is my IP".
Boreaz Tip: If your IP changes every time the router restarts, you can set up a Free Static IP. See our complete guide on how to use DuckDNS.