How to Set Up Your Own Minecraft: Java Edition Server

Abhimannu Das
Updated On: 
<div class="paragraphs"><p>How to Set Up Your Own Minecraft: Java Edition Server</p></div>
How to Set Up Your Own Minecraft: Java Edition Server

Cover-Credits: 

Highlights
Setting up your own server in Minecraft can help you customize your gameplay experience for yourself and others who join your server.
Setting the server up for the first time can be very tricky so make sure you follow the steps correctly.
You can get a Realm subscription as well which can be more expensive but is a hassle-free experience for setting up a Minecraft server.

Minecraft: Java Edition allows you to set up your own server via Realms or you can even host your own server. If you are looking to use Realms to automate the process, check out our guide on how to create a Realm in Minecraft. But if you want to host your own server, here is a quick guide to help you get started.

How to set up a server in Minecraft: Java Edition

Before we get started, make sure you have Minecraft: Java Edition installed. Here’s how you prepare your Minecraft server folder:

  1. Go to the Minecraft Servers website and download the minecraft_server.1.XX.X.jar file (The Xs denote the current version of the game) 

  2. After you have downloaded it, make a folder on your desktop to keep all your server files in. You can name it “Minecraft Server”. 

  3. Drag over or copy and paste the .jar file into the Minecraft Server folder. 

  4. While you have the file browser open, open command prompt from the start menu.  

  5. You can check if Java is installed in command prompt by typing without quotes “java -version”. 

  6. To start the server, you will need to change the directory to the location where you have the Minecraft Server folder and the .jar file located. 

  7. You can find the directory in Windows by simply clicking on the browser directory in file browser.

Minecraft Server Folder

How to configure your Minecraft server

How to configure your Minecraft server
  1. Type without quotes “cd” hit space and then paste the address you just copied, then hit enter. This should look like “cd Z:\Minecraft Server” 

  2. Type the following into your command prompt manually without quotation marks after inputting the directory. 

    • Java -jar “name of your jar”.jar 

  3. Hit enter and after running the command, you will notice a failed to load properties error along with failed to load eula.txt. Ignore this for now.

  4. Back in the Minecraft Server folder open the “eula.txt’ file that has been created with your text editor. Here you will need to set the eula=false to eula=true and save. 

  5. You will also see a “server.properties” file. If it does not appear like an editable text file, right-click it and click “Open with” and choose Notepad.

  6. Take note of the query.port setting as this is the port you will need to forward on your local router to allow other inbound connections.  

  7. The gamemode setting will allow you to set if you would like to play survival or creative. Specify what you would like by typing after the “=”. 

  8. Spawn-protection specifies the radius of blocks in the server spawn that cannot be broken. You can change this to 0 if you would like them to be broken. 

  9. The allow-nether specifies if you would like the Nether on your server. 

  10. Difficulty can set the difficulty of the server. This can be either peaceful, easy, normal, or hard. 

  11. The pvp setting specifies if you want to allow players the ability to hurt each other. 

  12. The max-players specifies the maximum amount of people who can join your server. You may want to adjust this to how much RAM you have dedicated to your server. 

  13. The level-seed allows you to insert a seed for a world to generate from if you have one. 

  14. Motd sets the message in the Minecraft server browser that other players will see once they have added your IP to their list. 

Now you just have to rerun the launch command in the command prompt and the server should be running. Repeat steps 1 and 2 again to start your server.

Making sure you are in the Minecraft Server file directory and enter java -jar “your jar name”.jar into command prompt.

You will also need to forward the port listed in server.properties query.port. The default it is 25565 so in your router settings you will need to specify that port to forward. This process will vary from different router manufacturers. If you need assistance in forwarding a port, please refer to your router’s help site/manual. 

By default, if you did not specify anything in the server-ip setting, the server will point to your public IP, this is what other players will need to connect to your server and play with you. 

What's My IP

You can find your public IP by searching “What’s My IP” on Google. Do NOT share your public IP with strangers and give it to your friends and trusted individuals only. When a player wants to connect to your server, they will enter your public IP address followed by:25565 into the IP field of the server menu. The full address should look something like this: 12.34.56.78:25565 

If you are the host, you can either connect to it by typing the public IP or by simply typing ‘localhost’ if your server is running on the computer you play Minecraft on. 


Published On: 
author profile picture
Abhimannu is a PC esports writer at AFK Gaming. With over seven years of experience in esports journalism, he has worked on a myriad of games and their ecosystems including Valorant, Overwatch and Apex Legends.