How to install mods on a Don’t Starve Together (DST) server

Installing mods on a Don’t Starve Together dedicated server trips up more new server owners than almost anything else, and the reason is simple: there are two files involved, not one, and a mod only works when it appears in both. Get one file right and forget the other, and your mod silently does nothing. This guide walks through exactly how the system works on a self-hosted SteamCMD install, with the precise file paths and Lua syntax, so you can add, configure, and troubleshoot mods with confidence.

Don’t Starve Together server basics

Don’t Starve Together (DST) is the multiplayer co-op survival game developed and published by Klei Entertainment — the standalone multiplayer companion to single-player Don’t Starve. The Steam game (the client you play) has App ID 322330, but that is not what you install on a server. The DST dedicated server is a separate package with SteamCMD App ID 343050, installed anonymously:

login anonymous
force_install_dir /path/to/installation/directory
app_update 343050 validate

A DST server can optionally be split into two shards (worlds): a surface world called Master and an underground world called Caves, grouped together under a cluster. This shard structure matters a great deal for mods, because — as you’ll see below — each shard keeps its own copy of the file that enables mods. If you run a caves world, you’ll be editing two files instead of one.

The two-file mod system (the core idea)

Here is the single most important concept in this entire guide: DST dedicated servers use two separate files with two distinct jobs. One file downloads mods; the other enables them. Downloading a mod does not enable it, and enabling a mod that was never downloaded does nothing. A mod works only when it appears in both places.

FileJobLocation
dedicated_server_mods_setup.luaTells the server which Workshop mods to download/update on startupIn the server install mods/ folder — NOT inside the cluster
modoverrides.luaTells the server which downloaded mods to enable, plus their configurationIn each shard folder of the cluster: Master/ and Caves/

If you remember nothing else, remember this: download in one file, enable in the other, and a mod needs both. A huge share of “my mod isn’t loading” reports come down to a mod that’s listed in one file but missing from the other.

Where these files live

On a canonical self-hosted SteamCMD layout, the paths are:

  • Download file: /mods/dedicated_server_mods_setup.lua — inside the SteamCMD install directory’s mods folder.
  • Enable file(s): under your save/cluster directory, one per shard:
    • //Master/modoverrides.lua
    • //Caves/modoverrides.lua (if caves are enabled)

The save-folder root depends on your operating system: on Linux it’s ~/.klei, on Windows it’s Documents/Klei, and on macOS it’s ~/Documents/Klei.

One honest caveat: many managed control-panel hosts (Nodecraft and others) flatten or relocate these paths inside their own panels, so the exact folder names may look different on a managed host. The two-file logic is always identical — you’ll still have a download file and a per-shard enable file — but don’t be surprised if a panel labels them differently. The paths above are the canonical self-hosted SteamCMD layout. If you’d rather skip the file-shuffling entirely, a managed Don’t Starve Together server hosting plan handles the install and exposes these files through a file manager.

File 1 — dedicated_server_mods_setup.lua (download)

This file lists the Workshop mods the server should download and keep updated. You add one line per mod using ServerModSetup, passing the numeric Steam Workshop ID as a string — the quotes are required:

ServerModSetup("378160973")  -- mod name here so you remember it
ServerModSetup("378160971")  -- Mod 1
ServerModSetup("378160972")  -- Mod 2

The function signature is ServerModSetup("") — a single string argument, the numeric Workshop ID. To pull in an entire Workshop collection at once, use ServerModCollectionSetup(""), which installs every mod in that collection:

ServerModCollectionSetup("123456789")  -- installs all mods in this collection

A few rules to keep this file working:

  • The double dash -- begins a Lua comment. Never start a mod line with --, or the server will ignore that mod entirely.
  • The server downloads and updates everything listed here automatically on startup — unless you launch it with -skip_update_server_mods.
  • This file lives only in the install mods/ folder. It is not duplicated per shard.

File 2 — modoverrides.lua (enable and configure)

Once the mods are downloaded, you have to switch them on. That’s the job of modoverrides.lua. This file returns a single Lua table keyed by workshop- — note the literal workshop- prefix and the square-bracket quoted-string key:

return {
    ["workshop-378160971"] = { enabled = true }, -- Mod 1
    ["workshop-378160972"] = { enabled = true }, -- Mod 2
    ["workshop-378160973"] = { enabled = true }  -- Mod 3 (no trailing comma on the last)
}

The formatting rules here are strict, and a single mistake can prevent the whole file from loading:

  • Each mod key is ["workshop-"] — square brackets, a quoted string, and the literal workshop- prefix.
  • Each value is a table written with curly braces { }, not parentheses.
  • Put a comma after every entry except the last one.
  • The file must return the table.

Configuring a mod’s options

Many mods expose settings — drop rates, durations, crafting modes, and so on. You set them inside the mod’s table using configuration_options:

["workshop-378160972"] = {
    enabled = true,
    configuration_options = { crafting = "normal", duration = 3500 }
}

The configuration keys must match exactly the option names defined in that mod’s modinfo.lua (specifically the data = values inside its own configuration_options). If you guess at a key name or get the spelling wrong, that setting is ignored and the mod falls back to its default. When in doubt, open the mod’s modinfo.lua in its downloaded folder and copy the exact option names.

The caves / shard rule

This is where two-shard servers catch people out. If your cluster runs both a Master and a Caves shard, you must place a modoverrides.lua in each shard folder. For mods that should affect the entire server, the same modoverrides.lua content needs to go in both Master/ and Caves/. Put it in only one shard, and the mod will be active only in that world — for example, a mod enabled in Master/ but missing from Caves/ won’t run underground.

The simplest reliable approach: get your modoverrides.lua exactly how you want it, then copy that identical file into both shard folders. Note that enabling caves itself — the shard_enabled = true setting in cluster.ini plus a matching cluster_key/token — is a separate topic from mods; this guide assumes your caves shard is already set up.

End-to-end workflow

Putting it all together, here’s the full process from start to finish:

  1. Find the Workshop IDs. Open each mod’s Steam Workshop page; the numeric ID is the number at the end of the URL, after ?id=.
  2. Add download lines. Add a ServerModSetup("") line per mod (or one ServerModCollectionSetup("") for a whole collection) to mods/dedicated_server_mods_setup.lua.
  3. Start the server once so it auto-downloads the listed mods into the mods/ folder.
  4. Enable and configure. Add each mod to modoverrides.lua in Master/ (and Caves/ if you run caves) with enabled = true and any configuration_options you want.
  5. Restart the server to apply the changes.

That restart at the end is non-negotiable — DST reads these files at startup, so edits made while the server is running won’t take effect until it cycles. For a fuller walkthrough of cluster setup, shard configuration, and panel-specific file locations, see the Don’t Starve Together documentation.

Troubleshooting common mod problems

The overwhelmingly common failure is a mod present in one file but not the other. Every mod enabled in modoverrides.lua should have a matching ServerModSetup() line in dedicated_server_mods_setup.lua, and vice-versa. When a mod won’t load, check these in order:

  • Both files match. Confirm the same Workshop ID appears in dedicated_server_mods_setup.lua (as ServerModSetup("ID")) and in modoverrides.lua (as ["workshop-ID"]).
  • Quotes and prefixes. The download file uses the bare numeric ID in quotes; the enable file uses the workshop- prefix inside square brackets. Mixing these up is a frequent error.
  • Comma discipline. A stray trailing comma after the last entry, or a missing comma between entries, can break the whole modoverrides.lua table.
  • Caves coverage. On a two-shard cluster, make sure the mod is enabled in both Master/ and Caves/ if it should run server-wide.
  • Curly braces, not parentheses. Mod values in modoverrides.lua are tables — { enabled = true }, never ( enabled = true ).
  • You actually restarted. Edits only apply after a full server restart.

One more clarification worth making, because older host guides sometimes confuse it: you may see references to enabling mods via modsettings.lua or a “force enable” line. For a dedicated server, the authoritative Klei method is modoverrides.lua — that is the file you should use. The modsettings.lua force-enable mechanism is primarily a client-side tool and is not the canonical way to enable mods on a dedicated server. Stick with modoverrides.lua and you’ll be on the supported path.

Frequently asked questions

Why isn’t my mod loading even though I subscribed to it on Steam?

Subscribing in your Steam client only affects your own game, not the dedicated server. The server downloads mods exclusively from the IDs you list in dedicated_server_mods_setup.lua, and it enables them only when they’re listed in modoverrides.lua. You need both entries on the server, regardless of what you’ve subscribed to.

Do I really need to edit two different files for one mod?

Yes. dedicated_server_mods_setup.lua downloads the mod; modoverrides.lua enables and configures it. Downloading alone does not turn a mod on, so a working mod must appear in both files.

Where do I find a mod’s Workshop ID?

Open the mod’s Steam Workshop page and look at the URL — the numeric ID is the number after ?id=. That’s the value you pass to ServerModSetup("...") and the same number you use in the ["workshop-..."] key.

How do I add a whole collection of mods at once?

Use ServerModCollectionSetup("") in dedicated_server_mods_setup.lua to download every mod in a collection. You still enable each one individually in modoverrides.lua with its own ["workshop-"] = { enabled = true } entry.

Do mods need to be in both the Master and Caves folders?

If your cluster runs both shards and you want a mod active across the whole server, yes — the same modoverrides.lua content must be in both Master/ and Caves/. A mod is only active in the shard where it’s enabled.

How do I change a mod’s settings, like drop rates or durations?

Add a configuration_options = { ... } table inside that mod’s entry in modoverrides.lua. The keys must match exactly the option names defined in the mod’s modinfo.lua; otherwise the setting is ignored and the default is used.

Ready to play?

Run your own Don't Starve Together server with XGamingServer

Spin up an always-on Don't Starve Together server your friends can join in minutes — no port-forwarding, no tech headaches.

99.9%Uptime SLA
< 5 minInstant setup
24/7Human support
DDoSProtected
Instant setup Your server is live in minutes with a one-click control panel.
Mods & plugins Install mods, plugins and workshop content in a few clicks.
DDoS protected Enterprise DDoS mitigation keeps your server online 24/7.
Low-latency hardware Premium CPUs & NVMe SSDs for lag-free multiplayer.
Free backups Automatic backups so your world is never lost.
Real human support Gamers helping gamers — 24/7, no bots, no scripts.

Pick your Don't Starve Together plan & play in minutes

See all plans
Starter $8.40/mo 4 GB RAM Renews $12/mo Buy now
Rookie $17.50/mo 8 GB RAM Renews $25/mo Buy now
Pro $24.50/mo 12 GB RAM Renews $35/mo Buy now