Local DayZ Server
Here we will see how to install and set up a DayZ Standalone server on a Windows computer or server.
Prerequisites
- Windows computer/server
- with Steam installed
- Steam account
Installation
The first step is downloading the server files. This can easily be done through Steam.
- Fire up Steam
- Go to your
Library
- At the top where it says
Games
change that to includeTools
- You'll see
DayZ Server
among the results. Select it - Click
Install
- You'll notice on your desktop there'll be a shortcut to launch the server
WARNING
Don't launch the DayZ server yet!
Initialization
- Open up your File Explorer
- Move to the Dayz Server directory
INFO
The DayZ Server directory should be something along the lines of:
C:\Program Files (x86)\Steam\steamapps\common\DayZServer
.
In the remainder of this guide we will assume that this is where your DayZ Server directory is.
INFO
This is what you would see is if you were looking at the file structure on a remote server;
- Create a new text file; call it
start.bat
- Using your favorite text editor, paste this into your
start.bat
file:
@echo off
:start
::Server files location
set serverLocation="C:\Program Files (x86)\Steam\steamapps\common\DayZServer"
::Server Port
set serverPort=2302
::Server config
set serverConfig=serverDZ.cfg
::Server profile
set serverProfiles=profiles
::Logical CPU cores to use (Equal or less than available)
set serverCPU=4
:: Go to DayZServer location
cd "%serverLocation%"
::Launch parameters (edit end: -profiles=|-config=|-port=|-cpuCount=|-doLogs|-adminLog|-netLog|-freezeCheck|-filePatching|-BEpath=)
start "DayZ Server" /min "DayZServer_x64.exe" -config=%serverConfig% -port=%serverPort% -profiles=%serverProfiles% -cpuCount=%serverCPU% -dologs -adminlog -netlog -freezecheck
@echo off
:start
::Server files location
set serverLocation="C:\Program Files (x86)\Steam\steamapps\common\DayZServer"
::Server Port
set serverPort=2302
::Server config
set serverConfig=serverDZ.cfg
::Server profile
set serverProfiles=profiles
::Logical CPU cores to use (Equal or less than available)
set serverCPU=4
:: Go to DayZServer location
cd "%serverLocation%"
::Launch parameters (edit end: -profiles=|-config=|-port=|-cpuCount=|-doLogs|-adminLog|-netLog|-freezeCheck|-filePatching|-BEpath=)
start "DayZ Server" /min "DayZServer_x64.exe" -config=%serverConfig% -port=%serverPort% -profiles=%serverProfiles% -cpuCount=%serverCPU% -dologs -adminlog -netlog -freezecheck
TIP
See the Launch Parameters page for more info on the meaning of each parameter.
Don't worry if you don't have a serverDZ.cfg
in your DayZ Server directory; we're going to create one in just a minute.
Configuration
The config file serverDZ.cfg
sets all of the parameters that the server needs in order to know how to behave.
You can find an example here
WARNING
If you haven't changed any of the settings so far, then make sure that the config file is saved in the same folder as the start.bat
file.
Ideally, this should be the following folder:
C:\Program Files (x86)\Steam\steamapps\common\DayZServer
Server profile
When the server starts up it's going to create a folder (whose name depends on what you set as argument to the -profiles
parameter) and within that folder it's going to put your log files.
Also, very importantly, this is where you are eventually going to put the files that will allow you to be recognized as an admin; in other words, that's where your server will look in order to verify your claim to be an admin.
Start It
Open a new terminal and run the start.bat
script with:
.\start.bat
.\start.bat
If everything worked correctly you will get a little window with some logs.
Join It
- Fire up the DayZ launcher
- Go to
Servers
- Go to
LAN
- Click on
Join
- Congrats! You are now playing on your own local DayZ server!
Stop It
Create a new file called stop.bat
; it will look like this:
taskkill /f /im DayZServer_x64.exe
taskkill /f /im DayZServer_x64.exe
Then, just like before, open a new terminal and run the stop.bat
script with:
.\stop.bat
.\stop.bat
Reset / Wipe
- Go to the missions folder (e.g.
C:\Program Files (x86)\Steam\steamapps\common\DayZServer\mpmissions
) - Open the folder of the particular mission you are running (e.g.
dayzOffline.chernarusplus
) - Open the
storage_1
folder - Delete its content
TIP
An easier and quicker solution could be to leave your DayZServer
folder vanilla, copy it with a different name (e.g. DayZServerChernarus
), then when a reset / wipe is required you can just delete the custom folder and copy your DayZServer1
folder again, assigning it the same name as before (e.g. DayZServerChernarus
).
Soft Wipe
A "soft wipe" will wipe all the loot, all the buildings (bases), and all the cars; players will only be left with what they have in their inventory.
This can be useful when changes are made to the map: a soft wipe will prevent loot, bases or cars from hanging around in the air where (say) a building used to be in a previous version of the map.
For instance, this proved useful with update 1.23, which brought several changes to the NorthWest Airfield.
- Go to the missions folder (e.g.
C:\Program Files (x86)\Steam\steamapps\common\DayZServer\mpmissions
) - Open the folder of the particular mission you are running (e.g.
dayzOffline.chernarusplus
) - Open the
db
folder - Open the
economy.xml
file - Find the lines that start with
<dynamic>
and<vehicles>
INFO
<dynamic>
controls the loot and the buildings on your server.
<vehicles>
of course controls the vehicles on your server.
- Change their
load
parameter from1
to0
; this means that the loot (and vehicles) won't be loaded - Restart your server and wait a few minues; none of the loot will spawn in
- After a few minutes the server will save its state and none of the loot will be there. Stop the server
- Change the
load
parameters of<dynamic>
and<vehicles>
back to1
- Restart the server
Return XMLs To Vanilla
- Go to Bohemia Interactive's DayZ Central Economy GitHub repository
- Download the vanilla files (folders) for Chernarus and/or Livonia:
dayzOffline.chernarusplus
and/ordayzOffline.enoch
- Go to the missions folder (e.g.
C:\Program Files (x86)\Steam\steamapps\common\DayZServer\mpmissions
) - Replace the missions folder with those you have downloaded from Bohemia Interactive
Mod installation
- Open the DayZ Workshop page.
- Select the mod you want to install and open its page
- Click on the
Subscribe
button- This will download the mod on your computer
- Find the mod folder on your computer
- it should be placed in a folder like:
C:\Program Files (x86)\Steam\steamapps\common\DayZ\!Workshop
- it should be placed in a folder like:
WARNING
If you cannot find the !Workshop
folder change your view settings to show hidden folders.
- Copy the folder
- The folder is going to be named something like:
@
+ the name of your mod; e.g.@WindstridesClothingPack
- The folder is going to be named something like:
- Go to your DayZ Server folder
- e.g.:
C:\Program Files (x86)\Steam\steamapps\common\DayZServer
- e.g.:
- Paste the mod folder into your DayZ Server folder
- Open your mod folder
- Open the
Keys
folder - Copy the key
- The key will be a
.bikey
file; e.g.Crazymike_winterchernarus.bikey
- The key will be a
- Go back to your Local DayZ server folder
- Open the
keys
folder - Paste the key
- Go back to your Local DayZ server folder and edit your
start.bat
file- in the line that starts with
start "DayZ Server"
, add a-mod=<string>
parameter; use a semi-colon separated list of mods as argument
- in the line that starts with
TIP
In case some mods contain a space in their name, use "
's around the whole launch parameter block.
E.g.: "-mod=@Winter Chernarus"
- Start your server to see your mods in action!
Local DayZ Server or DayZ Community Offline Mode?
DayZ Community Offline Mode is brilliant for quickly getting into the game so you can have a look around, spawn things in and generally explore, but if you want to have a genuine DayZ experience you need to run your own server locally.