EN

Game servers

How to Create a 7 Days to Die Server

Complete guide to installing a dedicated 7 Days to Die server on a VPS or dedicated Linux server: SteamCMD, serverconfig.xml, systemd service, administration, mods and backups.

10 min read, updated on 18 November 2026

On this page

Your values

Enter them once and the commands in this guide update.

This guide explains how to install a dedicated 7 Days to Die server on your VPS or dedicated Linux server, configure it with serverconfig.xml, run it as a systemd service under a dedicated user, then administer it and back it up.

The server has a native Linux version, distributed free of charge through Steam under application ID 294420.

Order a Server

To host your 7 Days to Die server, HostMyServers offers several suitable options:

Prerequisites

  • SSH access as root or user with sudo privileges
  • 64-bit Linux system: Debian 12/13 or Ubuntu 22.04/24.04
  • Active firewall: nftables, iptables or ufw (use only one tool at a time)
  • A Steam account that owns the game, to connect to the server (downloading the server itself does not require an account)

Required Configuration

Component Minimum Recommended
RAM 8 GB 16 GB and more
CPU 2 fast cores 4 cores or more, high frequency
Storage 40 GB SSD 80 GB NVMe SSD

The server files alone take up about 18 GB. The rest of the space is used for generated worlds, backups and mods.

Ports Used

Port Protocol Usage Exposure
26900 TCP Game Public
26900 to 26903 UDP Game Public
8081 TCP Telnet (administration console) Local only
8080 TCP Web dashboard, disabled by default Closed, or restricted to your IP

If you change ServerPort, the game ports shift by the same amount.

System Update

Terminal
sudo apt update && sudo apt upgrade -y

Installing Dependencies

SteamCMD needs 32-bit libraries. The other packages are used for downloading, checking the configuration, the Telnet console and scheduled backups:

Terminal
sudo apt install -y lib32gcc-s1 curl tar ca-certificates nano cron telnet libxml2-utils

Creating a Dedicated User

The server must never run as root. Create a user reserved for it:

Terminal
sudo useradd --create-home --shell /bin/bash sevendays

Firewall Configuration

Open only the game ports. Telnet port 8081 stays closed: the console can only be reached from the server itself.

With UFW

Terminal
sudo ufw allow 26900/tcp
sudo ufw allow 26900:26903/udp
sudo ufw reload

With iptables

Terminal
sudo apt install -y iptables-persistent
sudo iptables -A INPUT -p tcp --dport 26900 -j ACCEPT
sudo iptables -A INPUT -p udp --dport 26900:26903 -j ACCEPT
sudo iptables-save | sudo tee /etc/iptables/rules.v4

Saving the rules across reboots requires the iptables-persistent package.

With nftables

These commands enable nftables, then use the inet filter table and the input chain from the /etc/nftables.conf file shipped with the package, on both Debian and Ubuntu.

Terminal
sudo apt install -y nftables
sudo systemctl enable --now nftables
sudo nft add rule inet filter input tcp dport 26900 accept
sudo nft add rule inet filter input udp dport 26900-26903 accept
(echo "flush ruleset"; sudo nft list ruleset) | sudo tee /etc/nftables.conf

Installing SteamCMD

Open a session as the dedicated user, then download SteamCMD:

Terminal
sudo -iu sevendays
mkdir -p ~/steamcmd ~/7dtd-server ~/7dtd-data
cd ~/steamcmd
curl -fsSL https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz | tar -xzf -

Downloading the Server

Still as the sevendays user:

Terminal
~/steamcmd/steamcmd.sh +force_install_dir /home/sevendays/7dtd-server +login anonymous +app_update 294420 validate +quit

When it finishes, the message Success! App '294420' fully installed. is displayed. If the download is interrupted, run the same command again: SteamCMD resumes where it left off.

Server Configuration

Create Your Configuration File

An update can overwrite serverconfig.xml, so work on a copy that Steam will leave alone:

Terminal
cd ~/7dtd-server
cp serverconfig.xml serverconfig.custom.xml
nano serverconfig.custom.xml

Settings to Change

Find each property in the file and change only its value:

xml
<property name="ServerName" value="My 7 Days to Die Server"/>
<property name="ServerDescription" value="Welcome to my server"/>
<property name="ServerPassword" value="PlayerPassword"/>
<property name="ServerPort" value="26900"/>
<property name="ServerVisibility" value="2"/>
<property name="ServerMaxPlayerCount" value="8"/>
<property name="GameWorld" value="Navezgane"/>
<property name="GameName" value="MyGame"/>
<property name="WebDashboardEnabled" value="false"/>
<property name="TelnetEnabled" value="true"/>
<property name="TelnetPort" value="8081"/>
<property name="TelnetPassword" value=""/>
<property name="EACEnabled" value="true"/>

The UserDataFolder property is commented out in the original file. Replace the entire commented line with this one, to keep worlds, saves and mods in a single folder:

xml
<property name="UserDataFolder" value="/home/sevendays/7dtd-data"/>
Parameter Description
ServerName Name displayed in the server list
ServerPassword Password to join the server (empty = open access)
ServerPort Game port
ServerVisibility 2 = public, 1 = friends only, 0 = unlisted
ServerMaxPlayerCount Maximum number of simultaneous players
GameWorld Navezgane, a bundled world such as Pregen06k01, or RWG for a generated world
WorldGenSeed World seed when GameWorld is set to RWG
WorldGenSize Size of the RWG world: 6144, 8192 or 10240
GameName Game name, used for the save folder
SandboxCode Code that bundles the difficulty and gameplay settings
TelnetPassword When left empty, Telnet listens on the local interface only
EACEnabled Enables EasyAntiCheat
UserDataFolder Server data folder

Set the Difficulty with SandboxCode

Since version 3.0, many settings have moved out of serverconfig.xml: GameDifficulty, XPMultiplier, DayNightLength, BloodMoonFrequency, LootAbundance and others. They are now grouped in the SandboxCode property, so do not add these old properties, even if you find them in an old file.

To get your code:

  1. Launch the game and open the new game creation screen.
  2. Open the Sandbox options and adjust them.
  3. Copy the code with the button provided for this purpose.
  4. Paste it into the file:
xml
<property name="SandboxCode" value="AAAJABJACJADJARFBNC"/>

The value above is the default code, which corresponds to the Adventurer difficulty.

Check the File

An improperly closed tag prevents the server from reading its configuration. Check the file:

Terminal
xmllint --noout ~/7dtd-server/serverconfig.custom.xml && echo "Configuration is valid"

Clean Shutdown Script

To make sure the world is saved every time the server stops, the service sends the saveworld then shutdown commands to the local console. Still as the sevendays user, create the script:

Terminal
nano ~/stop.sh
Terminal
#!/bin/bash
# Save the world and stop the server through the local Telnet console.
(
  exec 3<>/dev/tcp/127.0.0.1/8081 || exit 1
  printf 'saveworld\r\n' >&3
  sleep 10
  printf 'shutdown\r\n' >&3
  sleep 2
) 2>/dev/null || exit 0

# Wait for the server to actually exit before handing control back to systemd.
while kill -0 "$1" 2>/dev/null; do
  sleep 2
done

Make it executable and exit the session:

Terminal
chmod +x ~/stop.sh
exit

Configuration as a systemd Service

Create the Service File

Terminal
sudo nano /etc/systemd/system/7dtd.service
Configuration
[Unit]
Description=7 Days to Die Dedicated Server
Wants=network-online.target
After=network-online.target

[Service]
Type=simple
User=sevendays
Group=sevendays
WorkingDirectory=/home/sevendays/7dtd-server
ExecStart=/bin/sh /home/sevendays/7dtd-server/startserver.sh -configfile=serverconfig.custom.xml
ExecStop=/home/sevendays/stop.sh $MAINPID
TimeoutStopSec=180
Restart=on-failure
RestartSec=30
LimitNOFILE=100000

[Install]
WantedBy=multi-user.target

Enable and Start the Service

Terminal
sudo systemctl daemon-reload
sudo systemctl enable --now 7dtd.service

Management Commands

Terminal
# Check status
sudo systemctl status 7dtd.service

# Stop the server cleanly
sudo systemctl stop 7dtd.service

# Restart the server
sudo systemctl restart 7dtd.service

Follow the Startup

The launch script writes one timestamped log per startup. To follow the most recent one:

Terminal
sudo -u sevendays bash -c 'tail -f "$(ls -t /home/sevendays/7dtd-server/7DaysToDieServer_Data/output_log__*.txt | head -1)"'

Startup takes several minutes. Then check that the server is listening on its ports:

Terminal
sudo ss -tulpn | grep -E ':(26900|26901|26902|26903|8081)\b'

Connecting to the Server

  1. Launch 7 Days to Die, using the same version as the server.
  2. Open Join a Game.
  3. Find your server in the list, or use Connect to IP with the address SERVER_IP and port 26900.
  4. Enter the password set in ServerPassword.

Labels may vary slightly depending on the game's language and version.

Administration

Open the Console

Connect to the server over SSH, then open the local console:

Terminal
telnet 127.0.0.1 8081

To leave Telnet without stopping the server, press Ctrl+], then type quit.

Give Yourself Administrator Rights

The serveradmin.xml file is created on first startup in /home/sevendays/7dtd-data/Saves/. The simplest approach is to use the console rather than edit it by hand:

  1. Join the server with your character.
  2. In the Telnet console, display the IDs of connected players:
Text
lpi
  1. Give yourself the highest permission level, 0:
Text
admin add PlayerName 0

Levels range from 0 (full rights) to 1000 (no rights). Once you are an administrator, you can open the in-game console with F1.

Useful Commands

Command Description
help Lists the commands available on your version
listplayers or lp Shows connected players
listplayerids or lpi Shows players and their IDs
say "message" Sends a message to all players
kick PlayerName "reason" Kicks a player
ban add PlayerName 1 days "reason" Bans a player for a given duration
ban remove <id> Lifts a ban
whitelist add PlayerName Adds a player to the whitelist
admin add PlayerName 0 Makes a player an administrator
admin remove PlayerName Removes an administrator
saveworld or sa Saves the world
shutdown Saves and stops the server

Web Dashboard

The dashboard is disabled by default, which is the safest setting. If you enable it with WebDashboardEnabled, do not open port 8080 to everyone. Preferably, go through an SSH tunnel from your computer:

Terminal
ssh -L 8080:127.0.0.1:8080 YOUR_USER@SERVER_IP

The dashboard is then available at http://127.0.0.1:8080. If you have a fixed IP address, you can restrict the port to that address instead:

Terminal
# UFW
sudo ufw allow from YOUR_IP to any port 8080 proto tcp

# iptables
sudo iptables -A INPUT -p tcp -s YOUR_IP --dport 8080 -j ACCEPT

# nftables
sudo nft add rule inet filter input ip saddr YOUR_IP tcp dport 8080 accept

Installing Mods

With UserDataFolder set, mods go in /home/sevendays/7dtd-data/Mods/. Each mod has its own folder, which contains a ModInfo.xml file.

Terminal
sudo systemctl stop 7dtd.service
sudo -iu sevendays
mkdir -p ~/7dtd-data/Mods
# Copy the mod folder here, for example with scp or unzip
exit
sudo systemctl start 7dtd.service

Then check that the mod appears with the version command in the console.

Since version 3.0, some mods written for older versions no longer work. Check compatibility before any update.

Server Update

Players and the server must use the same game version. Back up before every update, because a major version change can make a save incompatible. The backup.sh script is described in the next section.

Terminal
sudo systemctl stop 7dtd.service
sudo -u sevendays /home/sevendays/backup.sh
sudo -iu sevendays
~/steamcmd/steamcmd.sh +force_install_dir /home/sevendays/7dtd-server +login anonymous +app_update 294420 validate +quit

Then compare your configuration with the newly supplied file, to spot added or removed properties:

Terminal
diff ~/7dtd-server/serverconfig.xml ~/7dtd-server/serverconfig.custom.xml
exit
sudo systemctl start 7dtd.service

Automatic Backup

Backup Script

Terminal
sudo -u sevendays nano /home/sevendays/backup.sh
Terminal
#!/bin/bash
BACKUP_DIR="/home/sevendays/backups"
DATE=$(date +%Y-%m-%d_%H-%M-%S)
ARCHIVE="$BACKUP_DIR/7dtd_$DATE.tar.gz"

umask 077
mkdir -p "$BACKUP_DIR"

# If the server is running, save the world before archiving
(
  exec 3<>/dev/tcp/127.0.0.1/8081 || exit 1
  printf 'saveworld\r\n' >&3
  sleep 15
) 2>/dev/null

tar -czf "$ARCHIVE" -C /home/sevendays 7dtd-data 7dtd-server/serverconfig.custom.xml
STATUS=$?

# Exit code 1 only means a file changed while it was being read
if [ "$STATUS" -gt 1 ]; then
  rm -f "$ARCHIVE"
  echo "Backup failed" >&2
  exit "$STATUS"
fi

# Delete backups older than 7 days
find "$BACKUP_DIR" -name "7dtd_*.tar.gz" -mtime +7 -delete

echo "Backup completed: $ARCHIVE"
Terminal
sudo chmod +x /home/sevendays/backup.sh

Schedule the Backup

Terminal
sudo crontab -u sevendays -e

Add:

Text
# Backup every 6 hours
0 */6 * * * /home/sevendays/backup.sh

Also keep a copy on another machine: a backup stored on the same disk does not protect you if that disk fails.

Restore a Backup

Replace the archive name with the name of the backup you want to restore:

Terminal
sudo systemctl stop 7dtd.service
sudo -iu sevendays
mv ~/7dtd-data ~/7dtd-data.old
tar -xzf ~/backups/7dtd_2026-01-01_12-00-00.tar.gz -C ~
exit
sudo systemctl start 7dtd.service

Once you have checked the result in-game, you can delete ~/7dtd-data.old.

Troubleshooting

Service won't start

  • Check the service status: sudo journalctl -u 7dtd.service -n 100
  • Check the latest output_log__*.txt file in 7DaysToDieServer_Data/
  • Validate the configuration: xmllint --noout /home/sevendays/7dtd-server/serverconfig.custom.xml
  • Check disk space and memory: df -h and free -h
  • Check that the files belong to the user: sudo chown -R sevendays:sevendays /home/sevendays

Unable to determine CPU Frequency

If SteamCMD displays Unable to determine CPU Frequency. Try defining CPU_MHZ., set the variable before running the command again:

Terminal
export CPU_MHZ=2000

Error! App '294420' state is 0x202 after update job

This error is usually caused by a lack of disk space or incorrect permissions. Check df -h, fix the file ownership with the chown command above, then run SteamCMD again.

steamclient.so Error

If the logs report steamclient.so, create the link to SteamCMD's file:

Terminal
sudo -iu sevendays
mkdir -p ~/.steam/sdk64
ln -sf ~/steamcmd/linux64/steamclient.so ~/.steam/sdk64/steamclient.so
exit
sudo systemctl restart 7dtd.service

Players can't connect

  • Wait for startup to finish, especially when a world is being generated
  • Check that the server is listening with the ss command shown above
  • Check the firewall: 26900 on TCP and 26900 to 26903 on UDP
  • Check that the player is using the same game version as the server
  • If you use mods, check the EACEnabled value and the mod's instructions

Server doesn't appear in the list

  • Check that ServerVisibility is set to 2
  • Wait a few minutes after startup
  • Try connecting directly with Connect to IP to tell a list problem from a network problem

Telnet console refuses the connection

  • The server may still be starting up
  • Check that TelnetEnabled is set to true and TelnetPort to 8081
  • Run telnet from the server itself, not from your computer

Server stops or slows down

  • Look for a lack of memory: sudo journalctl -k | grep -i "out of memory"
  • Reduce ServerMaxPlayerCount and MaxSpawnedZombies
  • Choose a smaller world
  • Remove the heaviest mods
  • If the problem persists, upgrade to a plan with more RAM