Direct answer
For a first Minecraft Java server, create a dedicated folder, choose the server software, install the Java version that software requires, place the server JAR in the folder, run it once, accept the EULA, then start it again. Test locally before touching port forwarding.
- Create an empty server folder.
- Choose Vanilla, Paper, or a mod loader.
- Install the required 64-bit Java version.
- Put the server JAR in the folder and give it a simple name such as
paper.jar. - Run the JAR once so the server creates its files.
- Read
eula.txtand seteula=trueonly if you agree. - Start the server again and wait for
Donein the console. - Join with
localhostfrom the same computer, then configure whitelist, backups, and networking.
Choose the server software first
The software determines what you can add later. Use the official Vanilla server when you want Mojang's server behavior with no Bukkit/Paper plugins. Use Paper when you want the Bukkit/Paper plugin ecosystem. Use Fabric, NeoForge, or Forge when the server is built around mods or a modpack.
Install Java and run the server
Current Paper versions use different Java versions depending on the Minecraft line. Paper documents Java 21 for Paper 1.20 through 1.21.11, and Java 25 for Paper 26.1 and newer. Check your exact software version instead of assuming an old tutorial is still correct.
java -versionAfter putting the JAR in the server folder, a simple Paper start command looks like this:
java -Xms2G -Xmx4G -jar paper.jar --nogui-Xmx4G sets the maximum Java heap to 4 GB. Do not allocate all system memory to Minecraft.
First-run setup
The first launch normally creates files such as eula.txt and server.properties. The process may stop until you accept the EULA. After you set eula=true, run the same start command again.
When startup succeeds, the console will eventually report that startup is complete. Use stop in the server console when you want to shut it down; do not normally close the window or kill Java while the server is writing world data.
Test locally before opening the network
From Minecraft Java Edition on the same computer, add a multiplayer server with the address localhost. If another device is on the same home network, use the server computer's LAN address, often something like 192.168.x.x.
If local connections do not work, fix the server first. Port forwarding cannot fix a server that is not listening locally.
Before inviting friends
- Enable the whitelist for a private server.
- Make only trusted administrators operators.
- Create a backup before major updates or plugin changes.
- Leave
server-ip=blank unless you specifically need to bind the server to one local interface. - If friends will connect over the internet, configure the firewall and router only after local testing succeeds.
Official references
These references were checked while preparing this guide. Version-specific behavior can change, so use the project documentation for your exact release when a detail differs.
Related guides
Help us improve this article
Tell us what is missing, unclear, outdated, or incorrect. You can also suggest something we should add.