How to Add Mods to a Don't Starve Together Server
Add Workshop mods to a Don't Starve Together dedicated server: ServerModSetup in dedicated_server_mods_setup.lua, then modoverrides.lua in Master and Caves.
Updated Oct 3, 2026 · 5 min read
On this page
- What you are working with
- Where the cluster folder is
- Before you start
- Step 1: Download the mods with dedicated_server_mods_setup.lua
- Step 2: Enable the mods in modoverrides.lua
- Step 3: Copy it to Caves
- Step 4: Restart and join
- The easy way to get modoverrides.lua right
- Game updates can wipe your mod list
- Common problems
- Mods on GamezServers
- FAQ
To add mods to a Don't Starve Together server, edit two files. Add ServerModSetup("378160973") for each Workshop ID to mods/dedicated_server_mods_setup.lua in the server install, which downloads the mod. Then enable it with ["workshop-378160973"] = { enabled = true } in modoverrides.lua in both the Master and Caves shard folders of your cluster, and restart. Players download the mods automatically when they join. Game updates can reset the setup file, so check it after patches.
What you are working with
| File | Job | Where it lives |
|---|---|---|
dedicated_server_mods_setup.lua |
Downloads and updates Workshop mods on start | The server install's mods folder, next to bin64 |
modoverrides.lua |
Turns mods on and holds their settings | Each shard folder: Master/ and Caves/ in your cluster |
cluster.ini |
Cluster settings, game mode, password | The cluster folder |
| Workshop ID | The mod's number | The end of its Steam Workshop address, after ?id= |
Downloading a mod does not enable it, and enabling a mod that was never downloaded does nothing. A mod works only when it is in both files.

Where the cluster folder is
| Setup | Cluster folder |
|---|---|
| Hosted from the game on Windows | Documents\Klei\DoNotStarveTogether\<number>\Cluster_1\ |
| Self hosted dedicated server on Linux | ~/.klei/DoNotStarveTogether/<cluster name>/ |
| GamezServers | DoNotStarveTogether/config/server/ |
Each cluster folder holds cluster.ini and the two shard folders, Master (the surface) and Caves.
Before you start
- Back up the cluster folder. Some mods change the world permanently.
- Check mods are marked for servers. On the Workshop, server mods say "all clients require mod" or "server only". Client only mods (like minimaps or UI) are installed by each player and do not go on the server.
- Stop the server before editing the files.
Step 1: Download the mods with dedicated_server_mods_setup.lua
Open mods/dedicated_server_mods_setup.lua in the server install folder. Add one line per mod, with the Workshop ID in quotes:
ServerModSetup("378160973")
ServerModSetup("375859599")
To add a whole Workshop collection, use its collection ID instead:
ServerModCollectionSetup("379114180")
Lines starting with -- are comments and do nothing. The server downloads and updates everything listed here each time it starts.
Step 2: Enable the mods in modoverrides.lua
Open (or create) Master/modoverrides.lua in your cluster folder:
return {
["workshop-378160973"] = { enabled = true },
["workshop-375859599"] = {
enabled = true,
configuration_options = {
language = "english",
},
},
}
The key is workshop- followed by the ID. Each entry ends with a comma. One missing bracket or comma stops the server starting entirely, it does not just skip the mod.
Step 3: Copy it to Caves
Copy the same modoverrides.lua into Caves/. Each shard reads its own copy, so a mod enabled only in Master does not run in the caves. That shows up as items that vanish or crash the shard when someone carries them underground. Keep the two files identical unless a mod's page says otherwise.
Step 4: Restart and join
Start the server and watch both shards' logs for the mods downloading and loading. In Browse Games, tick the filter for modded servers if you cannot see yours. Players download the mods when they join.
The easy way to get modoverrides.lua right
Mod settings are easy to get wrong by hand, because option names must match the mod's own modinfo.lua exactly, and a mistyped option fails silently. The game can write the file for you:
- In the game, click Host Game, create a new world, and enable and configure the mods on the Mods tab.
- Start the world once, then quit.
- Open the new cluster folder in
Documents\Klei\DoNotStarveTogether\<number>\and copyMaster/modoverrides.lua. - Upload it to both
Master/andCaves/on the server, and add the matchingServerModSetuplines.
Game updates can wipe your mod list
This is the one that confuses server owners for days. dedicated_server_mods_setup.lua sits inside the game's install folder, so when the server updates or validates its files, the update can put back the original, empty file, as described on the Klei forums. The server starts without downloading anything. Mods that were already downloaded may keep working until they need an update, then players get "Disconnected due to missing mods" when the Workshop version moves on.
modoverrides.lua lives in your cluster folder and is never touched by updates, which is why it all looks correct.
- Keep a copy of your
dedicated_server_mods_setup.luasomewhere outside the install folder. - After every game update, open it and check your
ServerModSetuplines are still there. - Restart regularly, because mods only update when the server starts.
Common problems
- Mod not loading at all: it is in only one of the two files. It needs a
ServerModSetupline and anenabled = trueentry. - Works on the surface, breaks in caves: the mod is enabled in
Master/modoverrides.luabut not inCaves/. - Server will not start after editing: a syntax error in
modoverrides.lua, usually a missing comma or bracket. - Mod settings ignored: an option name does not match the mod's
modinfo.lua. Use the in game method above. - "Disconnected due to missing mods": the server has an old version or lost its setup file. Check the file and restart so mods update.
Mods on GamezServers
On a GamezServers Don't Starve Together server, the surface and caves run together, so you edit mods/dedicated_server_mods_setup.lua and the two modoverrides.lua files in DoNotStarveTogether/config/server/Master and Caves right in the Files tab, or over the SFTP login in Settings. Press Backup before adding mods, then restart. For the cave setup itself, see how to set up a Don't Starve Together server with caves.
FAQ
Where does dedicated_server_mods_setup.lua go?
In the mods folder of the server install, next to bin64. It is part of the game files, not your cluster folder.
Do I need modoverrides.lua in both Master and Caves?
Yes. Each shard reads its own copy, so copy the same file into both folders.
Do players need to download the mods?
They download automatically when players join. Client only mods are the exception, which players install themselves.
Why did my Don't Starve Together mods stop working after an update?
The update likely reset dedicated_server_mods_setup.lua to the empty default. Add your ServerModSetup lines back and restart.
Skip the setup. Your own Don't Starve Together server.
Then $9.99/mo. Just trying it? $2.50 for 3 days