With no introduction needed: If you want to host your own Rust server to learn plugin coding, host a server for friends, or anything else: Here’s how to do it.
Downloading Rust Dedicated Server
To setup the Rust dedicated server we need to use something called SteamCMD. A command-line based ‘copy’ of Steam. This allows us to download the game files without needing to login (Great for VPS’ and servers running on other hardware), and keep the game up-to-date.
- Download SteamCMD for Windows here.
- Create a folder for your server. I’ll call this
RustServer
. In that folder, create another calledsteamcmd
and extract the contents ofsteamcmd.zip
into there. (You should now haveRustServer/steamcmd/steamcmd.exe
). - In your
RustServer
folder, create a folder calledRust
where our actual server files will be stored. This can be called whatever you like. If you’re hosting multiple servers you can have multiple in yourRustServer
folder using the same SteamCMD installation. - Create a new text file, and rename it to
update.bat
(Make sure to replace.txt
). Open with a text editor like Notepad and paste in the following:
|
|
- Make sure to replace
<RUST FOLDER>
with the full path of your Rust folder you created in step 3, for example it should now read:+force_install_dir C:\Users\tcno\Desktop\RustServer\Rust
. - Make sure to replace
<STEAMCMD FOLDER>
with the full path of your server’s SteamCMD folder, for example it should now read:C:\Users\tcno\Desktop\RustServer\steamcmd\steamcmd.exe
. - Save and run the new
update.bat
file.
SteamCMD should update and start, then your Rust server files should be downloaded (or updated if they exist already). This should be around 9GB.
You can run steamcmd.exe
yourself and run each command seperately if you wish. This can help debug issues, or fix your server if it refuses to update. For example force_install_dir ...
, then login anonymous
, etc.
Starting your server
Similar to the update.bat
file, we can now create a start.bat
to run your server.
Create the start.bat
file next to update.bat
and open with Notepad as above.
|
|
IMPORTANT:
Rust/RustDedicated.exe
is used: If you called the install folder something else, change this. This is the name of the folder next to thestart.bat
file. You will also find<YOUR PUBLIC IP>
, this must be set to your correct external IP (The one others connect to your server with/seen by the internet) for the mobile companion app to work properly. Finally, replacecd <RUST FOLDER>
withcd C:\Users\tcno\Desktop\RustServer\Rust
(your Rust server’s full path).If you’d like to automatically check for updates/verify files each time you start the server without needing to run
update.bat
yourself, add the following on a new line just after:start
in yourstart.bat
file (replacing the placeholders as in the steps above).
|
|
Replace
TroubleChute's Rust Guide Server
with the name of your server. Adjust the server.seed, server.worldsize and server.maxplayers to your liking as well. 2000 is a smaller map, 5000 is a much larger map.If you wish you can also enter more options to the
start
command such as:+server.description "This is a test server" +server.url "https://hub.tcno.co" +server.headerimage "https://tcno.co/assets/img/icons/ico_TroubleChute_Full.webp" +server.gamemode "hardcore" +server.tags vanilla,creative
Going to use RCON to Remotely CONtrol your server and run commands? Make sure to include
+rcon.password <THIS SHOULD BE STRONG> +rcon.port 28018
. If you would like RCON to work over the internet then make sure to change the Firwall rules and Port Forwarding steps below to use28015-28018
instead of28015-28017
.
Run your server at least once to generate folders and files required.
Joining your new Rust server
Simply open the console in-game using F1 and run connect localhost
, or connect 127.0.0.1:28015
.
Letting other people connect
The first thing is the firewall. The Windows Firewall, and antivirus software with firewalls or third-party filewalls that listen to the Windows Firewall rules are easy – Others may need a more in-depth Google session to solve.
Usually you’ll open Windows Defender Firewall with Advanced Security
, but no more! Here are some simple commands to save you LOTS of clicks.
Open PowerShell
as admin by searching for it in your start bar, or open the Terminal
as admin, if you have that installed, and then make sure PowerShell
appears as the top - otherwise select it from the dropdown.
Now, run the following commands to allow traffic for port 28015 through to your computer:
|
|
If you ever wish to remove your Firewall rules for this, run the command: Remove-NetFirewallRule -DisplayName "Rust Server"
This will open both of the ports and allow people on the same local network as you to connect to your server while it’s running.
All you need is your local IP address (Other devices on your network may be able to see you in the LAN
tab of the server browser as well).
To get your local IP:
- Run the following in a terminal/CMD/powershell window:
ipconfig
- Find the way you’re connected to the internet, for example
Ethernet adapter Ethernet
- Find the
IPv4
address and copy it - For example, your local IP is
192.168.1.10
Other devices can use this local IP address to connect to your server. Note: This is a LOCAL IP, and your server is not yet accessible over the internet or even routers outside of your own… That’s where we need to
Port Forward
Using your Local IP address we found above (and allowed ports through to) - We need to send traffic from these two ports to our computer.
If you’re using multiple routers in a chain before your computer reaches your fiber box/access box: You’ll need to port forward each router to the next until you finally port forward to your computer.
Port forwarding varies wildly from router to router, and you can look up guides specifically for your router. Essentially you’ll need to forward all ports between 28015
and 28017
on both TCP
and UDP
to your computer (or the next router on the way to your computer).
On most routers you can enter a range such as 28015-28017
. If you cannot then you’ll need to port forward 28015
, 28016
and 28017
. Select TCP/UDP
for the protocol if available, if not you will need to repeat the steps to add a rule for TCP and then UDP.
Let’s say you have just ONE router between you and the internet (Example: You’re connected directly to the fiber box), you’ll port forward as follows:
- Ports:
28015-28017
- Type:
TCP/UDP
- Destination:
192.168.1.10
Now you’re done port forwarding.
Letting others join
At this point you’ve allowed local traffic and over the internet to reach your Rust server. All you need to do is let others join by checking the Server Browser in-game, or by getting your external IP address by Google searching “What is my IP”.
Others can then use the console to connect using connect xxx.xxx.xxx.xxx:28015
.
After a short while of having the server running it should, if allowed through your firewall and port forwarded correctly, show on the global server list.
Have fun!
Giving yourself admin
To give yourself access to commands make sure to run the command ownerid <SteamID 64> <username>
.
Get your SteamID 64 from a website like steamid.uk, or simply visit your own profile in Steam and you should see a url in the format of steamcommunity.com/profiles/<SteamID 64>
. If you see steamcommunity.com/id/<custom identifier>
you can not use this to identify yourself on the Rust server and the easiest way around it is using a third-party website like mentioned before.
You should also see the ID of players joining using RCON, or just checking your server as people join, though copying from a website is often a lot easier if text is moving quickly.
Whenever you run commands that change configurations use the command server.writecfg
to save your changes persistently.
Saving and closing your server
As long as your server is running people should be able to play on your server. When you are ready to restart or shut-down your game server use the commands: server.save
and quit
to save and close your server.
Rust should, by default, save the state of the server every 60 minutes. This can be adjusted in the server.cfg
file in <Rust Folder>\server\my_server_identity\cfg
. If this file doesn’t exist you can create it as server.txt
and rename it so it’s file type changes to .cfg
. Use the command server.saveinterval <interval>
which is by default server.saveinterval 600
. The <interval>
is the time between saves in seconds.
You can load or reload changes in here by using the command server.readcfg
, or by restarting the server entirely.
|
|
Eras and Gamemodes
There are a few gamemodes that you can choose and use. These are set in your start.bat
as +server.gamemode <name>
. There is vanilla
, survival
, softcore
, hardcore
, and primitive
, as well as a few placecholders including deathmatch, teamdm, onedeath, koth_solo, koth_team
and weapontest
used for testing weapon changes.
Only a few of these mean something. vanilla
should NEVER be used as it causes issues. This is the default when no gamemode is set.
Using survival
- the default gamemode. This is set with +server.gamemode ""
and NOT “survival”.
Using +server.gamemode softcore
and +server.gamemode hardcore
will make the game easier, or harder by disabling or limiting features.
Finally, primitive
is used to apply certain restrictions on items and features – and allows us access to the new medieval era!
NOTE: When you set these, it’s a good idea to set it as a tag as well! Use +server.tags vanilla,primitive
for example.
Create a Primitive / Medieval Rust server
Use +server.gamemode primitive
to select this restricted gamemode, and use +server.era
followed by primitive
, medieval
, frontier
, or rust
.
Rust is the default base game.
Primitive is the most restricted gamemode, with most weapons items and monuments removed.
Medieval (the new one) is the same as Primitive, but allows access to the revolver, blunderbuss and double-barrel shotguns as the most notable changes.
Frontier is currently a placeholder for the most part, and is the same as Medieval feature-wise.
Using Primitive, Medieval or Frontier restricts access to full metal armor, chainsaw, jackhammer, most weapons and ammunition, SAM sites, as well as components related to weapons like springs, and rifle/semi/smg bodies. Disabled monuments include the Giant Excavator, Missile Sile, Oil Rig and Underwater labs. NPCs such as Cargo, the Patrol Helicopter and Bradley no longer spawn. Building to Metal and higher is restricted, and the same goes for armoured doors. Turrets are allowed, however. Transport like Minicopters, Scrappies and Attack helicopters are disabled. The workbenches see increased scrap price when using the tech tree. Finally, raiding can mainly be done with Siege weapons such as a catapult or battering ram instead of rocket launchers and the rest.
To make your server a primitive Medieval vanilla server, you would use something like: +server.gamemode primitive +server.era medieval +server.tags vanilla,primitve,medieval
NOTE
While gamemodes and eras can be changed while the server is running and mid-wipe: you should NEVER do this unless you are absolutely certain it’s correct. Doing so will cause a reset to all players and their inventories with no way to revert it. Find more info on the Rust Wiki - Server Gamemodes.
More reading
While you’re here, check out the guide on installing uMod and plugins for your Rust server, as well as the other Rust Articles on this website.