DocsMinecraft Server Ports: How to Make Your Server Public
Ask on Discord
Minecraft Server Ports: How to Make Your Server Public illustrated for the CraftLands Minecraft docs
MINECRAFT · SETTINGS
lborg
Docs Writer
Published August 6, 2026
UPDATED 19 DAYS AGO

Minecraft Server Ports: How to Make Your Server Public

Making a Minecraft server public comes down to one forwarded port and the right address to share. This guide covers which ports Minecraft actually uses, how to forward them on your router, and what to do when forwarding just won't work on your connection.

QUICK ANSWER

To make a Minecraft server public, forward its port on your router to your PC's local IP: 25565 TCP for Java, 19132 UDP for Bedrock. Then share your public IP or hostname with friends. If it won't work at all, you may be behind CGNAT, and a tunnel or a hosted server gets around it.

Fact
Port 25565 is the Java default, so friends can join with just your IP. Move the server to another port and they have to type it after the address, like 203.0.113.5:25570.
Fact
Forwarding a port doesn't open your whole network up, it only opens that one specific port to that one specific device, everything else on your home network stays closed off.
Fact
Automated scanners look for Minecraft servers on the default port 25565, so a home server on a different port is less obvious to them.

Default Ports: 25565 TCP Java, 19132 UDP Bedrock

Minecraft Java Edition runs on port 25565 by default, and it uses TCP. Bedrock Edition is different, it uses port 19132, and it runs over UDP instead. Mixing these up is probably the most common mistake people make, so keep in mind which version you're running before you touch your router settings.

Changing the Port in server.properties

Don't want to use the default port? You can change it. Open up server.properties and look for the server-port line, then just type in whatever port number you want to use instead. Save the file and restart the server for it to take effect. Just remember, if you change it here, you'll also need to forward that new port on your router, not 25565. Our server.properties guide covers the rest of the settings in that file too.

port-properties.webp

Forwarding on a Home Router, Step by Step

Every router looks a little different, but the process is mostly the same everywhere. Log into your router's admin page, usually by typing something like 192.168.1.1 into your browser. Find the section called port forwarding, sometimes it's under NAT or virtual server instead. Add a new rule pointing your Minecraft port, 25565 for Java or 19132 for Bedrock, to your computer's local IP address. Let the server through your PC's firewall too; on Windows, allow the prompt the first time a Java server starts. Save the rule, and you're basically done. It sometimes takes a restart of the router for the rule to actually kick in.

To check it worked, keep the server running and have a friend outside your home join with your public IP.

Local IP vs Public IP vs Hostname

These three get mixed up a lot, so here's the quick version. Your local IP is the address your computer has inside your home network, usually starts with 192.168. Your public IP is the address your whole house shows to the internet, and that's what friends outside your home actually need to connect. A hostname is just a friendlier name that points to your public IP, so you don't have to remember a string of numbers, and it can update automatically if your IP changes.

CGNAT: Why Forwarding Fails for Some Connections Entirely

Sometimes port forwarding just won't work, no matter how carefully you follow the steps. That can be CGNAT, short for carrier grade NAT. Basically, your ISP is sharing one public IP across a bunch of different homes, so you don't actually have your own public IP to forward a port to in the first place.

To check, compare the WAN IP on your router's status page with the address a "what is my IP" search shows. If they differ, something upstream is sharing your address, and a WAN IP between 100.64.0.0 and 100.127.255.255, the range set aside for carrier grade NAT, means it's your ISP.

Call your ISP and ask for a real public IP, some will give you one if you ask, others won't budge at all. If yours won't, a tunnel such as playit.gg makes the server public without any forwarding: only you run its agent, and your players just connect.

Dynamic IP and Why the Address Stops Working

Most home internet connections don't have a fixed public IP. It changes now and then, sometimes when your router restarts, sometimes just randomly from your ISP's side. That's annoying because it means the IP address you gave your friends can just stop working out of nowhere. A dynamic DNS service can fix this, it gives you a hostname that keeps pointing to your current IP even after it changes.

Security Considerations When Opening a Home Port

Opening a port on your router does expose your computer a bit more to the outside internet, so it's worth taking a few basic precautions. Keep your server software updated, use a whitelist so random strangers can't just wander in, and don't forward any other ports you don't actually need open. It's not something to stress over too much, just don't leave things wide open longer than necessary.

When a Hosted Server Removes the Problem

If all this port forwarding stuff sounds like a hassle, or you're stuck behind CGNAT with no way around it, a hosted server just skips the problem entirely, because it's public from the moment it's created. No router settings, no dynamic IP worries, players connect straight to an address that always works. Check out our hosting plans and pricing if running your own hardware isn't worth the headache. And once your server's up, our guide on joining a Minecraft server walks friends through the rest.

Do I need to forward a port if I'm only playing with people in my own house?

Nope. Port forwarding is only needed for players connecting from outside your home network. Everyone on the same wifi can join using your local IP.

Can I forward the same port for both Java and Bedrock?

Not by default. Java uses 25565 TCP and Bedrock uses 19132 UDP, so you forward both. Since one is TCP and the other UDP, you can also run Bedrock on the same number as Java and forward that one port as TCP and UDP.

Will port forwarding slow down my internet?

Not on its own, no. Forwarding a port just opens a doorway for traffic, it doesn't use any extra bandwidth by itself. Your connection only slows down if the server itself is using up a lot of your upload speed.

How do I get a public IP for my Minecraft server?

You usually have one already: it's the address your router shows the internet, and a "what is my IP" search tells you what it is. Forward the server's port and give friends that address. If your ISP puts you behind CGNAT, you don't have one of your own, so ask the ISP for one or use a tunnel instead.

Rent a Minecraft Server Today

Pick a plan and your Minecraft server is online in about 30 seconds, with Paper plugins and Forge modpacks one click away in the panel. Full file access and SFTP are there when you go deeper, and free automatic backups every six hours mean a restore, not a rebuild.
VIEW MINECRAFT PLANS