A Valheim dedicated server on Linux gives you a persistent game world that can remain available around the clock while giving you control over server configuration, backups, administration, and networking.
Valheim 1.0 is scheduled for release on September 9, 2026, with full crossplay between supported platforms. This makes dedicated servers an especially useful option for groups playing across different platforms.
In this guide, you'll learn how to install and configure a Valheim dedicated server on Ubuntu Linux using SteamCMD, configure networking and Crossplay, run the server as a systemd service, and manage backups and server permissions.
Looking for a reliable server for Valheim? FitServers provides high-performance dedicated server infrastructure suitable for persistent multiplayer game workloads. Choose the CPU, RAM, storage, and network configuration that fits your workload.
Valheim Dedicated Server Requirements
Iron Gate does not publish a single fixed CPU and RAM specification for every dedicated-server workload. Resource requirements can vary depending on the number of players, world activity, and the complexity of the environment.
Valheim servers are capped at 10 players, so most private groups do not need extremely large server configurations.
As a practical starting point, consider:
- CPU: 2–4 modern CPU cores
- RAM: 4–8 GB depending on workload
- Storage: SSD or NVMe storage with at least 10 GB of available space
- Operating System: Ubuntu 22.04 LTS or Ubuntu 24.04 LTS
- Network: A stable public network connection with sufficient bandwidth and low latency
- Access: SSH access with sudo privileges
For larger builds, active worlds, or multiple server processes, additional CPU and RAM may be appropriate.
- For a small private server with up to 4 players, 2–4 CPU cores and 4–8 GB RAM is typically sufficient.
- For larger or more active worlds with heavier builds, 4+ CPU cores and 8 GB or more RAM is recommended.
- NVMe SSD storage improves server responsiveness and makes backup operations more efficient.
Choose an Ubuntu Linux Server
For this tutorial, we will use Ubuntu 24.04 LTS. Ubuntu provides a straightforward environment for installing SteamCMD and the Linux Valheim Dedicated Server. The same general process can be adapted to other modern Linux distributions, but package names and commands may differ.
If you haven't deployed a server yet, you can choose a FitServers dedicated server configuration based on your expected player count and workload.
Step 1: Connect to Your Server via SSH
From Linux or macOS, open a terminal and connect using SSH:
ssh root@YOUR_SERVER_IP
Windows users can use an SSH-capable terminal such as PowerShell or a third-party SSH client. After connecting, update the system:
apt update && apt upgrade -y
If you are using a non-root account with sudo privileges, use:
sudo apt update && sudo apt upgrade -y
Keeping the operating system updated helps ensure that you have current security patches and package versions.
Step 2: Install Required Dependencies
The Valheim Dedicated Server requires several Linux libraries. Iron Gate's official dedicated-server documentation specifically lists libatomic1, libpulse-dev, and libpulse0 as required packages.
First, enable 32-bit architecture:
dpkg --add-architecture i386
apt update
Then install the required packages and utilities:
apt install -y lib32gcc-s1 libatomic1 libpulse-dev libpulse0 curl wget ufw
If you are using a sudo-enabled account:
sudo dpkg --add-architecture i386
sudo apt update
sudo apt install -y lib32gcc-s1 libatomic1 libpulse-dev libpulse0 curl wget ufw
Step 3: Create a Dedicated Valheim User
For security, avoid running the game server as the root user. Create a dedicated Linux account for Valheim:
adduser valheim
Follow the prompts to create the account and password. Then switch to the new account:
su - valheim
From this point onward, the Valheim server files will be stored under the valheim user's home directory.
Step 4: Install SteamCMD
SteamCMD is Valve's command-line tool for downloading and updating Steam applications, including the Valheim Dedicated Server.
Create a directory for SteamCMD:
mkdir -p ~/steamcmd
cd ~/steamcmd
Download the Linux SteamCMD package:
wget https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz
Extract it:
tar -xzf steamcmd_linux.tar.gz
You should now have the SteamCMD executable available in the ~/steamcmd directory.
Step 5: Download the Valheim Dedicated Server
Valheim's Dedicated Server application uses Steam App ID 896660. Create the installation directory and download the server files with SteamCMD:
./steamcmd.sh +force_install_dir ~/valheim_server +login anonymous +app_update 896660 validate +quit
SteamCMD will download the required server files into /home/valheim/valheim_server. When the installation completes successfully, you can move to the server directory:
cd ~/valheim_server
Step 6: Create the Valheim Server Startup Script
Valheim includes a default Linux startup script called start_server.sh. It is recommended to make a copy of the original script rather than editing it directly because updates can reset the original startup script.
Create a copy:
cp start_server.sh start_valheim.sh
Open the copied script:
nano start_valheim.sh
Locate the command that launches valheim_server and configure it using the options you want. A basic example is:
./valheim_server -nographics -batchmode -name "My Valheim Server" -port 2456 -world "DedicatedWorld" -password "Secret123" -public 1
Important Server Options
- -name: Sets the name displayed in the server browser. Example: -name "My Valheim Server"
- -port: Sets the server's base port. The default is 2456. Valheim uses the specified port and the next port, so the default range is 2456–2457.
- -world: Specifies the world name. Example: -world "DedicatedWorld". If a world with that name does not already exist, Valheim will create one.
- -password: Sets the password required to join the server. Use a strong password and avoid reusing passwords from other accounts.
- -public 1: Makes the server visible in the server browser. Use -public 0 if you want the server hidden from the public browser and intend to use a direct connection method instead.
Step 7: Enable Valheim Crossplay
If players on different supported platforms need to connect to the same dedicated server, add the -crossplay argument. For example:
./valheim_server -nographics -batchmode -name "My Valheim Server" -port 2456 -world "DedicatedWorld" -password "Secret123" -public 1 -crossplay
The -crossplay argument enables Valheim's Crossplay backend. Without it, the dedicated server uses the Steam backend. With Crossplay enabled, users on supported platforms can connect to the server. Valheim 1.0 is scheduled to introduce full crossplay between supported platforms on September 9, 2026.
- Steam backend: Uses the Steam backend, intended for Steam players, requires the server's ports to be reachable from the internet. Default ports are 2456–2457.
- Crossplay backend: Uses Valheim's Crossplay backend, allows players on supported platforms to connect, uses a relay service, does not require traditional router port forwarding. Players can connect using a join code, server browser, or supported public IP/port connection methods.
If your goal is to allow friends playing on different platforms to join the same server, Crossplay is generally the appropriate configuration.
Step 8: Configure the Firewall
Before enabling UFW, make sure SSH access is allowed. Otherwise, enabling the firewall without an SSH rule can lock you out of the server. Switch back to your root account or open another SSH session with sudo privileges.
Allow SSH:
sudo ufw allow OpenSSH
Allow the default Valheim UDP port range:
sudo ufw allow 2456:2457/udp
Then enable UFW:
sudo ufw enable
Check the firewall status:
sudo ufw status
You should see rules for SSH and the Valheim UDP ports.
This depends on the backend you use. For the Steam backend, the Valheim documentation states that the server's port range must be accessible from the internet, which may require port forwarding when the server is behind a router or NAT. For the Crossplay backend, Valheim uses a relay service, so traditional router port forwarding is not required for external players to access the server.
A public cloud or dedicated server with a public IP generally does not require the same home-router port-forwarding setup.
Step 9: Create a systemd Service
You can start Valheim manually, but a systemd service is a better approach for a persistent Linux server. It allows the server to start automatically after a reboot, run independently of your SSH session, restart after certain failures, be monitored using standard Linux service commands, and produce logs accessible through journalctl.
Switch back to your root or sudo-enabled account and create the service file:
sudo nano /etc/systemd/system/valheim.service
Add the following configuration:
[Unit]
Description=Valheim Dedicated Server
Wants=network-online.target
After=network-online.target
[Service]
Type=simple
User=valheim
WorkingDirectory=/home/valheim/valheim_server
ExecStart=/bin/bash /home/valheim/valheim_server/start_valheim.sh
Restart=on-failure
RestartSec=5
[Install]
WantedBy=multi-user.target
Save the file and reload systemd:
sudo systemctl daemon-reload
Enable the service so it starts automatically after reboot:
sudo systemctl enable valheim
Start the server:
sudo systemctl start valheim
Check its status:
sudo systemctl status valheim
If everything is working correctly, the service should show as active.
Step 10: View Valheim Server Logs
Because the server is running through systemd, you can monitor its output using journalctl. To view recent logs:
sudo journalctl -u valheim
To follow the live log:
sudo journalctl -u valheim -f
Look for "Game server connected" in the logs—this indicates that the server has successfully started and is ready to accept connections. Press Ctrl + C to stop following the log.
Step 11: Configure Automatic World Backups
Valheim includes built-in automatic backup functionality. You can configure the number of backups and backup intervals using -backups, -backupshort, and -backuplong options.
According to the official documentation, the default backup configuration keeps one shorter-term backup and additional longer-term backups. The default short backup interval is 2 hours, while the long interval is 12 hours.
You can explicitly configure these values if desired:
-backups 4 -backupshort 7200 -backuplong 43200
Here, 7200 seconds = 2 hours and 43200 seconds = 12 hours. Automatic backups are useful, but they should not be your only backup strategy. For an important long-running world, consider periodically copying the save data to separate storage.
Step 12: Find the Valheim Save Directory
By default, Linux Valheim server data is stored under:
~/.config/unity3d/IronGate/Valheim
World files and server administration files are stored under this location. You can also specify a custom save location using the -savedir argument (e.g., -savedir /path/to/valheim-data), which can make backup management easier, especially when you want game data separated from the rest of the user's home directory.
Step 13: Manage Valheim Server Admins, Bans, and Permissions
Valheim provides three important administration files:
- adminlist.txt
- bannedlist.txt
- permittedlist.txt
These are located within the server's save directory.
adminlist.txt
Add a player's Platform User ID, one per line, to give them administrator privileges. Administrators can use server commands such as Kick PLAYERNAME, Ban PLAYERNAME, and Unban PLAYERNAME.
bannedlist.txt
Add Platform User IDs here to prevent specific players from joining the server.
permittedlist.txt
This file works as an allowlist. If players are added to the permitted list, only permitted players can join the server. Everyone else will be prevented from accessing the server.
The Platform User ID can be obtained from the server log or through Valheim's in-game F2 panel.
Step 14: Configure Server World Settings
Valheim's dedicated server supports additional startup options for world modifiers. For example, you can specify a difficulty preset:
-preset hard
You can also configure individual world modifiers, such as -modifier raids none and world-setting keys such as -setkey nomap. These options are useful if you want to customize the gameplay experience for your group. Check the current Valheim dedicated-server documentation before adding advanced modifiers to a production server because available settings can change between game versions.
Step 15: Update the Valheim Dedicated Server
Valheim receives game updates, so keeping the dedicated server synchronized with the current game version is important. Before major game updates, it is a good idea to verify your world backups and review official release information. Stop the server first:
sudo systemctl stop valheim
Switch to the valheim user and run SteamCMD again:
su - valheim
cd ~/steamcmd
./steamcmd.sh +force_install_dir ~/valheim_server +login anonymous +app_update 896660 validate +quit
Then return to the root or sudo-enabled account and start the service:
sudo systemctl start valheim
Step 16: How to Join Your Valheim Dedicated Server
Once the server is running, players can join through the appropriate connection method.
Using the Server Browser
If you configured -public 1, the server can appear in the in-game server browser. Search for the server name you configured with -name "My Valheim Server".
Using a Join Code
For Crossplay servers, Valheim supports joining through a join code. A player can open the Join Game section, select Add Server, and enter the join code.
Using IP and Port
Depending on the backend and network configuration, players can also connect using the server's public IP address and port. For the default configuration, the base port is 2456. For example: YOUR_SERVER_IP:2456. For Crossplay servers, Valheim's official documentation also notes that local and loopback IP addresses cannot be used to connect through the Crossplay backend.
Step 17: Common Valheim Dedicated Server Problems
Server Does Not Start
Check the service:
sudo systemctl status valheim
Then inspect the logs:
sudo journalctl -u valheim -n 100
Look for missing libraries, permission errors, incorrect paths, or configuration problems.
Server Is Not Showing in the Browser
First check that the server uses -public 1. Then verify that the server has successfully started. If you're using the Steam backend, verify that the required network ports are accessible. Also remember that the server browser can contain many entries, so searching for the exact server name can make your server easier to locate.
Players Cannot Connect
Check your firewall status:
sudo ufw status
Confirm that 2456:2457/udp is allowed. If you're using the Steam backend behind a router or NAT, confirm that the required ports are forwarded correctly. If you're using Crossplay, traditional router port forwarding is not required because the Crossplay backend uses a relay service.
Server Stops After Reboot
Check that the systemd service is enabled: sudo systemctl is-enabled valheim. If necessary, enable and start it with sudo systemctl enable valheim and sudo systemctl start valheim.
World Save Cannot Be Found
Verify the world name in your startup script (-world "DedicatedWorld")—the name must match the intended world. Also check the server's save directory and make sure the valheim user has permission to access it.
Step 18: Recommended Dedicated Server Configuration for Valheim
The ideal server configuration depends on the number of players and the complexity of your world.
Small Private Server
Suitable for a small group:
- 2–4 modern CPU cores
- 4–8 GB RAM
- SSD/NVMe storage
- Stable public network connection
Larger or More Active World
For a more active server with larger builds and heavier workloads:
- 4+ modern CPU cores
- 8 GB or more RAM
- NVMe SSD storage
- Reliable high-bandwidth network connection
There is no need to purchase excessive hardware simply because the server is dedicated. Choose a configuration based on your actual workload and expected player activity.
Step 19: Why Use a Dedicated Server for Valheim?
A dedicated server provides several advantages over having one player host the game from their own PC:
- Persistent World: The server can remain online even when individual players are not playing.
- No Host PC Required: Players do not need one person's gaming computer to remain online for everyone else to access the world.
- Centralized Administration: Server administrators can manage players, permissions, bans, backups, and configuration from one location.
- Better Infrastructure Control: With a dedicated server, you can choose the CPU, RAM, storage, and network configuration according to your requirements.
- Suitable for Long-Term Worlds: Automatic backups and persistent server infrastructure make dedicated servers suitable for groups that want to maintain the same Valheim world over an extended period.
Conclusion
You now have a Linux-based Valheim dedicated server configured with SteamCMD, a dedicated Linux user, firewall rules, systemd automatic startup, server backups, and administrative controls.
The setup can support a persistent Valheim world without requiring a player's personal PC to remain online. If your group uses different platforms, enabling the Crossplay backend can also make it easier for players on supported platforms to join the same server.
For larger worlds or more demanding workloads, choosing a dedicated server with sufficient CPU performance, RAM, NVMe storage, and reliable network connectivity can provide a solid foundation for long-running multiplayer sessions.
Frequently Asked Questions
How many players can play on a Valheim server?
Valheim servers are capped at 10 players.
What operating system should I use for a Valheim dedicated server?
This guide uses Ubuntu 24.04 LTS. A modern Linux distribution with the required libraries can also be used, but package installation commands may differ.
What port does a Valheim dedicated server use?
The default base port is 2456, and Valheim uses the specified port plus the next port, resulting in the default range 2456–2457.
Does Valheim Crossplay require port forwarding?
No. When the Crossplay backend is enabled with -crossplay, Valheim uses a relay service, so traditional router port forwarding is not required for external players.
Can Xbox, PlayStation, Switch, and PC players play together?
Valheim 1.0 is scheduled to support full crossplay between supported platforms. The 1.0 release is scheduled for September 9, 2026.
Where are Valheim server saves stored on Linux?
The default Linux save directory is ~/.config/unity3d/IronGate/Valheim. You can use the -savedir argument to specify a different location.
How do I restart the Valheim server?
With the systemd configuration in this guide, use sudo systemctl restart valheim and check its status with sudo systemctl status valheim.
How do I view Valheim server logs?
Use sudo journalctl -u valheim -f to display the live systemd logs for the Valheim service.
Can I use an existing Valheim world on a dedicated server?
Yes. Valheim supports using existing worlds. The world files need to be placed in the appropriate server save directory, and the -world parameter must match the world name.
Should I use automatic backups?
Yes. Valheim provides built-in automatic world backups through the -backups, -backupshort, and -backuplong options. For important worlds, it is still recommended to maintain an additional backup outside the server itself.
Ready to Deploy Your Valheim Server?
A Valheim dedicated server provides several advantages over having one player host the game from their own PC: persistent worlds that remain online even when players are not playing, no host PC required, centralized server administration, better infrastructure control, and suitable support for long-term worlds with automatic backups and persistent infrastructure.
FitServers provides high-performance dedicated server infrastructure suitable for persistent multiplayer game workloads. Choose the CPU, RAM, storage, and network configuration that fits your workload and gaming group size.
Configure your Valheim server today!