How to Host a Minecraft Server: With a Panel or by Hand

Short answer: To host your own Minecraft server, you need a Linux server with at least 2 GB of free RAM. The fastest way is a web panel like ServerSheriff: connect your server, pick Minecraft, accept the EULA, play. If you prefer to do everything yourself, install Java and the official server.jar by hand. This guide covers both, each on a fresh Debian 13 server.

→ Try ServerSheriff for free Free plan: 1 node, up to 5 applications, no credit card.

This guide is for Minecraft: Java Edition (PC).

Which way fits you?

With ServerSheriffBy hand
Command line needednoyes
Javaships in the container, nothing to installyou install it
Server setupdone by the paneluser, systemd and firewall are on you
EULAone click in the paneledit eula.txt
Start, stop, consolein the browservia SSH
Backupscreate, restore and schedule in the panelscript and off-site copy are on you
Paper, Spigot, modpackspick when you create the Minecraft serverdownload and set up yourself
More games and servicessame panela separate setup each

Just want to play with friends? Take path 1. Want to see what happens under the hood? Path 2.

Requirements (both paths)

  • Your own Linux server (VPS or dedicated) from any provider. For ServerSheriff it must be a freshly installed Debian 13 server. The manual path uses Debian 13 as well.
  • RAM: The Minecraft Wiki gives these guide values: 1 GB for 1 to 4 players, 2 GB for 5 to 10 players and 4 GB for 10 or more players. That is for a new world with a view distance of up to 10. Big worlds, lots of redstone, mob farms or mods need a lot more.
  • A public IP address, so your friends can connect.

The server software from Mojang is free. Your players need their own Minecraft license.

Path 1: Minecraft server with ServerSheriff

ServerSheriff is a web panel for game servers. You bring your own server, the panel sets it up, and you manage everything in the browser. ServerSheriff does not rent out servers.

Step 1: Create an account

Sign up for ServerSheriff for free. The Free plan costs nothing and needs no credit card. It includes 1 node (your server) and up to 5 applications. Game servers, databases, SFTP accounts, Docker stacks and web server domains all count as applications. That is plenty for a Minecraft server with friends.

Step 2: Connect your server as a node

A “node” is your Linux server inside the panel.

  1. Click Create node.
  2. Enter your server’s IP address, SSH port and the root password.
  3. The panel connects and installs everything it needs, including Docker. You don’t type a single command.

Use a freshly installed Debian 13 server with nothing else running on it.

ServerSheriff only needs the root password for this setup. After that, the panel logs in with its own SSH key as the user control-panel. Once the node shows as ready, you can change the root password. For more hardening, see How to secure a game server.

Step 3: Create the Minecraft server

  1. Click Create game server and pick Minecraft as the game.
  2. Choose the Game Category. Besides Vanilla, there are server types like Paper or Spigot for plugins, and ready-made modpacks as one-click installers. If you pick a modpack, select it in the Modpack field.
  3. Select the Game Version.
  4. Assign CPU, memory and disk. 2 GB RAM is fine to start, more with mods.
  5. The panel can pick the port for you (Assign port automatically).
  6. Create it. On the first start, the panel shows you the Minecraft EULA. Read it and click Accept. The Minecraft server then starts automatically.

You can watch the start live in the console. You can also send commands there, for example whitelist add <name> or op <name>.

On ServerSheriff, every game server runs in its own Docker container and not as root. The panel publishes the ports for you. If your provider has a firewall in its control panel, open the port there yourself. If your server is at home behind a router, set up port forwarding.

Step 4: Settings, backups and schedules

  • Settings: open server.properties in the panel’s file manager. The most important entries are listed in path 2 below and apply to both paths. Restart the server afterwards.
  • Backups: create and restore with one click.
  • Schedules: run restarts, backups or console commands at fixed times. A schedule can also clean up old backups.

A good start: every night, first a backup, then a restart.

Tip: turn on two-factor login in the panel. Whoever has your panel account controls your Minecraft servers.

More about Minecraft in the panel: Minecraft servers with ServerSheriff

→ Try ServerSheriff for free

Path 2: Minecraft server by hand

Minecraft server with the ServerSheriff panel

For this path you need SSH access and some command-line experience.

Important: ServerSheriff needs a fresh server. If you set up Minecraft by hand and want to switch to the panel later, reinstall the server and take your world with you (see “Bring over an existing world”).

On a fresh Debian 13 server you are usually logged in as root. Install sudo first if it is missing:

apt update
apt install sudo

Step 1: Create a separate user

Never run the Minecraft server as root. If someone exploits a bug in the server, they would get full control of your system. Create a system user without a login shell:

sudo useradd --system --create-home --home-dir /opt/minecraft --shell /usr/sbin/nologin minecraft

All server files will live in /opt/minecraft.

Step 2: Install Java

Each Minecraft version needs a specific Java version:

  • Minecraft 26.1 and newer: Java 25
  • Minecraft 1.20.5 to 1.21.x: Java 21
  • Minecraft 1.18 to 1.20.4: Java 17

The current version, 26.3, requires Java 25 according to Mojang’s official version manifest (as of October 2026). Debian 13 ships Java 25 in its official package sources. The “headless” package is enough, because the server has no graphical interface:

sudo apt install openjdk-25-jre-headless
java -version

The last command should show version 25. For Minecraft 1.20.5 to 1.21.x, install openjdk-21-jre-headless instead.

Step 3: Download the server and start it once

Download server.jar only from the official page: minecraft.net/en-us/download/server. The download link changes with every release, so copy it from there.

cd /opt/minecraft
sudo -u minecraft wget -O server.jar "<LINK-FROM-MINECRAFT.NET>"
sudo -u minecraft java -Xms1G -Xmx2G -jar server.jar --nogui

-Xmx2G is the maximum RAM the server may use. -Xms1G is the starting value. --nogui starts the server without a window.

On the first start, the Minecraft server stops right away and creates eula.txt. Read the Minecraft EULA. If you agree, change eula=false to eula=true:

sudo -u minecraft sed -i 's/eula=false/eula=true/' /opt/minecraft/eula.txt

Now start the server again with the same command. This time it generates the world. Type stop in the console to shut it down cleanly.

Step 4: The 5 settings in server.properties that matter first

/opt/minecraft/server.properties controls your Minecraft server. To get started, you only need these five:

SettingWhat it doesExample
motdText shown in the Minecraft server listmotd=Our Server
max-playersMaximum number of playersmax-players=10
difficultyGame difficultydifficulty=normal
white-listOnly approved players can joinwhite-list=true
view-distanceView distance in chunks. Costs a lot of RAM and CPUview-distance=10

Keep online-mode=true. Then the server checks that every player has a real Minecraft account. Add players to the whitelist with whitelist add <name> in the console.

Step 5: Open port 25565

Minecraft Java Edition uses TCP port 25565 by default. Debian 13 does not ship the ufw firewall by default. If you use it, allow SSH first. Otherwise you lock yourself out when you enable it. If your SSH port is not 22, use yours.

sudo apt install ufw
sudo ufw allow 22/tcp
sudo ufw allow 25565/tcp
sudo ufw enable
sudo ufw status

If your provider has its own firewall in the customer panel, open the port there as well. More on SSH, firewall and updates in How to secure a game server.

Step 6: Keep the server running with systemd

To restart the server automatically after a reboot or crash, create a systemd service. systemd is the program that starts and watches services on Debian.

Create /etc/systemd/system/minecraft.service:

[Unit]
Description=Minecraft Server
After=network-online.target
Wants=network-online.target

[Service]
User=minecraft
WorkingDirectory=/opt/minecraft
ExecStart=/usr/bin/java -Xms1G -Xmx2G -jar server.jar --nogui
Restart=on-failure
RestartSec=10
SuccessExitStatus=143

[Install]
WantedBy=multi-user.target

Then enable and start it:

sudo systemctl daemon-reload
sudo systemctl enable --now minecraft
sudo systemctl status minecraft
journalctl -u minecraft -f

The last command shows the live server log.

To stop the server, run sudo systemctl stop minecraft. systemd sends it the SIGTERM signal. The server saves the world and shuts down cleanly. Java then exits with code 143. The line SuccessExitStatus=143 tells systemd that this is not an error.

One catch: with systemd you can’t reach the Minecraft server console directly. Run commands like whitelist add in-game as an operator, or set up RCON.

Step 7: Back up your world

Your world lives in /opt/minecraft/world. The safest backup is taken while the server is stopped for a moment:

sudo systemctl stop minecraft
sudo tar -czf /root/mc-backup-$(date +%F).tar.gz -C /opt/minecraft world
sudo systemctl start minecraft

Also copy your backups to another machine or storage. A backup on the same disk does not help when that disk dies. Test a restore from time to time: unpack the backup, start the server, log in briefly.

Connect

In the game: Multiplayer → Add Server, then enter your server’s IP as the address. If the Minecraft server does not run on port 25565, add the port: your-server-ip:port. On ServerSheriff, Copy address in the panel gives you the full address with port. All steps and a checklist are in How to Join a Minecraft Server.

Bring over an existing world

  1. Stop the server.
  2. Copy the world folder (default: world) from your PC or old server. Single-player worlds live in .minecraft/saves/.
  3. Upload it:
    • ServerSheriff: with the panel’s file manager. It opens the Minecraft server folder directly, and by default the world sits there in world/. Via SFTP, the same folder is under /gameserver/gameserver-<ID>/, in your Minecraft game’s folder, at server/world/.
    • By hand: to /opt/minecraft/world, then run sudo chown -R minecraft: /opt/minecraft.
  4. If the folder is not called world, set level-name in server.properties to the folder name. Then start.

Use the same or a newer Minecraft version than the one the world last ran on. Make a copy first.

Common mistakes

Minecraft server: bring over an existing world
  • Friends can’t connect: the port is still closed in ufw, in your provider’s firewall or on your router. Check all of them.
  • UnsupportedClassVersionError on start: your Java version is too old. Install the version that matches your Minecraft version (see path 2, step 2).
  • Lag or crashes with OutOfMemoryError: not enough RAM. Assign more memory (in the panel or with -Xmx) or lower view-distance. Never set -Xmx higher than the free RAM on your server.
  • Server won’t start, log mentions the EULA: the EULA is not accepted yet. Click Accept in the panel or set eula=true in eula.txt.
  • Permission errors after copying files by hand: the files belong to root instead of minecraft. Fix: sudo chown -R minecraft: /opt/minecraft.

FAQ

Does it cost anything to host my own Minecraft server?
The server software from Mojang is free. You pay for the server or VPS it runs on. You can use ServerSheriff on the Free plan without a credit card.

How many players can my server handle?
That depends mostly on RAM, CPU and view distance. As a guide value, the Minecraft Wiki names 2 GB of RAM for 5 to 10 players at a view distance of up to 10. More players or mods need more power. Use max-players to set the limit.

Can I use plugins or mods?
Yes. For plugins, use Paper or Spigot. For mods, use a modpack. In ServerSheriff you pick this under Game Category when you create the server. By hand, you download the matching server file yourself.

Can I host it at home?
Yes. You also need a port forward on your router for your Minecraft server’s TCP port. Some internet connections don’t give you your own public IPv4 address, for example with DS-Lite or carrier-grade NAT (CGNAT). Then a port forward is not enough. In that case, ask your internet provider for a public IPv4 address, or use a rented server.

Java or Bedrock?
This guide is for Java Edition (PC). Bedrock (consoles, phones, Windows app) needs its own server software and a different port. Without extra software, the two editions can’t play together.

Can I run other games on the same server?
Yes, if there is enough RAM. In ServerSheriff, you just add more game servers on the same node, for example a Valheim server. The Free plan includes up to 5 applications.

Your Minecraft server in a few clicks

No Java install, no eula.txt, no systemd: connect your Debian server to ServerSheriff and start Minecraft in the browser. Vanilla, Paper or a modpack, with console, backups and schedules. Free for one server.

With ServerSheriff

ServerSheriff is a web panel for your own server. Connect it once, then manage game servers, databases and Docker in your browser. The Free plan costs nothing, needs no credit card and includes 1 node and up to 5 applications.

→ Try for free · Manage game servers and databases with ServerSheriff