May 12, 2021
How To Make a Minecraft Server – Complete Guide.
This guide takes you through the steps of setting up your own server with the default server software that Mojang Studios distributes for free. The software can be used on most operating systems, including Windows, macOS, GNU/Linux and BSD.
How to Make a Minecraft Server.
To create your own Minecraft server, you will need to go through the following steps:
- Step 1: Get Minecraft Java Edition.
- Step 2: Get the Latest Version of Java.
- Step 3: Download the Minecraft Server.
- Step 4: Commands to Run the Server.
- Step 5: Setting up Server Properties.
- Step 6: Port Forward to Play Globally (Optional)
- Step 7: Connecting to your Minecraft Server.
We will go through every step in details, below.
Setting up a Minecraft server takes some time, and technical knowledge. Read this guide on how to set up a server.
A Minecraft server does not need to be a high-end machine, but netbooks and notebooks are not for good server machines. They typically have lower-end hardware and bad I/O performance.
Watch this Video on How to Make a Minecraft Server.
If you prefer a visual step-by-step-guide, then watch this video.
How to Make a Minecraft Server – Complete Step-By-Step Guide.
When playing Minecraft, one of the more technical things you may need to do is set up your own server. Fortunately, however, Mojang Studios makes things easier by providing its own free server software, and this is compatible with Microsoft Windows, Linux, MacOS and various other operating systems.
Generally speaking, a computer does not need to be top-of-the-range to function well as a Minecraft server, although if you intend to play on the same computer you are using as the you are going to require some additional power. A certain level of technical expertise may be required, and public servers are available for those who wish to play without hosting.
For those who do want to make their own Minecraft server, however, this guide will walk you through the basic steps.
How to Create a Minecraft Server.
To set up your own Minecraft server, you are going to need to work through seven basic steps, which are as follows:
Step 1: Make Sure You Have Minecraft Java Edition
Step 2: Upgrade to the Latest Java Version
Step 3: Download the JAR Minecraft Sever File
Step 4: Create a Batch File to Launch the Server
Step 5: Select Your Server Properties
Step 6: Create a Port Forward Entry
Step 7: Connect to Your Minecraft Server
Step 1: Make Sure You Have Minecraft Java Edition.
The first step in the process of how to make a Minecraft server is to make sure you have the correct version of the game. It is important to state that the option to run your own server is only compatible with Minecraft Java Edition. Therefore, if you have a different version of the game, you will not be able to make use of this option.
You can download Minecraft Java Edition here:
The game is compatible with Microsoft Windows 7 and above, as well as the Linux or MacOS operating systems. Your computer will require a minimum of 4GB RAM, although 8GB RAM is recommended, especially if you will be playing on the same computer you are using as a server. For MacOS you will require OS X using 10.9 Maverick or newer.
Step 2: Upgrade to the Latest Java Version.
Next, you need to make sure you have the most up-to-date version of Java. To do this:
1. Visit the Java download page at: https://www.java.com/en/download/
Do not download the file from elsewhere, as you need to know that the file is trustworthy.
2. Scroll through the available options and find the version of Java that is relevant to you. This will depend on the operating system you are using. Once you have found the version that is applicable to your computer, click on the link to start the download process. You may need to read and accept the terms and conditions.
3. The executable file for the latest version of Java should then download to your default download folder. Once the download has finished, find the file on your computer and run the executable file. You may need to re-enter your password and you may also need to provide permission for the application to make changes to your computer.
4. Once you have launched the executable file, follow the instructions provided on-screen to install Java. If you are asked, you can feel free to remove the older version installed on your computer.
5. Work through the installation process fully, until you have updated Java to the latest version.
Step 3: Download the JAR Minecraft Server File.
Once you have updated Java, you need to download the Java Archive or JAR file for the Minecraft server.
1. Visit the server download page at: https://www.minecraft.net/en-us/download/server
2. On the page, you should see a link labelled ‘Download minecraft_server.jar’. Please note that the exact name of the file will depend on the latest version of the server file. Do not download the server file from another page, as you need to know that you have downloaded it from a trustworthy source due to the permissions it will require.
3. If you see a notification warning you that the file may harm your computer, disregard it and click the option that allows you to continue with the download. This is a warning intended for files that have been downloaded from untrusted sources, but the official Minecraft server file is 100 percent trustworthy and authentic.
4. Create a new folder on your computer. Some people opt to use their desktop for this, but you can create the folder anywhere on your computer. The easier it is to access, the better. Give the folder a name of your choosing.
5. Move the downloaded JAR file to the new folder you have created. The file will have downloaded to the default folder for file downloads from your web browser. You can move it by either copying or cutting the file and then pasting it.
6. Open the new folder you made, which should now also include the JAR server file. Double click on the file to run it. In doing so, a number of new files will be created within your new folder. These files are important and will need to be kept there for the server to run properly, so do not delete or move them.
7. Open the new file entitled eula.txt and look for the line which reads “eula=false”. Edit this so that it instead reads “eula=true”. Do not change anything else within the text file. Once you have made the change, click ‘File’, then ‘Save’ to save the new setting. This process means you have accepted the EULA agreement, which is mandatory.
8. Close the text file, and run the JAR file once more. This should then result in even more files being added to the new folder on your computer. Once this is complete, a new server window should also appear, indicating that the process is complete and your Minecraft server has been launched.
At this stage, computers on the same network as you should be able to join the server by running Minecraft and finding the server on the multiplayer tab within the game. However, more steps are required to optimise the server and to allow other players from beyond your network to join, so it is important to keep following this guide.
Step 4: Create a Batch File to Launch the Server.
The next stage of the process involves creating a batch file, which can be used to launch the server, while also helping to optimise performance. The batch file needs to be made manually and needs to be contained in the same folder as the rest of the server files, which is the new folder you created during Step 3.
1. Open the folder with your server files and right-click, then go to ‘New’ and select ‘Text Document’. Depending on the operating system you are using, the exact name for this on the menu may vary. It should result in the default application for creating basic text files opening, which is Notepad on Windows.
2. Enter the following text within the document:
java -Xms1024M -Xmx1024M -jar minecraft_server.jar
This code works by allocating 1GB RAM to help run the server (hence the 1024M, which refers to 1,024MB – or 1GB). It should be noted that the end of the first line assumes your main sever file is named minecraft_server.jar. If this is not the case, you need to replace the “minecraft_server.jar” with whatever your JAR file has been saved as.
3. With the text inserted into the text document, go to ‘File’, then select ‘Save As’. Make sure it is going to be saving the file to the same folder you have been using for the other server files. Move down to the section where it says ‘Save as Type’ and lists the file type as ‘Text Document’ and use the drop down menu to select ‘All Files’ instead. Enter your chosen name for the batch file and then enter .bat at the end, then click ‘Save’.
4. An optional step here is to close the text file and then go to the server folder you have been using. Find both the original text document you created, as well as the .bat file. You can delete the text document, but make sure you do not delete the file that has the .bat suffix.
Once you have completed these steps, double check that the batch file works by opening it. If it has been set up properly, it should launch your Minecraft server. If this does not happen, double check the code you used for typing errors. You should also make sure the JAR file name matches the name used within the code.
Step 5: Select Your Server Properties.
After creating your batch file, there are some additional steps that can be undertaken, in order to set the server properties how you want them. The way to do this is to edit the server properties file within your folder. This can be done by opening the server.properties file in your default text editor, such as Notepad.
1. Take a look at the code and think about the sort of game you want to play on your server.
2. The line that says “gamemode=survival” by default describes the game type you want to play. The default setting, survival, means that health is a factor and the player character can die. The alternatives here are to change this code to “gamemode=creative”, which will mean the game is in creative mode, with no player death, or “gamemode=adventure”, which will mean the game is in adventure mode, which is intended for player created maps.
3. The line that says “difficulty=easy” by default controls the difficulty setting, as well as things like the damage caused by enemies and the extent of hunger effects. The available options are “difficulty=easy”, “difficulty=normal” and “difficulty=hard”, which are all self-explanatory, or “difficulty=peaceful”, where no enemies will spawn at all.
4. The line that says “spawn-monsters=true” determines whether or not enemies spawn in the game. This applies regardless of other settings and whether you have opted for survival, creative or adventure mode. Replacing the word “true” with “false” – so that the line reads “spawn-monsters=false” – will prevent any enemies from appearing.
5. The line that says “pvp=true” controls the player vs. player settings within the game. By default, this is set to “true”, meaning players are able to cause damage to other players within the game. By changing this setting to “pvp=false”, you can disable the ability for players to harm each other while on your server.
6. The line that says “max-players=20” can be altered to change the setting for the maximum number of players that are able to join the server at any one time. The higher this number is, the more resources your computer will require to handle running as the server. Some experimentation may be required to find the ideal number.
7. The line that says “enable-command-block=false” by default can be changed to “enable-command-block=true”, which will enable the use of command blocks within the game. Command blocks allow for console commands to be entered.
8. The line that says “level-name=world” by default controls the world that will be played in via your server. The default setting will result in a random world being created. However, if you download world files, you can add them to your server folder and use these by changing this setting to “level-name=” and then the name of your preferred world. The name you enter here must match the file name exactly, so take care when entering it.
Step 6: Create a Port Forward Entry.
Assuming you want players to be able to join your server from beyond your local network, you are going to need to create a port forward entry. However, if you are happy to restrict your server to your local network only, you can skip this step entirely, as it will not be relevant to you and will create unnecessary work.
1. Check the name of the router you are using for your network. For example, your router might be a BT Home Hub 5, or a Verizon Jetpack MiFi 6620L. Try to be as specific as you can, as this will be important for the next step.
2. Navigate to your router’s administration page, if you know how to do so. If you are unsure, however, you can instead visit the following page: https://portforward.com/router.htm. On that page, you should see a list of routers. Find your router and click on the link provided. You will then be able to access step-by-step instructions for accessing your administration page and the port forwarding section.
3. Follow the instructions and log in.
4. Go to the port forwarding section, as explained on the aforementioned website, and create a new port forwarding entry. You can name it whatever you like, but this should be immediately obvious to you in future as your port forwarding entry for Minecraft. The port number needs to be set to 25565 for both TCP and UDP.
5. Make sure you save any settings and then you can leave the router administration panel.
Step 7: Connect to Your Minecraft Server.
The final step involves actually connecting to your Minecraft server.
1. Open the batch file you made in Step 4 of this guide. This should then launch the server. If this does not happen, you need to double check the batch file to make sure you entered the code properly, so go back to Step 4.
2. Find your public IP address. You can do so by visiting the following website: https://whatismyipaddress.com/.
3. Load the latest version of Minecraft Java Edition. This should match the JAR file you downloaded in terms of version number, so double check that this is the case.
4. Within the game, go to the ‘Installations’ tab and then click ‘New’. This will take you to the ‘Create New Installation’ page, where you need to provide a name for the installation, select the right version number and provide the game directory. This should go to the correct directory by default, but you can change it if necessary. You can also make alterations to the screen resolution from this page, should you need to.
5. Click the ‘Create’ button at the bottom of the screen.
6. Go back to the ‘Installations’ tab and find the installation you just created. Click on the ‘Play’ button next to it. This should then start Minecraft Java Edition properly and once the game has loaded, you need to go to the ‘Multiplayer’ section, then click on the ‘Add Server’ option.
7. You should now see a page titled ‘Edit Server Info’. On this page, provide a server name and then in the ‘Server Address’ box, you need to enter the public IP address you found earlier, followed by a colon and then the number ‘25565’, which is the same number you used in the port forwarding step.
So, to provide an example, your entry should resemble the following: 11.222.333.4444:25565.
However, the numbers prior to the :25565 must match your public IP address exactly.
8. Click on the ‘Done’ button at the bottom of the page.
Assuming all of the steps were followed properly, you should achieve a successful connection. If you do encounter problems, the most common issue is likely to be incorrect entry of one of the settings, such as your IP address. Simply work back through the steps, paying extra attention to any possible errors you may have made.
Should you encounter performance issues, you can either allocate more RAM by revisiting Step 4.2 of this guide, or you can adjust the maximum number of players that can connect to the server by revisiting Step 5.6.
How to Host a Minecraft server for Free with Minehut.
Note: This is a separate guide on how to create a free Minecraft server with Minehut.com.
There is another, much simpler way to make a Minecraft server for free, for you and your friends. This works for MAC and PC for the Java Version, and the method sets up a server for a maximum of 10 players.
For our full guide on Minehut, please see your page “How to set up free Minecraft Server Hosting with Minehut“.
Minehut is one of the few hosting services that allows you to host a Minecraft server for free.