Valheim Dedicated Server Hosting: Setup, Mods and Backups
Valheim is best with friends, and the best way to play with friends is a dedicated server. With one, the world stays online when the host logs off, nobody's PC has to carry the whole session, and you can run mods and backups properly. This guide covers how to set up a Valheim dedicated server, move your existing world onto it, add mods safely and, most importantly, back up a world you've spent a hundred hours building.
We run YN HOSTING, which offers Valheim servers in Singapore and Frankfurt today, with India and Ashburn (US) coming soon. The steps below work for any host or your own machine.
Why use a dedicated server instead of hosting in-game?
When you host from the game menu, your PC runs the world and the game at the same time, and the world disappears when you quit. A dedicated server: - Stays online 24/7, so friends can play on their own schedule. - Spreads the load, so the host doesn't stutter during base raids. - Supports mods and admin tools in a cleaner way. - Makes backups automatic instead of "whenever someone remembers".
What a Valheim server needs
| Group size | RAM | Notes |
|---|---|---|
| 2–5 players, vanilla | 4 GB | Fine for most friend groups |
| Up to 10 players, vanilla or light mods | 4–6 GB | Large builds increase load |
| Heavily modded or huge bases | 8 GB+ | Mod packs like Valheim Plus-style overhauls |
Valheim's default player limit is 10. Mods can raise it, but performance drops in shared areas. The server uses one main thread heavily, so a fast CPU matters more than many cores. NVMe storage makes world saves quicker and smoother; all YN HOSTING servers use NVMe.
Ports
Valheim uses the port you set with -port and the next port up, so the default is 2456–2457 (UDP). If you self-host on the Steam backend, forward these on your router or open them in your firewall. Servers running with -crossplay send traffic through a relay and don't need port forwarding. A game host handles this for you.
Step 1: Install the server
Self-hosted: install "Valheim Dedicated Server" from the Tools section of Steam, or with SteamCMD using app ID 896660.
Game host: pick Valheim, choose a location near your players, and the server is installed for you.
Step 2: Set the name, world and password
The server is started with launch options such as:
-name "My Viking Server" -port 2456 -world "Midgard" -password "secret12" -public 1
-name: what shows in the server browser.-world: the world file name. If it doesn't exist, a new world is generated.-password: at least 5 characters, and it must not contain the server name.-public 1: list the server in the community browser. Use0for a private server joined by IP.
On YN HOSTING these are settings in the panel: see setting your world, server name and password.
Crossplay
Add -crossplay to run the server on the crossplay backend (PlayFab), so players on any platform can join, not only Steam. Without it, only Steam players can see and join the server. Players can connect to a crossplay server with its public IP and port, a join code or the server list, but not with a local or loopback IP. The join code appears in the server log once the server is running and changes when the server restarts, so share the current one.
World modifiers
Valheim lets you change difficulty without mods. Use -preset with one of the official presets: Normal, Casual, Easy, Hard, Hardcore, Immersive or Hammer. Then fine-tune with -modifier (set it after the preset, because a preset overwrites earlier modifiers):
- Combat: veryeasy, easy, hard, veryhard
- DeathPenalty: casual, veryeasy, easy, hard, hardcore
- Resources: muchless, less, more, muchmore, most
- Raids: none, muchless, less, more, muchmore
- Portals: casual, hard, veryhard
Checkbox options use -setkey: nobuildcost, playerevents, passivemobs or nomap. Example: -preset casual -modifier raids none -setkey nomap. Check Iron Gate's dedicated server guide for changes after updates.
Step 3: Move your existing world
Most groups start in a private game and move later. A Valheim world is two files with the same name:
- WorldName.db: the world data (terrain, buildings, items).
- WorldName.fwl: the world metadata (name and seed).
Where to find them on your PC:
- Windows: %USERPROFILE%\AppData\LocalLow\IronGate\Valheim\worlds_local
- If you used Steam Cloud saves, the files may be in worlds instead, or you can move a world to local storage from the in-game world list.
To upload:
1. Stop the server.
2. Upload both files to the server's worlds folder with SFTP (uploading files with SFTP). On Linux servers this is usually under .config/unity3d/IronGate/Valheim/worlds_local in the server user's home folder, or wherever -savedir points.
3. Set -world to the exact file name, without the extension. It's case-sensitive on Linux.
4. Start the server.
If the server creates a fresh world instead of loading yours, the name doesn't match exactly, one of the two files is missing, or the files are in the wrong folder.
Step 4: Become an admin
Add your Platform User ID to adminlist.txt in the save folder, one per line, then restart. It uses the format Platform_UserID and is case-sensitive, for example Steam_7656119XXXXXXXXXX; you can find it in the server log or the in-game F2 panel. Admins can use commands like kick, ban and save from the F5 console (you may need to enable the console with the -console launch option on your client). bannedlist.txt and permittedlist.txt work the same way; adding anyone to permittedlist.txt turns it into a whitelist.
Step 5: Add mods with BepInEx
Most Valheim mods use BepInEx, usually installed as the "BepInExPack Valheim" package from Thunderstore.
- Install BepInExPack Valheim on the server (many hosts offer a one-click option).
- Put mod
.dllfiles inBepInEx/pluginson the server. - Install the same mods on every player's game. Most gameplay mods must match on both sides. A mod manager such as r2modman or Thunderstore Mod Manager lets you share a profile code with friends.
- Start the server and check the log for errors.
Tips: - Popular server-side or both-side mods include mods for building tweaks, map sharing, item stacks and server sync. Many use ServerSync to force config settings from the server to players. - After a major game update, mods often break for a few days. Hold off updating the server until your mods are updated too. - See installing mods and plugins for the upload steps.
Step 6: Backups (do this before anything else)
Valheim worlds can be corrupted by crashes, power cuts or bad mods, and losing a long-running world is the fastest way to lose a group. Protect it:
Built-in backups
The dedicated server saves every 30 minutes by default and keeps rolling backups. You can tune this with launch options:
- -saveinterval 1800: seconds between saves.
- -backups 4: how many automatic backups to keep.
- -backupshort 7200: time before the first backup.
- -backuplong 43200: time between later backups.
Off-server backups
- Before every game update or mod change, stop the server and download both
.dband.fwlfiles. - Keep at least one copy off the server, on your PC or cloud storage.
- Ask your host whether it takes its own backups and how to restore them.
Restoring
Stop the server, replace the .db and .fwl with the backup copies (backup files may have a timestamp or .old in the name; rename them to the world name), then start again.
Performance tips
- Fewer items on the ground. Thousands of dropped items and huge piles of placed pieces in one area increase load. Use chests.
- Spread big builds out instead of putting everything in one giant base.
- Restart regularly, for example daily (automatic restarts).
- Pick a nearby location. Valheim syncs a lot of data between players. Singapore suits Southeast Asia and Frankfurt suits Europe, with India and Ashburn (US) coming soon. See our region and lag guide.
DDoS protection
Public Valheim servers can be targeted by attacks. YN HOSTING includes Gcore and Zero Lag Protection on every server, for almost lag-free play while attacks are filtered (how it works).
FAQ
How many players can join a Valheim server?
10 by default. Mods can raise this, but performance suffers in busy areas.
Which ports does Valheim use?
UDP 2456 and 2457 by default (the -port value and the next one up).
Why does my server load a new world instead of mine?
The -world name doesn't match your files exactly, one of the .db/.fwl files is missing, or they're in the wrong folder.
Do my friends need the same mods?
For most gameplay mods, yes. Share a mod manager profile so everyone matches.
Can Xbox players join?
Yes, if the server runs with -crossplay. They can join with the server's join code, its public IP and port, or the server list.
How do I back up my Valheim world?
Download the .db and .fwl files regularly, and use the server's -backups settings for automatic rolling copies.
Get your Valheim server
See our Valheim server plans in Singapore and Frankfurt, with India and Ashburn (US) coming soon, NVMe storage and 24/7 support. New customers on monthly billing can get the first month for $1 using the YN1 code on each plan card (details). Need help moving your world? Join our Discord: https://discord.gg/cCUKcyMEuH.
Comments0
No Comments Yet
Be the first to share your thoughts.
Please sign in or sign up to leave a comment.