Blog · WebJi® India

Valheim Dedicated Server Setup

Quick answer: Install SteamCMD on a Linux VPS, run app_update 896660 with validate, start the binary with a server name, world and password of at least five characters, then open UDP 2456 and 2457. Run it under systemd and back up both world files before anyone joins.
✓ In business since 2005✓ INR + GST billing✓ 24/7 Email Support — avg reply < 60 min
Focused Indian analyst studying analytics charts across two monitors — valheim dedicated server setup

What the server needs before the first command

A Valheim dedicated server is a Linux process you install with SteamCMD, run as a service, and back up on a schedule. You need a VPS with about 4 GB of RAM, sudo access, and UDP ports 2456 and 2457 open. No Steam account is required, because the server app installs anonymously.

  • OS: Ubuntu 22.04 or 24.04, or any distro with a 64-bit runtime and SteamCMD available.
  • Panel: none. This is a shell install, not a cPanel job.
  • Network: a public IPv4 address. IPv6-only will not work for the default join flow.
  • Player count: the server is happiest with a group of two to ten; beyond that, read the RAM table below.

Install Valheim with SteamCMD

Valheim's dedicated app is 896660. The install is four commands, run as a non-root user so the server never runs with root privileges.

  1. sudo adduser --disabled-password --gecos "" valheim then switch to it with sudo su - valheim.
  2. mkdir -p ~/valheim && cd ~/valheim, then install SteamCMD with sudo apt install steamcmd.
  3. Run steamcmd +force_install_dir ~/valheim +login anonymous +app_update 896660 validate +quit. It downloads roughly 2 GB and ends with a success line.
  4. Start it once by hand: ./valheim_server.x86_64 -name "YourName" -port 2456 -world "Dedicated" -password "yourpass" -public 1.

The password must be at least five characters and must not appear inside the server name. Those two rules cause more failed first starts than anything else.

How much RAM and CPU ten players need

The vendor does not publish a hard player-to-RAM table, so treat these as working figures from running worlds, not a specification.

PlayersRAMNotes
1 to 44 GBFine for a small build and short sessions
5 to 108 GBComfortable with a large base and several portals
Modded, or 10+16 GBMods add memory, and so does a big explored map

Two vCPU is enough. The server is more sensitive to single-core speed than to core count, and to disk latency when it writes a save. NVMe storage removes a class of stutter that has nothing to do with the network.

Open the ports and prove they are open

Valheim listens on UDP 2456, and the query port is 2457. Open both, in that order, or friends will see a server that never appears.

  1. sudo ufw allow 2456:2457/udp, then sudo ufw reload.
  2. Confirm the process is listening: ss -lunp | grep 245 should show the valheim binary on 2456 and 2457.
  3. From outside, ask a friend to join by IP and port. A timeout there with a listening process means the provider firewall or the game port is blocked, not that the server is down.

With -crossplay the session is relayed through PlayFab, and players can join with a join code instead of an IP. Keep the UDP ports open anyway, so both paths work.

Run it as a service, not in an SSH window

A server started by hand dies when the SSH session closes. A systemd unit restarts it after a crash and starts it at boot.

  1. Create /etc/systemd/system/valheim.service with ExecStart pointing at the binary and the same arguments you used by hand.
  2. Add Restart=on-failure, RestartSec=10 and User=valheim, and set WorkingDirectory to the install folder.
  3. Run sudo systemctl daemon-reload, then sudo systemctl enable --now valheim.
  4. Watch the first start with journalctl -u valheim -f. You know it worked when the log shows the world name and a line that the game server connected.

Back up the world before anyone joins

A Valheim world is two files with the same name: Dedicated.db and Dedicated.fwl. They live under ~/.config/unity3d/IronGate/Valheim/worlds/ for the user that runs the server. Copy only one and the world either fails to load or reverts.

  1. Stop the service cleanly with sudo systemctl stop valheim, so the save flushes.
  2. Archive both files: tar czf ~/valheim-backup-$(date +%F).tar.gz -C ~/.config/unity3d/IronGate/Valheim/worlds .
  3. Copy that archive off the server, to your own machine or object storage. A backup on the same disk is not a backup.
  4. Schedule it daily with crontab -e, and keep the last seven archives.
  5. To restore, stop the service, put the old pair back in the worlds folder, and start it again.

Do this before the first friend joins, not after the first build disappears. Reverted progress is the most common complaint about community servers, and it is nearly always a missing .fwl or a save copied while the server was running.

Connect and confirm the world is live

Join with IP:2456, or use the join code if crossplay is on. Then check the server side, because a successful join from one machine can hide a world that did not load.

  1. Read the log for the world name you passed with -world. A different name means you are on a new, empty map.
  2. Join from a second network, such as a phone hotspot, to prove the port is open beyond your own LAN.
  3. Place a marker, log out, restart the service, and log back in. If the marker is still there, saving works.

The five failures that stop a first join

What happensCause and fix
Process exits immediatelyPassword shorter than five characters, or contained in the server name. Change both, restart.
"Failed to bind socket" in the logAnother process holds 2456. Find it with ss -lunp and stop it.
Server starts but the map is emptyThe -world name does not match the files. Use the exact name of your .db file without the extension.
Friends time outUDP 2456 and 2457 are blocked, or the port rule sits on the wrong interface. Re-run the ss check, then the firewall.
Progress reverts after a restartThe save was copied while running, or the .fwl is missing. Restore the last full pair.

When to email support

Email support@webji.services with the log line, the output of the port check and the time of the failure. Support is 24/7 by email in Hindi and English, and the average first reply is under 60 minutes. The office phone is a business-hours line, not a support queue.

If you would rather not run the service unit and the backups yourself, Valheim server hosting covers the managed version, and a general VPS gives you the shell this guide assumes. Managed plans are quoted by email before payment, because slots and mods change the RAM figure.

Frequently Asked Questions

How do I set up a Valheim dedicated server?

Install SteamCMD on a Linux VPS, run app_update 896660 validate into a folder, start the binary with a name, world and password, then open UDP 2456 and 2457. Put it under systemd so it survives a disconnect.

How much RAM does a Valheim server need?

About 4 GB for up to four players, 8 GB for five to ten, and 16 GB for a modded world. The vendor does not publish a fixed table, so these are working figures from running servers rather than a specification.

Which ports does Valheim use?

UDP 2456 for the game and 2457 for the query. Open both in the firewall and confirm with ss that the process is listening. With crossplay enabled, players can also join by code through the PlayFab relay.

How do I back up a Valheim world?

Stop the service, then archive both Dedicated.db and Dedicated.fwl from the worlds folder together. Copy the archive off the server and keep seven days. Restoring one file without the other is what causes a reverted map.

Does the world keep running when everyone logs off?

Yes. The dedicated server keeps the world loaded and time passing while it runs, which is why crops grow and bases can be attacked offline. Stop the service if you want the world to pause.

Need help with this?

WebJi® support does it for you — free. Talk to our Jaipur team →