How to Start a Valheim Server with Friends
Getting your Viking crew together in Valheim is one of the best ways to experience the game. Whether you’re battling fearsome creatures, building epic longhouses, or just exploring the vast landscapes, playing with friends enhances the experience tenfold. But how exactly do you start a Valheim server so you can explore, build, and conquer together? It’s actually quite straightforward, and this guide will walk you through the process. There are primarily two ways to play with friends: using the in-game server options, or setting up a dedicated server. We’ll cover both.
In-Game Server Options: The Quick Start
The easiest way to start playing with friends is through Valheim’s built-in server options. This approach is perfect for those looking for a quick and easy setup without having to deal with more complex configurations.
Starting a Friends-Only Server
- Launch Valheim: Start the game as you normally would.
- Select Your Character: Choose the Viking you wish to play.
- World Selection: On the World Selection screen, you can either choose an existing world or create a new one by clicking “New”.
- Start Server: After selecting or creating your world, click the “Start Server” option.
- Invite Your Friends: Your friends can now join your server by using the in-game friend invite system or by searching for the server if you’re on the same local network.
This option creates a private server which is only available for your friends, meaning that no strangers can join your server, making this a great option if you just want to play with your established group.
Community Servers
If you want a server that anyone can join, choose “Community Server” instead of “Start Server”. This option makes your server publicly listed, so be aware that other players may join. This may be a fun way to meet new players but be sure you are ready for strangers to be in your game.
Limitations of In-Game Servers
Keep in mind that in-game servers have limitations. Specifically, the game needs to be running on the host’s machine at all times for other players to connect. This means if the host is not online, the server is down and no one can play. This can be inconvenient if your friends want to play when you’re unavailable. This is why a dedicated server might be a better option for some.
Setting Up a Dedicated Valheim Server: For the Serious Viking
A dedicated server allows for a more stable and persistent experience. Your server will be online 24/7, allowing your friends to play whenever they want, even if you’re not online. This option is a bit more involved, but well worth it for frequent players.
Step 1: Install the Valheim Dedicated Server Tool
- Open Steam: Launch the Steam client.
- Navigate to Library: Go to your Steam library.
- Search for Valheim Dedicated Server: In the search bar, type “Valheim Dedicated Server” and install the tool.
- Note: If you don’t have Valheim already, you will also need to purchase and install the base Valheim game.
Step 2: Edit the “startheadlessserver” File
This is where you configure your server settings.
-
Locate the Server Files: Go to your Steam library, right-click on “Valheim Dedicated Server”, select “Manage” then “Browse local files” to access the folder where the server is installed.
-
Open “startheadlessserver.bat”: Right-click and select “Edit” to open the file in Notepad or another text editor.
-
Modify Server Settings: Inside the file, you’ll find lines to modify, for example:
-
-name "My Awesome Server"
: This sets your server name. Replace “My Awesome Server” with your server’s name. -
-world "MyWorld"
: This sets the name of your game world. Replace “MyWorld” with your desired world name. -
-password "yourpassword"
: Set a password for your server. Change “yourpassword” to a secure password of your choice. -
-port 2456
: This is the default port number for the Valheim Server, if you need to change it for any reason, this is where you can do it. If you are keeping the default port, you can generally leave this setting as is. -
-public 1
: If you want your server to be listed in the server list then set this to 1. Otherwise, setting to 0 makes it unlisted but still joinable with the correct details.
-
-
Save Changes: After editing the file, save your changes.
Step 3: (Optional) Copy Existing World Files
If you have an existing world you want to host, copy its files to the dedicated server folder.
- Find Your World Files: Navigate to
C:Users[Your User Name]AppDataLocalLowIronGateValheimworlds_local
. - Copy Files: Find the
*.db
and*.fwl
files associated with your world. Copy these files. - Paste Files: Paste them into the
Valheim Dedicated Server
installation folder where the “startheadlessserver.bat” is located. - Rename if Necessary: If your server world name is different from the original, rename the files you copied to match the name of your world.
Step 4: Find Your IP Address
You’ll need to share your IP address for friends outside your local network to connect.
- Open Command Prompt: Press the Windows key, type “cmd”, and press Enter.
- Type “ipconfig”: Type
ipconfig
into the command prompt and press Enter. - Locate your IPv4 Address: Find the line that says “IPv4 Address”. This is your IP address.
Step 5: Set Up Port Forwarding
This step is crucial if your friends are not on the same local network.
- Access Router Settings: Access your router’s settings via your web browser. Usually by going to your Gateway address in your browser bar (you can find your gateway address in the ipconfig output from the step above.)
- Find Port Forwarding: Look for the port forwarding section.
- Create a Rule: Add a new rule to forward UDP traffic on port 2456 (or the port you specified in
start_headless_server.bat
) to your computer’s local IP address.
Step 6: Allow Ports Through Your Firewall
Ensure your firewall doesn’t block the server.
- Open Firewall Settings: Search for “Firewall” in the Windows search bar and open “Windows Defender Firewall”.
- Allow an App: Click on “Allow an app through Windows Firewall”.
- Add Valheim Dedicated Server: Click “Change Settings” and then “Allow another app…” locate and add the
valheim_server.exe
file located inside the folder where the dedicated server is installed. - Ensure Private & Public are Checked: Make sure that both “Private” and “Public” check boxes are selected and click OK.
Step 7: Run the Server
Now you can launch your Valheim server.
- Run the batch file: Double-click the “startheadlessserver.bat” file. A command prompt window will open, and the server will start.
Joining the Server
Your friends can now join the server using the following steps:
- Launch Valheim: Open the game.
- Select Character: Choose your Viking character.
- Join Game: Click on “Join Game”.
- Enter IP Address: Click the “Join IP” button in the bottom left, and have your friend enter your server’s IP address and port number (usually 2456)
- Enter Password: If you set one, input your server password.
- Connect: Click “Connect” to join the game.
Frequently Asked Questions (FAQs)
1. Can my friends play on my Valheim server without me?
Yes! That’s the primary benefit of a dedicated server. Once set up, your server will be running constantly, and your friends can join and play even when you aren’t online.
2. Is a Valheim dedicated server free?
Yes, the Valheim Dedicated Server tool is free to download and use through Steam. However, you need a separate PC to run the server, so there might be hardware or electricity costs.
3. How much RAM do I need for a Valheim server?
The official wiki says a Valheim dedicated server needs at least a 4 core CPU with 2GB of RAM and 2 GB of storage, but in practice it is recommended to have at least 3 GB of RAM to ensure smoother performance with a small number of players.
4. Can anyone join my Valheim server?
Yes, there are two types of servers. Start Server creates a friends-only server. Community Server makes it public, and anyone can join if they know the server details. If you are using the dedicated server tool, you can choose to have your server publicly listed or not via the -public 1/0 command in the start_headless_server.bat
file.
5. How many people can a Valheim server hold?
A Valheim server is capped at 10 players.
6. Can I transfer my world from an in-game server to a dedicated server?
Yes, by copying the world files (*.db
and *.fwl
) from C:Users[Your User Name]AppDataLocalLowIronGateValheimworlds_local
to the Valheim Dedicated Server
folder.
7. Why can’t my friends find my server in the server list?
Ensure your server is set to “public 1” in the “startheadlessserver” file and that you have port forwarding and firewall settings correctly configured. If you are not public, your friends need your public IP address to manually connect.
8. What if I don’t want to host the server myself?
You can rent a Valheim server from various hosting providers for a monthly fee.
9. How much does a rented Valheim server typically cost?
Rented servers can cost anywhere from $4.90/month and up, depending on the number of players supported and server specifications.
10. Can I password protect my server?
Yes, you can add a password by adding the -password "yourpassword"
argument to the “startheadlessserver.bat” file and change “yourpassword” to a secure password.
11. Do private servers charge a monthly fee?
Valheim servers do not have an official server monetization program, but renting a private server often involves a monthly subscription fee with hosting companies.
12. What is port forwarding, and why do I need it?
Port forwarding allows your router to direct incoming traffic on a specific port to the correct computer on your network. It’s needed for friends outside your local network to connect to your server.
13. How do I find my local IP address?
You can find it by opening the command prompt, typing “ipconfig”, and locating the “IPv4 Address”.
14. Can I start a server directly from my game?
Yes, you can, but those servers will not be online if the host is not playing.
15. What should I do if my friends have connection issues?
Check port forwarding, firewall settings, and server configuration. Ensure that everyone has the latest version of the game and is using the correct server IP address. Sometimes restarting the game and the server can also help.
By following these steps and troubleshooting tips, you’ll be well on your way to enjoying endless hours of Valheim with your friends! Happy Viking adventures!