Home/Minecraft guides/How to make a Minecraft server

How to make a Minecraft server

Everything you need to get a Minecraft Java server running, either on your own computer or on a host, and the settings worth changing before your friends join.

Short version
  • Pick your server software: Paper for plugins, Fabric or Forge for mods, Vanilla for pure Minecraft.
  • Give it enough RAM: 2–4 GB for a few friends, more for big groups or modpacks.
  • At home you need the right Java version, eula=true and port 25565 forwarded on your router. On a host, all of that is done for you.
  • Turn on the whitelist, set a sensible view distance, then share the address.

1. Decide where it will run

You have two real options. Both run the same server software; the difference is who keeps the machine online.

Your own PCA hosting provider
CostFree (plus electricity)Monthly fee
Online when you're notOnly if your PC stays onYes, 24/7
Port forwardingNeeded, and some ISPs block itNot needed
Your home IPShared with every playerStays private
PerformanceShares your PC with your gameDedicated resources

Hosting at home is great for trying things out with one or two friends while you're playing anyway. If people want to log in while you're asleep, or more than a handful of players join, a host is less hassle.

2. Pick your server software

This is the choice that matters most, because plugins and mods only work on the software they were made for.

  • Paper is a faster drop-in replacement for Vanilla that runs Bukkit and Spigot plugins (EssentialsX, LuckPerms, WorldEdit, CoreProtect…). Players join with a normal, unmodded client. Most SMPs should start here.
  • Fabric loads mods. It's lightweight, updates to new Minecraft versions quickly and has excellent performance mods. Players usually need the same mods installed.
  • Forge also loads mods and is behind many large, content-heavy modpacks.
  • Vanilla is Mojang's own server with nothing added.

Our Paper vs Fabric vs Forge comparison goes deeper. If your friends play on phones or consoles, you need a Bedrock server instead.

3a. Running it on your own computer

  1. Install the right Java. Minecraft 1.20.5 and newer need Java 21 or later; 1.18 to 1.20.4 need Java 17; 1.12 to 1.16 run on Java 8. Install a 64-bit build such as Eclipse Temurin. If the server stops with UnsupportedClassVersionError, your Java is too old for that Minecraft version.
  2. Download the server jar into an empty folder: Vanilla from minecraft.net, Paper from papermc.io, Fabric's server launcher from fabricmc.net, or the Forge installer from minecraftforge.net (run it with --installServer).
  3. Create a start script so you can set the memory. On Windows make start.bat, on macOS or Linux start.sh:
    java -Xms4G -Xmx4G -jar server.jar nogui
    Our startup command generator writes a tuned version for you, including Aikar's flags.
  4. Run it once. It creates eula.txt and stops. Open it, read Mojang's EULA, change eula=false to eula=true, and run the script again. When you see Done (…)! For help, type "help", it's up.
  5. Join from the same PC using the address localhost.
  6. Let friends in. In your router, forward TCP port 25565 to your PC's local IP and allow Java through your firewall. Friends connect to your public IP. If your ISP uses CGNAT, port forwarding won't work and you'll need a host or a tunnelling service.

3b. Running it on a host

A host does steps 1, 2, 4 and 6 for you. On NS5 it looks like this:

  1. Open the order page, choose Minecraft: Java Edition and pick Paper, Purpur, Fabric, Forge or Vanilla.
  2. Choose a size. 4 GB is a good default for friends; our RAM calculator helps if you're unsure.
  3. Pay, or start the free trial. The server installs itself in about a minute with the EULA already accepted.
  4. Copy the address shown at the top of your server page and share it.

You can change the Minecraft version in the Startup tab and switch between Paper, Fabric, Forge and Vanilla in Settings later.

4. Settings to change before people join

These live in server.properties (on NS5, the Server Settings tab gives you a form with a live MOTD preview). Restart after changing them.

SettingWhat to set
white-listtrue for private servers, then /whitelist add Name for each friend.
online-modeKeep true. Turning it off lets anyone join as any name.
difficultynormal or hard for survival.
view-distance8–10. Higher looks nicer but costs a lot of RAM and CPU.
simulation-distance6–8. How far away farms and mobs keep running.
max-playersWhatever your RAM can handle; it doesn't reserve anything.
motdThe line shown in the server list.
spawn-protection0 if you don't want a protected area around spawn.

The server.properties generator explains every common setting and writes the file for you.

5. Make yourself an operator

From the server console (not in game), run op YourName. Operators can use commands like /gamemode, /whitelist and /ban. Only op people you trust completely.

6. What to do next

  • Set up automatic backups before anyone builds anything important.
  • Add a few plugins such as CoreProtect (rollback griefing) and LuckPerms (permissions).
  • Pre-generate the world with Chunky so exploring doesn't cause lag. See fixing server lag.
  • Running a survival community? Follow our SMP setup guide.

Common questions

Is it free to make a Minecraft server?

Yes, the server software is free and you can run it on your own computer. You only pay if you rent a server from a host so it stays online without your PC.

Do my friends need to own Minecraft?

Yes. With online-mode on, which you should keep, every player needs a paid Minecraft Java account. Java players can't join a Bedrock server or the other way round without extra software.

Why can't my friends connect to my home server?

Usually the port isn't forwarded, the firewall is blocking Java, or your ISP uses CGNAT so your router has no public IP. Check that port 25565 TCP is forwarded to the right local IP, or use a host instead.

Which Minecraft version should my server run?

The latest release for Vanilla and Paper. For modded servers, use the version your mods or modpack support, since mods often lag behind new releases.

Run it on NS5 instead

Minecraft Java servers from $3.70/month on AMD EPYC with dedicated RAM. One-click Paper, Fabric, Forge and Modrinth modpacks, backups and SFTP included. Try one free for 48 hours, no card needed.