Grey Triangle

Creating a Minecraft Server [Windows OR Linux]

Last updated: April 13, 2021

Jason Lawrence Minecraft Server Hosting Banner

My Twitter Account My Profile Jason Lawrence

To date I have tested 71 different providers to see who can really deliver the best Minecraft Server Hosting.

This guide will show you how to set up your own Minecraft server using a Windows or Linux dedicated server or VPS. It’s great for those who need a lot of computing power behind their Minecraft server to handle 100+ players at one time.

If you are looking for a non-technical cost-effective way of setting up your own server then I advise you to check out my list on the homepage of the top Minecraft server hosting providers.

With this method, you pay monthly for a Minecraft server that is secure, ready to go in minutes and easy to manage with a Multicraft control panel included.

Multicraft Screenshot

We will only be looking at the Java version of the multiplayer server in this guide, the traditional Minecraft game before the Bedrock release.


Before we get started I just want to warn you about the possible risks and dangers.

Danger to your file system

As you will be editing files and accessing command-line portions of your computer or a server you are going to be potentially making changes that can be catastrophic.

I myself have encountered times when I have been editing MYSQL for instance and locked myself completely out of the database by editing the wrong line.

PHPMyAdmin Screenshot

It can happen to anyone and before making any changes double-check what you are doing.

Danger from the rest of the world

As you will be potentially opening up your computer or server to the rest of the world you could be inviting the wrong sort of people in.

By unlocking ports for example you could be giving all sorts of bad people an easy back door to your systems.

If you do not understand what you are doing then in my opinion you shouldn’t be doing it.

The Basic Flow When Setting Up A Minecraft Server

For both the Windows and Linux versions, the basic flow that you need to follow is the same.

You essentially do the following list but change it up based on the operating system, which I will explain in greater detail in the following sections.

Do these steps

  1. Make sure you are running the latest version of Java
  2. Ensure sure you have the latest Minecraft server files
  3. Create the server environment and ensure the network is set up correctly so that it can communicate with the outside world
  4. Launch the server

Easy right? Let’s dive deeper into what needs to be done to accomplish this.

Setting Up A Minecraft Server On Linux

Linux LogoLinux is a free operating system that can be difficult at first to understand for those used to working with Microsoft’s Windows operating systems.

The beauty of a Linux server is that it’s cheaper to rent per month than a Windows variety, due to the lack of an operating system cost.


You will need to first connect to your Linux server by SSH, here is a guide on how to do that.

Latest Java

You need to make sure your Linux installation has the latest Java files in order to run the Minecraft server.

While SSH’ed into your machine, enter the following command to list the available latest Java versions:
apt-cache search openjdk

Now we need to update this list using the following command:
apt-get update

Then you need to update to the latest version:
apt-get install openjdk-7-jdk

You will be prompted to choose an option to download the latest version, so press Y when ready.

You can manually check to see what the latest version of Java is on your system is with the following command, do that now:
java -version

Have a folder set aside for the server and its files

Now, you need to create a directory for your Minecraft server to live on your server. Ideally, this is kept somewhere that you can remember and easily access while not interrupting other processes and programs.

To make a directory then move into that directory run the following SSH command:
mkdir MyMinecraftServer
cd MyMinecraftServer

Download the Minecraft server files and do an initial run


You should still be within the new Minecraft server folder you have created and ready to download the server files into it, which you can do using the following command:
wget -O minecraft_server.jar

Be sure to check for the URL for the latest version of the Minecraft server files before running that command, you can find that URL here.

Next up you need to install “screen” so that you can run your new server without having to be connected 24/7. Run the following command to make that happen:
yum install screen

Now while you are still within your chosen folder you need to start the server, changing the numbers to represent the limit on memory allowed:

java -Xmx512M -Xms512M -jar minecraft_server.jar nogui

Then let’s make sure everything is connected properly and test the STOP function, run the following command:


Now you need to edit a file within that server folder named “” and change the line that contains “enable-query=false” and set it to “enable-query=true“.

Now save that file and restart the server, you should be now able to connect to it using an IP address.

Setting Up A Minecraft Server On Windows

Microsoft Windows LogoIf you have a spare Windows computer kicking about or have rented a Windows-based VPS or dedicated server then here are the instructions for setting it up as a Minecraft server.


Latest Java

Java - Check for updatesCheck that this Windows machine has the latest version of Java installed.

You can usually do this by opening up your Start menu (big button in the bottom left of your screen), then browsing through Programs to find Java. Now you have found Java you need to click an option labeled something like “check for updates” or “download latest version”.

If you can’t find a reference to Java already on your machine then you can manually download the latest version from the official website:

Have a folder set aside for the server and its files

Your newly created server will need a place to live on your target machine. This is where the files will be kept and the executables will be stored.


I usually create a folder on my desktop with a descriptive name.

This location is totally up to you but ideally, it should be somewhere convenient for you and away from other programs as it will create new files as it runs that can conflict with its neighbors.

Download the Minecraft server files and do an initial run

First, download the official Minecraft server files and put them into your target folder from the previous step.

When ready, double click the .jar file to start the server. Doing this will cause the server to start downloading and creating its dependant files in the same folder it is in.

Microsoft Windows Server Desktop


If you get an error stating “Cant save server properties” then you will need to re-run the .jar file as an administrator by right-clicking and choosing that option.

Accept the EULA

You should notice a new file with the filename eula.txt, open this with a text editor, any will do.

You need to change the line that says eula=false to eula=true to show that you agree to the Minecraft Server End User Licence Agreement.

If you do not do this then your server will not work.

Enable port forwarding on your router

OK, this is where it can get difficult and also risky, you are opening your machine to the rest of the world.

If you are hosting a local network server with no need to connect to the outside world then you do not need to complete this step.

Router Management Screen

Refer to your router’s manual to find out how to complete port forwarding for that model. You can find tutorials and tools to test on the website

For a Minecraft server, you will need to open the TCP port 25565.

Start your server so it’s ready to use for real

You now need to launch your server from the Windows Command Prompt command-line interface. You can find it by searching in the Start menu for “command prompt“.

Collect the file location of your new servers .jar file, it should be something like C:\Users\Jason\Desktop\MyMinecraftServerFolder\minecraft_server.1.15.1.jar.

Now using that opened Command Prompt you need to enter the following command, changing the {server_location} string for the file location referenced above.

java -Xmx1024M -Xms1024M -jar {server_location} nogui

If you would like to view a user interface for the server within your desktop then remove the “nogui” string from that command.

If all is well then you should be informed that your server is running, you can now invite people to it.

To find your external IP address in order for people to find you, try searching Google for “what’s my IP address”.


Thanks to these guys for the references I used while putting together this guide on creating a Minecraft server in Windows or Linux.

My Hosting Review Process:

1. Find 71 popular Minecraft Server Hosting providers

2. Buy a basic package and set it up

3. Run speed tests on server

4. Compare the features vs. cost

See top 10 hosts

Sidebar Banner

My Choices For Minecraft Hosting

Host Havoc

Best "All Round" Host

View Host Havoc

Best All Round Host 2021


Best "Budget" Host


Best Budget Host 2021

Best Established Host


Best Established Host 2021