make-a-minecraft-server

How to make a Minecraft server: A complete guide to setup a Minecraft server

Are you looking to set up a Minecraft Server? – Then this is how to make a Minecraft Server on Windows, Mac, or Linux host: a complete guide was written by SeekaHost Gaming servers experts.

Setting-up-Minecraft-servers

While the tech nerds and gaming fans are already acquainted with Minecraft as a highly interactive game the importance and scope of Minecraft extend beyond just that. It wouldn’t be an exaggeration to call it a launchpad for the nontechnical people and children who want to learn to code the fun way.

As a perfect meeting platform for coding enthusiasts, experts, and dilettante, Minecraft takes the craft of gaming to the next level by having an extended control over the functioning and interface of the game. For the best experience, many game lovers would like to run their private Minecraft server. Our UK Minecraft server hosting services very popular among the people who want to play Minecraft online with friends

Having your private server allows you to build your own personalized Minecraft world.

Setting up a Minecraft server

In this guide, we would mention to you a step by step procedure to create a Minecraft server.

  1. How to setup Minecraft Server on a Local PC (Windows)?
  2. How to set up Minecraft Server on a Local PC (Mac)?
  3. How to setup Minecraft Server on Linux (Ubuntu)?
  4. How to set up Minecraft Server on Linux (CentOs)?

How to share your Minecraft server with external users?

How to setup Minecraft Server in a Local PC (Windows)?

Step 1 – Download and install Java 

Go to https://www.java.com/en/download/ and download Java

Step 2 – Install Java

Double click the downloaded file and follow the screen to install 

Step 3 – Download the Minecraft Game 

Go to https://www.minecraft.net/en-us/download/server/ and download minecraft_server.x.x.x.jar file (x is any number)

Step 4 – Create a Game folder

Create a new folder under D driver or any folder for the game file.  

D:\Minecraft\ 

Copy and paste the downloaded file “server.jar” to the created folder.

Step 5 – Run the game

Start the server by double-clicking the .jar file which will generate configuration files. Make necessary modifications before the server gets ready for use

Setup-Minecraft-server

Open eula.txt file and replace eula=false with eula=true which is mandatory to start the Minecraft server.

You might encounter an error alerting that the server properties can’t be saved. In that instance, right-click .jar file Run as an administrator that will enable you to run the Minecraft server as an administrator.

Step 6 – Play the game and Enjoy 

Run the Game and go to multiplayer mode.

Add Server 

Install/Update your Java Version

Installation 

  • The user who hasn’t yet installed the Java or is using the outdated version can download it from the website https://java.com/en/download

Updating (If you already have Java installed on your computer)

  • Open Programs tab in your Windows Control Panel and search Java. Click Update Now
  • Open Command Prompt and get the Java version number by typing Java-version.

Note: After installation, you would need to restart the computer

Choose an appropriate location for Minecraft server files

Minecraft-server-setup-guide

Download Minecraft Server Version by visiting (https://minecraft.net/en-us/download/server

  • Before downloading, set the system location from which the server should run
  • The server would produce prerequisite configuration files during the first instance. They all are vitally important and should be collectively stored in a separate folder to ensure quick access.
  •  For the sake of access, you might assign a shortcut key to the folder and save it on your desktop. It is not mandatory though. You can save it at any location of your choice.

Downloading /starting the Minecraft server software

  • Go to the Minecraft website and download the Java.jar file which is the server software. It should be stored in the same location where you saved the installation files.
  • Start the server by double-clicking the .jar file which will generate configuration files. Make necessary modifications before the server gets ready for use
  • Open eula.txt file and replace eula=false with eula=true which is mandatory to start the Minecraft server.
  • You might encounter an error alerting that the server properties can’t be saved. In that instance, right-click .jar file Run as an administrator that will enable you to run the Minecraft server as an administrator.

Enable port forwarding

Go to the file named Server Properties. Make the required changes in key server settings (memory, game settings, server port, etc.) and then save it. Its default server port is Port 25565

  • Learn port forwarding configuration processes by referring to your router’s documents. Remember, forward TCP port 25565 for Minecraft.
  • In the Output IP/Server IP for the forwarded port provide the local IP address of your server that can be looked up by entering ipconfig in command prompt.

Start the Minecraft server

Open windows command prompt to start the Minecraft server.

  • Go to the folder that is containing the Minecraft server file and give the following command

Java -Xmx1024M -Xms1024M -jar {Your server file name} nogui 

Omit nogui parameter if you prefer to use server’s UI

java -Xmx1024M -Xms1024M -jar {Your server file name}

  • Batching multiple commands in one place makes things easier for you. For that, you can create a .bat file.
  • After the server starts working, you can enable people to connect to it using your local IP address. For that, they need to be on your home network. Those outside your home network can be invited to our server through your external or public IP address
  • Check it on Google by entering my IP address.
  • Go to the Minecraft server status checker and provide your public IP address to see if the server is accessible. 

How to set up Minecraft Server on a Local PC (Mac)? 

  • For setting up your Minecraft server you would require to download essential files that you can get from Minecraft:
  • Open https://minecraft.net/en/download/server in Safari and download the JAR file
  • Copy the JAR file you just downloaded and paste it into a new folder.
  • Give a relevant name to the file like “minecraft_server.jar.” To easily run the server commands you can remove the versions numbers.
  • Open Applications folder from your Go menu and start TextEdit application.
  • Select Plain Text from Format Menu for opening the plain text document.
  • In the text file that opens, copy-paste the following commands for starting the server.

#!/bin/bash

cd “$(dirname “$0″)”

exec java -Xms1G -Xmx1G -jar minecraft_server.jar

Note: -Xms1G -Xmx1G denotes the RAM (i.e. GB RAM) you can increase it by replacing 1 with 2 while rest will remain the same. 

  • Open the TextEdit menu and select Save. This file can be saved in the same folder where you saved the JAR file. Name it .start.command.
  • Open the Go menu and click the utility folder. Now open the Terminal
  • In Terminal window type chmod a+x followed by a single space.
  • Place .start.command file into your Terminal window to add the path to that file following chmod a+x command.
  • Now run the command by pressing Return that will start the server by changing the start. command file’ permissions.
  • Now run .start.command file by double-clicking it which will start to display some error messages that are normal to encounter during the first instance. The server will auto-generate some files. After running for the first time the server will auto stop.
  • Open Eula.txt file from the folder and make the following change

Eula=false should be replaced with Eula=true. Close the file after saving it.

  • Now start the server back up by double-clicking the start command. It will simply start a command line and automatically download the additional file. After some time the server world will be generated.
  • In the server command line Type /op your username to gain admin control for your Minecraft account
  • You need to change the server properties. Double-click server. properties file and upon promoting select TextEdit as the program to run it. Be careful while changing the entries to the server. Post changes restart the server.
  • The game mode entry lets you choose from 0 – Survival, 1 – Creative, 2 – Adventure, 3 – Spectator.
  • You can modify level seed entry as per your preferences 

Connecting to the Server on LAN ON Mac

  • Click Apple Menu and select System presence. Now click Network and from there find IP Address and note it down.
  • In another networked computer open Minecraft. If server computer and other computers share the same local network then you don’t need to change settings provided the server computer has a high caliber to run Minecraft on it at the same time which is generally not the case
  • On the second computer select Multiplayer to scan the games.
  • Now lick direct connect button
  • In the window that displays type the local IP address of your server and connect directly for loading the same. Make sure that both computers should share the same network/?
  • You can connect several computers to your server provided that they all share the same IP address.  

How to setup Minecraft Server on Linux (Ubuntu)?

Add the new “minecraft user” to the “sudo” group.

  • Create a new user for the Minecraft server and add it to the sudo group with following

sudo usermod -aG sudo Minecraft user

  • install the wget package

sudo apt install wget

  • Install Java with these steps

sudo apt install openjdk-8-jdk -y

sudo java –version

  • Creating a new directory as a repository for Minecraft server files

sudo mkdir minecraftdir

  • For moving to the Minecraft directory

cd minecraftdir

Download Minecraft Server and create Eula File

  • You will now need to download the Minecraft server.

sudo wget -O minecraft_server.jar https://s3.amazonaws.com/Minecraft.Download/versions/1.11.2/minecraft_server.1.11.2.jar

  • Allocate required permission to make the downloaded Minecraft t server executables

sudo chmod +x minecraft_server.jar

  • Create Eula file

sudo vi eula.txt and add Eula=true to agree to the license agreement conditions

Start Minecraft server

  • Start Minecraft server with the following command

sudo java -Xmx1024M -Xms1024M -jar minecraft_server.jar nogui

Note: 1024 M refers to the allocated memory (1024MB) you can change with your preferred value)

  • Stop command will stop the currently running Minecraft server)

stop

  • For running Java command sudo java -Xmx1024M -Xms1024M -jar minecraft_server.jar nogui
  • For exiting screen window press

CTRL+A+D

  • For returning to the screen

sudo screen -r

  • Voila the Minecraft server has been successfully installed on your Ubuntu.

How to set up Minecraft Server on Linux (CentOs)? 

Prerequisite

-A dedicated server for Centos 7

-Minimum 1GB of RAM for smooth functioning

-Root access to the server

-An SSH client to facilitate server connection 

  • Use SSH to access the root user of the server
  • ssh root@serverip
  • Now install Java OpenJDK

yum install java-1.6.0-openjdk

  • Type Y when prompted for proceeding. Upon successful installation, the screen will show complete
  • Add Minecraft server as its user called mc

adduser mc

  • Give it a password

passwd mc

  • Install wget using the following

yum install wget iptables-service screen nano

Download Minecraft on Centos and create directory

  • Now download Minecraft logging as your Minecraft user and switch users with the following command:

su – mc

cd ~

  • Create Minecraft s directory with the following command

mkdir minecraft 

  • Now transfer to the Minecraft directory

cd minecraft 

  • Visit Minecraft Website and copy the latest. jar file’s URL

wget https://s3.amazonaws.com/Minecraft.Download/versions/1.11.2/minecraft_server.1.11.2.jar

  • Make the Minecraft server executable by changing the permissions as below

chmod +x minecraft_server.1.11.2.jar

 Start Minecraft in Centos

  • Run following command for starting Minecraft

java -Xmx768M -Xms768M -jar minecraft_server.1.11.2.jar nogui

Note: For computers with more or less memory just subtract the 256 MB from total available memory (in MB and modify the command accordingly)

  • Type atrla A + D to exit screen
  • Now type exit.
  • Open port 25565if you are using iptables

 iptables -I INPUT -p tcp –dport 25565 –syn -j ACCEPT

  • This command will save rules to iptables

/sbin/service iptables save

  • Now you can connect your server to Minecraft. Launch Minecraft and then select multiplayer
  • Now click add server
  • Fill in the server details and then click done
  • To start playing the game click the plays button next to your server

How to share your Minecraft server with external users?

You may like to play games with friends who are not on your local network, i.e., friends or gamers who are living in other regions. There are 2 popular and easier ways of sharing your Minecraft server with such users:

Standard Method

  • Open the command prompt and generate your IP address by typing ipconfig
  • Note down your IP address
  • Open Minecraft server and provide your IP address
  • Go back to the server
  • Open the command prompt and type ipconfig to generate your IP address.
  • To get the admin controls on your server
  • Open the Minecraft server and at the end type op followed by your username
  • It will give you extended controls like whitelisting people, banning people changing game mode, etc.

Port forwarding (change setting in router)

  • Open command prompt and type ipconfig
  • Copy the default gateway
  • Open your browser and type what’s my IP
  • It will open the search results page
  • Click on your IP address and it will take to your router page
  •  Login to the router. The default login is admin and the default password is password
  • For Port forwarding open command prompt by pressing window key and typing cmd
  • Type ipconfig
  • Copy the default gateway
  • In your folder open for the file server properties and click port forwarding
  • Go back to the Minecraft
  • In the IP address enter IPV4 address that you got in the command prompt
  • In the start port and end port fields type 25565 (your port id)
  • This is the ID that you would need to give out to the people who wish to join your network.

An easier way of sharing your server with external users

Make a Minecraft server at home

  • Download ngrok from http://www.ngrok.com. You’ll need to sign up for a free account as well and follow their setup instructions.
  • Open ngrok.com website and sign up for free. It is a tool to will make your server visible over the internet
  • Now Start your Minecraft and run following in terminal for sharing the local Minecraft server

ngrok tcp 25565 

  • You will see the following message

Forwarding tcp://ngrok.com:12345 -> localhost:25565

Note that the 12345 stands for a unique number for you to establish a connection. Note it down

It will make your server visible over the net

  • Request the friend to start Minecraft and click Multiplayer
  • Next, click Direct Connect
  • Now enter the following line

ngrok.com:12345

Where 12345 should be replaced with the unique number that you noted in the earlier step

  • That’s all. Your friend is now connected and you can play

Note: An alternative to Direct Connect is “Add Server” followed by ngrok.com:12345

It can be used for troubleshooting issues 

How to make a modded Minecraft server?

create a modded server at home

  •  Download Minecraft as mentioned in the earlier section
  •  Now Download Forge by clicking https://files.minecraftforge.net/ (Select Windows Installer)
  •  Open Forge installer again and
  •  Select Install server and specify the desired location on which it should be installed
  •  Look for the Eula.txt file. Open it and change Eula False to Eula true. Save and close the file. 
  •  Relaunch.jar
  •  A window will open named Minecraft server it confirms that local modded server has been made
  •  Look for the desired mods at https://www.curseforge.com/minecraft/mc-mods?filte…
  •  Download the .jar file of mods and make a copy. Paste all the mods to the mods folder of your server.
  •  Press the window key and search for the term- “%update%”. Now hit enter
  •  In the resultant screen click.Minecraft. Make a folder “mods” if it doesn’t already have the one. It can be used to organize all the same mod files in one place. 
  •  Right-click server model and start a new document named Server Launcher. Paste the following text to it:
  •  java -Xmx2048M -Xms2048M -jar forge-1.12.2-14.23.5.2838-universal.jar -o true nogui
  •  It allows you to optimize the desired RAM to prevent lag. The number 2048 is the total RAM (2MB) you can change it to align with your speed needs
  •  After pasting text save the copy of the as Server Launcher. bat and selecting file type as all files. Double-clicking on it will start the server. Launch the server Wait until the server is fully launched. Once it does, close it.
  • You have now created the local server which allows any user to have the same PIP. However, you would need port forwarding to your server to connect people having different IPs. 
  •  Go to Google and search what’s my IP copy-paste the number to the address bar and enter it to open the router’s website where you can make needed editing. You would need a password to proceed. Different routers have different steps for editing. Googling your specific router would help you gain the required information about the same.
  • Go to the Port range forwarding section of your router and enter following info in the relevant fields:
  •  Application Name: Minecraft server
  •  Start ~ End Port: 25565 – 25565
  • Protocol: TCP
  • Device IP: ENTER COMPUTER’S IP HERE
  • Enabled: True        
  • Computer’s IP can be got by windows key +R which will prompt a box
  • Type cmd in the box to open the command prompt
  • Type ipconfig
  • There would be a line with the label IPv4. There you need to copy your IP address. Provide that number in your device IP
  •  type cmd. When the command prompt opens up, type ipconfig. Look for the line labeled as IPv4
  •  Now launch the server by double-clicking the .bat file. Startup Minecraft. In the multiplayer menu provide your public IP and then connect to the server. You are all set to play the game

You can read more on Tutorials/Setting up a server here or contact us to help setup a Minecraft Server for you.

If you wish to play Minecraft Online Free, you can do so at our Game Server website.

Read More: Best Minecraft Survival Servers List

Author Profile

James Flarakos
I love to make Minecraft content, and easy quick tutorials for others to use. And you can see more video and tips at www.jdogofficial.com