The reliable way to host a Don’t Starve Together dedicated server is to run a Linux x86_64 VPS with Docker, keep the Klei data directory on a persistent host path, and pass the game’s UDP ports through both Docker and your firewalls. Start with roughly one CPU core, 1 GiB of RAM plus about 60 MiB for each active player, and 4 GiB of free disk. A single Master shard normally listens on UDP 10999; a Caves shard needs its own port, such as UDP 11000.
Need a server to try this on? Antihost offers Linux VPS plans with NVMe storage, full root access and a 14-day free trial.
The container itself is disposable. Your cluster settings, token, world saves and logs survive replacement only when the host’s DoNotStarveTogether directory is mounted read-write at /data. The procedure below covers cluster creation, port exposure, first launch, updates, backups and the failures that most often make a server invisible or reset its world.
As an Amazon Associate I earn from qualifying purchases.
Windows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallOutdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware matchWhat you are building
A Dockerized DST server has four layers:
- VPS: a publicly reachable Linux machine with an x86_64/amd64 CPU, persistent storage and a configurable firewall.
- Docker: runs the dedicated-server image and maps UDP traffic into the container.
- Klei cluster data: the downloaded cluster configuration, token, shard settings, saves and logs, stored outside the container layer.
- Network path: the same UDP numbers must be permitted by the VPS firewall, any cloud firewall and Docker’s published ports.
When a player joins, Steam discovery and authentication reach the VPS, the game connects to the Master server, and the Master redirects the player to another shard when necessary. A missing or translated UDP port can therefore look like a game or mod problem even though the container is running.
Baseline VPS specification
The Docker image maintainer’s small-server baseline is a starting recommendation, not a capacity guarantee. Mods, caves, world size, simulation load and the number of simultaneous players can raise resource use.
#1 Best Overall
- Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
- Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
- Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
- Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
- 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.
| Resource | Starting point | How to interpret it |
|---|---|---|
| CPU | 1 core | Suitable as a small-server starting point; reserve additional headroom for larger or heavily modded worlds. |
| Memory | 1 GiB + approximately 60 MiB per active user | The figure is the image README’s rule of thumb. Leave operating-system and Docker overhead rather than allocating every megabyte to the game. |
| Disk | 4 GiB available | Covers a small installation and initial saves. Backups, logs, workshop content and several worlds require more. |
| CPU architecture | Linux x86_64/amd64 | Use a VPS offering that matches the image architecture; ARM instances are not covered by this procedure. |
| Addressing | Publicly reachable IP address | A private-only VPS cannot accept ordinary Internet players without an additional reachable network layer. |
| UDP policy | Configurable inbound and outbound UDP | Some providers restrict game traffic. Confirm that multiple UDP ports can be opened before ordering. |
Ports you must expose
Klei’s default game server port is UDP 10999. Every server in a multi-level cluster must use a different server port. The common two-shard example assigns UDP 10999 to Master and UDP 11000 to Caves.
| Purpose | Typical UDP port | When it is needed |
|---|---|---|
| Master game server | 10999 | Always for the standard single-shard or Master server. |
| Caves game server | 11000 in the example | Required when the cluster includes a Caves shard; choose a different free port if your configuration uses another value. |
| Steam authentication | 8766 by default | Use the value configured for the server’s steam_authentication_port. |
| Steam master-server communication | 27016 by default | Use the value configured for steam_master_server_port. |
| LAN listing range | 10998–11018 | Klei documents this range for LAN visibility. Internet discovery still depends on the relevant external UDP paths. |
Publish every port that the selected image and your cluster configuration require. Keep the external number equal to the internal number. For example, mapping external UDP 12000 to container UDP 10999 can prevent discovery or break the Master-to-Caves redirect, even though Docker reports the container as healthy. Do not assume that opening only 10999 is sufficient for a Caves cluster.
Free tools Windows power users keep installed
One-click scans. No signup required.
Three separate firewall checks
- Cloud firewall or security group: allow inbound UDP for the exact game, authentication and master-server ports.
- VPS firewall: allow the same numbers with your distribution’s firewall tool.
- Docker mapping: publish each port with the
/udpprotocol, not TCP.
Keep a written list of configured values. If you later change a shard’s port, change the Docker mapping and both firewall layers together.
Prepare the VPS
- Choose a Linux x86_64 VPS with a public IPv4 address, persistent disk and permission to receive UDP traffic.
- Install Docker using the package method supported by your Linux distribution. Confirm that the daemon is running and that your administrative account can invoke Docker (either through the Docker group or with
sudo). - Check the architecture with
uname -m. Anx86_64result matches the amd64 image setting used below. - Check free space with
df -h. Reserve more than the initial 4 GiB if you will retain backups or run several shards. - Create the persistent directory and restrict access to it:
mkdir -p "$HOME/.klei/DoNotStarveTogether"
The container must be able to write this directory. If the image starts but cannot install SteamCMD files or create saves, inspect ownership and permissions on the mount before changing anything else. Do not make the directory world-writable as a first response; grant write access to the container’s user according to the selected image’s documentation.
Rank #2
- 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
- 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
- Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
- 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
- What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
Create and download a Klei cluster
Cluster settings are generated through the Klei account’s Game Servers page, rather than invented inside the container. Sign in, create or configure the server, and download the settings archive. Klei’s Linux dedicated-server workflow then has you extract the cluster directory below the persistent DoNotStarveTogether path.
- Open the Klei account Game Servers page and create the cluster.
- Choose the world settings, player limit, caves option and any cluster name required by the page.
- Download the settings archive.
- Extract it so the resulting cluster directory is inside
$HOME/.klei/DoNotStarveTogether, not beside it and not only in a temporary download directory. - Keep the cluster directory name; it is used by the server’s
-clusteroption and by the container’s startup logic.
Before launching, inspect the tree. You should be able to find the cluster configuration and shard directories under the mounted Klei path. If you put the archive one level too deep, the image may start without finding the intended cluster and create a new, apparently empty world.
Place the server token safely
A public dedicated server needs a valid Klei server token. Create or obtain the token through the Klei account workflow, then place the file expected by the selected Docker project in the persisted Klei directory. The filename is server_token.txt; the Artoria2e5 project specifically warns that you must copy the file itself into the mounted folder rather than merely setting a path that exists only on your workstation.
Keep the token private. Do not paste it into a public issue, image layer, shell history shared with other administrators or a world-download archive. If you change Docker images, read that project’s current token instructions: projects can differ in the exact subdirectory they scan at startup.
Rank #3
- Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
- Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
- Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
- Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
- What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.
Run the container with persistent storage
The image README’s example mounts the host Klei directory at /data and publishes two game ports plus the Steam-related ports:
docker run -v ${HOME}/.klei/DoNotStarveTogether:/data
-p 10999-11000:10999-11000/udp
-p 12346-12347:12346-12347/udp
-e "DST_SERVER_ARCH=amd64"
-it jamesits/dst-server:latest
Use that command as an image-specific example, not as a promise that the project’s name, tag, entrypoint or port list will never change. Verify the current README for the image version you select. Most importantly, do not translate the external port numbers to unrelated values. Add or remove mappings to match your actual shard configuration and the project’s documented Steam ports.
Test in the foreground first
- Run the command in an interactive terminal so startup messages remain visible.
- Watch for SteamCMD installation, cluster discovery, token errors and shard startup messages.
- Leave the process running until the logs show that the configured server is listening.
- From a second terminal, check the published ports with
docker psand inspect recent output withdocker logs <container-name>if you assigned a name. - Attempt a connection before adding a restart policy. A foreground run makes path and permission mistakes easier to correct.
Switch to a detached service
After a successful foreground test, recreate the container in detached mode with a stable name and restart policy. Preserve the same mount and port values:
docker run -d
--name dst
--restart unless-stopped
-v "$HOME/.klei/DoNotStarveTogether:/data"
-p 10999:10999/udp
-p 11000:11000/udp
-p 12346:12346/udp
-p 12347:12347/udp
-e "DST_SERVER_ARCH=amd64"
jamesits/dst-server:latest
The exact Steam-related mappings depend on the selected image and your cluster. If the project documents a different set, follow that set while retaining the no-translation rule. A restart policy restarts the container after a daemon or VPS reboot; it does not replace a backup strategy.
Rank #4
- Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
- Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
- Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
- Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
- Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft
Configure Master and Caves shards
An overworld-only installation exposes one server port, commonly 10999. A Caves-enabled cluster has at least two servers, and each must have a unique port on the same machine. The example pair is Master 10999 and Caves 11000.
Quick wins for a faster PC:
Clear out junk files and repair common Windows errorsFree Scan →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Settings that matter
-persistent_storage_rootpoints the dedicated server at the durable Klei data root.-conf_dirselects the configuration directory used by the installation.-clusterselects the cluster directory downloaded from the Klei account page.-portsets the game server’s UDP listening port.-playerssets the maximum player count. Klei documents valid values from 1 through 64; this is a limit, not a recommendation that every VPS can support 64 players.-steam_master_server_portand-steam_authentication_portselect the Steam service ports. Klei documents defaults of 27016 and 8766 respectively.
Use the image’s supported configuration mechanism for these options. Some projects read Klei files directly, while others generate launch arguments from environment variables. Do not add flags that the image does not pass through.
Why a second shard can fail while Master works
The Master can appear online while Caves remains unreachable if the second port is not published, is blocked by one firewall, or is translated to a different external number. The Master’s redirect contains the configured shard address; a player cannot enter Caves when that address is inaccessible. Check the Caves mapping and both firewall layers before changing world files or mods.
Verify the installation
- Run
docker psand confirm the container is up rather than repeatedly restarting. - Run
docker port dstand verify every required mapping ends in/udpwith identical host and container numbers. - Read
docker logs dstfor token, permission, cluster-name and shard-port errors. - Confirm the host directory’s modification time changes when the server creates logs or saves. This proves that data is reaching the bind mount instead of remaining in the disposable container layer.
- Test from an external network, not only from the VPS itself. Local success can hide a cloud-firewall or public-address problem.
- For LAN testing, keep the server port within Klei’s documented 10998–11018 range. Internet players still need the public UDP path.
Back up and update without losing the world
Container replacement should not delete a world when $HOME/.klei/DoNotStarveTogether is mounted to /data. The mount contains cluster configuration, saves, logs and token files; the image layer is disposable. Back up the mounted directory before changing the image, Docker command or shard configuration.
Best Value
- 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
- Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
- Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
- HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
- What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.
Simple offline backup
- Tell players to leave and stop the container:
docker stop dst. - Create an archive outside the live directory, for example:
tar -czf "$HOME/dst-backup-$(date +%F).tar.gz"
-C "$HOME/.klei" DoNotStarveTogether
- Store at least one copy on separate storage. A backup on the same VPS does not protect against disk loss.
- Start the existing container again and confirm the world loads before updating.
The cited Docker projects document persistence and launch commands, but they do not promise a particular update cadence or backup service. Choose an image tag deliberately; a floating latest tag can change entrypoints, defaults or bundled server software between pulls.
Controlled image update
- Stop the server and make the backup above.
- Pull the desired image tag:
docker pull <image>:<tag>. - Remove only the container, never the mounted host directory:
docker rm dst. - Recreate it with the same
-vpath, identical UDP mappings and the intended tag. - Read the new logs and test both Master and Caves before allowing players back in.
If an update changes the image’s expected directory or token location, follow that project’s migration notes while keeping a copy of the original data tree.
Troubleshoot the common failures
The server is invisible in the browser
- Confirm the container is running and not restarting.
- Check the VPS firewall and cloud firewall for inbound UDP, not TCP.
- Compare the configured server port with the host and container sides of every Docker mapping.
- Check that the public IP belongs to this VPS and that the provider does not block game UDP.
- Test from outside the VPS network; a local listing is not proof of Internet reachability.
Players reach Master but cannot enter Caves
- Assign Caves a distinct server port, such as 11000 when Master uses 10999.
- Publish that port with
/udp. - Permit it in both firewall layers.
- Ensure the external number is the same as the configured Caves number; NAT translation can break shard redirection.
- Read both shard logs for a port collision or a cluster path mismatch.
The world resets after an image update
- Check
docker inspect dstand verify the bind mount targets/data. - Confirm the host path is the same one used before the update and contains the original cluster directory.
- Ensure the mount is read-write, not read-only.
- Check that the new container selected the same
-clustername. - Restore the pre-update archive only after stopping the server, so a running process cannot overwrite the restored files.
SteamCMD or save files report permission errors
The container user must write to the mounted directory. Inspect ownership and mode bits on the host, then apply the UID/GID or permission method documented by your image. A permission failure can prevent SteamCMD from installing updates even when the VPS has ample disk. Avoid deleting the directory: doing so removes the evidence needed to diagnose the mismatch and can destroy saves.
The container exits immediately
- Run it in the foreground and read the first error rather than repeatedly restarting it.
- Check that the architecture variable matches the VPS (
amd64for x86_64). - Verify that the cluster archive was extracted under the mounted
DoNotStarveTogetherroot. - Confirm the token filename and location required by the selected project.
- Check for a port already occupied by another DST instance.
Operational and security practices
- Use a separate, non-root administrative account for VPS access and limit SSH to trusted addresses where practical.
- Open only the UDP ports used by the cluster; do not expose Docker’s management socket or unrelated host services.
- Keep the server token readable only by the account and container process that need it.
- Monitor free disk space. World saves, logs and backups can consume the image’s 4 GiB starting allocation quickly.
- Watch memory and CPU during the busiest play periods. The 60 MiB-per-active-user figure is a sizing baseline, not a hard limit.
- Record the image tag, Docker command, cluster name, shard ports and backup location so a failed update can be reversed consistently.
- Do not enable Klei’s disabled-data-collection mode on an Internet-facing public server. Klei’s command-line documentation states that this mode restricts the server to offline operation.
Choosing more capacity
Scale the VPS when measurements show sustained pressure, not merely because the nominal player limit is high. A practical selection comparison is:
Quick Recap
| Decision factor | What to check | Why it matters for DST |
|---|---|---|
| CPU headroom | At least one dedicated or reliably available core for a small world; additional headroom for mods and multiple shards. | Simulation work can spike during world activity, and contention makes tick performance unpredictable. |
| RAM | 1 GiB plus approximately 60 MiB per active user, with operating-system reserve. | Running out of memory can kill the process or trigger swapping that feels like lag. |
| Persistent disk | More than 4 GiB when retaining backups, logs, workshop content or multiple clusters. | The mounted directory, not the container layer, is the data you must protect. |
| Public networking | Public IPv4, unrestricted required UDP and a configurable cloud firewall. | Discovery, authentication and shard redirects all depend on reachable UDP paths. |
| Port flexibility | Ability to publish several distinct UDP ports. | Master, Caves and Steam services cannot share one game port. |
| Maintenance model | Documented image updates, selectable tags and a straightforward rollback path. | Replacing an image is safe only when the persistent directory and command are reproduced accurately. |
Final launch checklist
- Linux x86_64 VPS with a public address and persistent disk.
- Docker installed and able to run the selected image.
- Cluster archive extracted below
DoNotStarveTogether. server_token.txtin the location expected by the image.- Master and Caves assigned unique UDP server ports.
- Host, cloud and Docker UDP rules aligned with those exact numbers.
- Host directory mounted read-write at
/data. - Foreground launch tested before enabling detached restart.
- External connection tested and a backup made before updates.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.
Recommended Free Tools




