Skip to content
KCD Multiplayer

KCD2 server hosting: Host your own server

A KCD:MP server is a small program you run yourself: on your own PC for a few friends, or on a rented Windows machine for everyone. It does not need the game, only its data exporters do. These are the basic steps on Windows, from the download to a server on the list.

Rather not run it yourself? Our official hosting partners run the server for you.

1. What you need

  • A Windows PC or server with the .NET 10 runtime, installed once. The server is a .NET 10 program.
  • One UDP port, 7777 unless you pick another.
  • For the data exporters (step 7): Kingdom Come: Deliverance II on Steam (Steam 1.5.6) and the KCD:MP client on the same machine.

2. Download the server

The server is one archive with a windows/ and a linux/ folder inside. Unpack it anywhere and take the windows/ folder: that folder is your server.

KcdMp.Server.exe      the server
server.toml.example   every setting, each one explained
gamemodes/            the game modes
data/                 what the server keeps and reads
tools/                the exporters for the game's data
sdk/                  the API for your code editor

3. Start it

Double-click KcdMp.Server.exe, or run it from a terminal in its folder so the window stays open when it stops. The first start copies server.toml.example to server.toml, the file you edit. The first lines it prints say the version, the game mode it loaded and, for each data file, whether it found it. Ctrl+C stops it.

To update, unpack a new release over the folder: only the example file is replaced, so your server.toml and your settings stay.

4. Name it and choose who can join

Open server.toml in any text editor. The settings most servers change first:

[server]
name = "My KCD:MP server"   # what players see in the launcher
password = ""               # "" = anyone may join
port = 7777
max_players = 32

[master]
url = "https://kcd-mp.com/server-list"   # "" = a private server

Restart the server after an edit. A server announces itself to the public list by default, so give it a password, or set url = "", while you test.

5. Open the port

Players reach the server on UDP 7777. Allow it through Windows Firewall from PowerShell, run as administrator:

New-NetFirewallRule -DisplayName "KCD:MP server" -Direction Inbound -Protocol UDP -LocalPort 7777 -Action Allow

Behind a home router, forward UDP 7777 to the PC as well. The list checks the server at the address it announces from, and a server it cannot reach is not listed. Once it is reachable it shows up on the server list and in the launcher within seconds. Behind a tunnel such as playit.gg, set public_address under [master] to the tunnel's "host:port".

6. Join it

Open the launcher with Steam running and use Direct connect: 127.0.0.1:7777 on the same PC, the PC's address on your home network, or your public address from outside. A listed server is also under Servers.

7. Give it the game's data

The server has no copy of the game, so it starts without the game's damage tables, navigation mesh, collision and terrain. The tools/ folder has an exporter for each. Run them on the PC where the game is installed, with Steam running and the game closed. They write straight into the server's data/ folder, and the next start picks the files up, with a line for each in the log. A missing file turns one feature off and nothing else.

The game's tables

KcdMp.ExportTables.exe

→ data/combat/items.json

Damage from the game's own weapon and armour numbers, and items, horses and potions by name. Run this one first.

A few seconds; the game does not start.

The guide ↗

Navigation mesh

KcdMp.ExportNavmesh.exe

→ data/navmesh/<level>.knav

NPCs that walk around walls instead of into them, and paths for a game mode.

A second per level; the game does not start.

The guide ↗

Collision

KcdMp.ExportCollision.exe

→ data/collision/<level>.kcol

Line of sight on hits and shots, the real floor under a player, rays for a game mode.

Starts the game once per level; minutes on the big ones.

The guide ↗

Terrain

KcdMp.ExportHeightmap.exe

→ data/heightmaps/<level>.hmap

The terrain check: a player far under or over the ground is pulled back.

Starts the game once per level; about a minute each.

The guide ↗

The per-level tools do all three levels unless you name one (--level klaster), and every tool lists its options with --help. A server on Linux gets the files copied into its own data/ folder.

8. Pick a game mode, make yourself admin

[gamemode] script in server.toml picks the mode. The ones that ship are in gamemodes/, free roam unless you pick another, and /reload in the chat reloads it without a restart. The server's own commands (/give, /tp, /time, /weather, /kick and the rest) answer admins only; the free roam mode makes admins of the names in KCDMP_ADMINS. From PowerShell in the server folder:

$env:KCDMP_ADMINS = "YourName"; .\KcdMp.Server.exe

Official hosting partners

Or let a host run it

Skip the steps above: these hosts run the KCD:MP server for you. Pick a plan and a game mode, and your server shows up in the launcher's list like any other. Every server rented through them supports the project.

Our hosting partners support KCD:MP: renting a server through these links helps fund the project.

Go further: the scripting docs

The scripting docs have the whole of it, Linux included, and everything you need to write a game mode of your own in Lua or C#: