Valheim Dedicated Server: Setup, World Modifiers and Backups

Published on | Updated

Set up a Valheim 1.0 dedicated server on Linux, set world modifiers with -preset, -modifier and -setkey, tune the backups and check the build after each patch.

Valheim logo above two Vikings resting at a campfire in a dark forest

You want a Valheim world that stays online when the host logs off, plays at the difficulty your group picked, and still lets everyone in after the next patch. This guide sets up the server on Linux, then covers world modifiers such as the event rate and death penalty, backups, and checking the server's build after an update.

Valheim left Early Access with version 1.0 on 9 September 2026. Its dedicated server does not run the game logic itself. According to the Valheim Wiki's dedicated server page, it relays traffic between players, generates terrain when someone explores a new area (the CPU-heavy part), keeps the loaded world in memory and saves it. Creatures and physics in each area are run by the game of a player who is there.

Quick answer: Install the Valheim dedicated server (Steam app 896660) with SteamCMD, +force_install_dir before +login anonymous, run valheim_server.x86_64 from your own start script as a systemd service and open UDP ports 2456 and 2457. World modifiers are start flags: -preset picks a preset and overwrites earlier modifiers, -modifier sets a single one such as raids or deathpenalty and goes after the preset, and -setkey turns on a switch such as nomap. A world keeps its modifiers, so to set the event rate back to normal, start the server with -preset normal. After every patch, stop the server, update it and check the Valheim version line in its log.

Hardware Requirements

The wiki gives these unofficial figures:

MinimumRecommended
CPU4 cores at 2.8 GHz6 cores at 3.4 GHz or more
RAM2 GB4 GB or more
Storage2 GB4 GB or more

Memory depends on how much of the world is loaded. The wiki's rough guide is 1.8 to 2.4 GB of RAM for a fresh world, plus around 100 to 300 MB for every area where players are active, and busy areas with a lot of building can need much more. You never have to plan past ten players: Iron Gate's 1.0 FAQ says Valheim 1.0 is a game for 1 to 10 players. Our server requirements guide covers sizing as the world grows.

If you would rather skip SteamCMD and systemd, our Valheim server hosting runs the official dedicated server with BepInEx mod support, NVMe SSD and DDoS protection, for Windows (Steam) players only.

Installing Valheim Dedicated Server on Linux

These commands are for Ubuntu. Valve's SteamCMD page says the package needs the multiverse repository and 32-bit (i386) packages, and that you should set the install folder before logging in, so +force_install_dir comes before +login.

# Install SteamCMD
sudo add-apt-repository multiverse
sudo dpkg --add-architecture i386
sudo apt update
sudo apt install steamcmd

# Create a dedicated user (never run game servers as root)
sudo adduser valheim

# Switch to the valheim user and make a folder for the worlds
su -l valheim
mkdir -p /home/valheim/data

# Download the Valheim dedicated server (app ID 896660)
steamcmd +force_install_dir /home/valheim/server +login anonymous +app_update 896660 validate +quit

validate checks every file against Steam's copy, which Valve suggests for a first install.

Starting the Server

The start_server.sh that ships with the server is reset every time Steam updates it, so Iron Gate's dedicated server guide tells you to work from a copy. Keep yours outside the install folder, where updates never touch it. Still as the valheim user, create /home/valheim/start.sh:

#!/bin/bash
# /home/valheim/start.sh
export SteamAppId=892970
export LD_LIBRARY_PATH=/home/valheim/server/linux64:$LD_LIBRARY_PATH
cd /home/valheim/server

exec ./valheim_server.x86_64 \
  -name "Your Server Name" \
  -port 2456 \
  -world "Dedicated" \
  -password "your_password" \
  -savedir /home/valheim/data \
  -public 1
chmod +x /home/valheim/start.sh
exit

exit takes you back to your own account for the sudo steps below. exec hands the process over to the server, so the stop signal from systemd reaches it directly. What the flags do, from Iron Gate's guide:

FlagWhat it does
-nameThe name shown in the server list
-portThe game port. The server uses this port and the next one, 2456 and 2457 by default
-worldThe world to load. If no world has this name, the server creates it
-passwordThe join password. LinuxGSM's Valheim config notes a minimum length of 5 characters
-savedirWhere the worlds and the admin, ban and permitted lists live, instead of ~/.config/unity3d/IronGate/Valheim
-public1 lists the server in the server browser, 0 hides it so players join with the Join IP button

Without -crossplay, the server uses the Steam backend, and Iron Gate's guide says only Steam users can then see and join it.

Systemd Service (Keeps Server Running)

# /etc/systemd/system/valheim.service
[Unit]
Description=Valheim Dedicated Server
After=network.target

[Service]
Type=simple
User=valheim
WorkingDirectory=/home/valheim/server
ExecStart=/home/valheim/start.sh
Restart=on-failure
RestartSec=5

[Install]
WantedBy=multi-user.target
sudo systemctl enable valheim
sudo systemctl start valheim

Iron Gate's guide says the server accepts players once it shows Game server connected. Follow the log with sudo journalctl -u valheim -f.

Firewall Rules

sudo ufw allow 2456/udp  # Game port
sudo ufw allow 2457/udp  # Game port +1

The server relies on UDP for game traffic, the wiki says, so open UDP only. If your provider runs its own firewall in front of the server, open the same ports there.

World Modifiers on a Dedicated Server

On a dedicated server, the world modifiers from the game's start screen are start flags. Iron Gate added them in patch 0.217.22, and its dedicated server guide lists three flags:

  • -preset <name> sets a preset: normal, casual, easy, hard, hardcore, immersive or hammer. A preset overwrites any modifiers set before it.
  • -modifier <modifier> <value> sets one modifier. If you also use a preset, put the modifiers after it.
  • -setkey <key> turns on one of the checkbox switches.
ModifierValues in Iron Gate's guideWhat it changes
combatveryeasy, easy, hard, veryhardDamage dealt and taken, enemy speed and size, how often enemies spawn with stars
deathpenaltycasual, veryeasy, easy, hard, hardcoreWhat you lose when you die
resourcesmuchless, less, more, muchmore, mostDrops from creatures and lootable objects, from 0.5x to 3x
raidsnone, muchless, less, more, muchmoreHow often enemies raid your base
portalscasual, hard, veryhardFrom letting every item through portals to no portals at all

Normal is not a value for any modifier. -preset normal puts every modifier back to normal. The four -setkey switches in Iron Gate's guide, as the Valheim Wiki's world modifiers page describes them:

KeyEffect
nobuildcostBuild pieces need no materials; you still discover recipes as usual
playereventsRaids follow each player's own progress instead of the bosses killed on the server
passivemobsEnemies don't attack until you provoke them
nomapNo map and no minimap

Iron Gate's 1.0 FAQ adds that some modifiers block certain achievements: hammer mode counts as a temporary cheat.

As an example, here is a normal world with the gentler casual death penalty, fewer raids and no map. Put a backslash after -public 1 in start.sh and add the lines below it:

  -public 1 \
  -preset normal \
  -modifier deathpenalty casual \
  -modifier raids less \
  -setkey nomap

Restart with sudo systemctl restart valheim. With -preset normal first, the script sets all of the world's modifiers every time it starts, whatever the world was created with.

Set the Event Rate Back to Normal

The event rate is the raids modifier: it sets how often raids happen, and the wiki's world modifiers page lists it as the EventRate key. There is no normal value for -modifier raids, and a world keeps the modifiers it was created with, because they are stored in the world itself. LinuxGSM's Valheim config warns that removing world modifiers does not reset them: you have to start the server with -preset normal at least once.

So add -preset normal to the script, put any modifiers you still want after it, and restart. An admin can do the same while the server runs: open the console with F5 and enter setworldpreset normal. Patch 0.217.22 gave admins setworldpreset, setworldmodifier and resetworldkeys; our console commands guide lists the rest. Your ID goes in adminlist.txt in the save folder (/home/valheim/data here), copied from the F2 panel in game as Iron Gate's guide says. Fix the script as well, or its flags set the old values again at the next start.

Easy Death Penalty Still Drops Your Items

If you set -modifier deathpenalty easy and still drop everything when you die, the setting works. Easy only softens the skill loss; you still drop all your items. Only casual keeps the gear you are wearing. Iron Gate described it as the mode "where you won't lose gear upon death" in a 2023 development blog, and the wiki lists what each level does:

Death penaltyEquipped gearRest of inventorySkill loss
casualKeptDropped1%
veryeasyDroppedDropped1%
easyDroppedDropped2.5%
normal (default)DroppedDropped5%
hardDroppedDestroyed7.5%
hardcoreDestroyedDestroyed100%

If casual doesn't seem to work either, look for a -preset after the -modifier, which overwrites it, and make sure the server starts from the script you edited and was restarted since. Iron Gate's guide notes that the Steam shortcut only starts the original file, which resets on every update.

Saves and Automatic Backups

The server saves and backs up on its own, set with flags from patch 0.210.6. -saveinterval sets the seconds between saves (default 1800, so 30 minutes). -backups sets how many automatic backups to keep (default 4): the first follows -backupshort (default 7200 seconds), the rest -backuplong (default 43200 seconds), so by default you have one backup that is 2 hours old and three that are 12 hours apart. They sit on the same disk as the world, so keep a copy elsewhere too. Our guide to restoring a Valheim world backup shows how to bring one back.

Update the Server and Check Its Build After a Patch

Iron Gate patched Valheim three times in October 2026: 1.0.17 on 6 October, 1.0.20 on 15 October and 1.0.21 on 28 October. The wiki's rule is to update the dedicated server every time the game updates, because players cannot connect when the versions don't match. Some patches fix saves too: 1.0.17 fixed a rare bug that could erase all objects in parts of the world when a large save chunk file was split into smaller ones.

The server is its own Steam app, so updating the game never updates it. Stop it, update the folder it starts from, and start it again:

sudo systemctl stop valheim
sudo -u valheim -H /usr/games/steamcmd +force_install_dir /home/valheim/server +login anonymous +app_update 896660 +quit
sudo systemctl start valheim

The Ubuntu package installs SteamCMD as /usr/games/steamcmd, a folder sudo does not search, hence the full path. Then check which build the server runs. It writes its version to the log every time it starts:

sudo journalctl -u valheim --since "10 minutes ago" --no-pager | grep -i "valheim version"

On 1.0 launch day that line read Valheim version: l-1.0.7 (network version 39) in a public bug report. Compare the number with the version on the game's main menu and the latest patch on Iron Gate's news page. For the Steam build of the folder itself, run grep buildid /home/valheim/server/steamapps/appmanifest_896660.acf before and after the update, the check LinuxGSM uses. If it stays the same while a new patch is out, SteamCMD did not update this folder.

If players still see "Incompatible version" afterwards, our incompatible version fix covers the next checks, including SteamCMD reporting success while the build stays old. On our Valheim servers the server binaries update automatically when Iron Gate ships a patch, and the web console shows the live log with the same version line.

World Files Since 1.0

The server keeps its worlds in a worlds_local folder under the save directory, which is /home/valheim/data in the script above. Since 1.0 each world is its own folder there, named after the world and split into many small chunk files, instead of one .db and .fwl pair. Stop the server before you copy anything, and back up or move the whole folder, never single files. An older world copied in as a .db and .fwl pair is converted to the new format the first time the server loads it, and the game makes a backup before it converts.

There is no seed option on the dedicated server. It gives the name in -world a random seed the first time. To play a particular seed, create the world on your own PC, load into it once, copy its folder into worlds_local and set -world to the world's name. It keeps the modifiers you picked there until the flags above change them. Our world generator guide covers picking the seed.

FAQ

How do I set world modifiers on a Valheim dedicated server? Add start flags: -preset first, then one -modifier per setting and -setkey for a switch such as nomap, and restart the server. Iron Gate's dedicated server guide lists every valid value.

Is there a way to set the event rate to normal on a dedicated server if the world was created with something else? Yes. The event rate is the raids modifier, and the world keeps the value it was created with. Start the server with -preset normal, which overwrites all earlier modifiers, and add the modifiers you still want after it. An admin can also enter setworldpreset normal in the F5 console.

Why is easy death not working on my dedicated server? It probably is working. Easy still drops all your items and only lowers the skill loss from 5% to 2.5%. To keep your equipped gear, use -modifier deathpenalty casual, and make sure no -preset comes after it in the script.

How do I check which version my Valheim dedicated server is running? Read the Valheim version line the server writes to its log at every start and compare it with the version on the game's main menu. With systemd: sudo journalctl -u valheim --no-pager | grep -i "valheim version" | tail -n 1.

Can I choose the seed for a Valheim dedicated server? Not with a flag. Create the world with that seed in the game, load it once, then upload the world folder and set -world to its name.

Sources

All opened on 31 October 2026: