Every Don't Starve Together console command worth typing — god mode, spawning, health and sanity, season and time, plus the server-admin set. Two things first, because they trip everyone up: you switch the console on in a file, and you have to watch the Remote vs Local toggle or your command quietly does nothing. Both are below.
client.ini, press ~ in-game, and make sure the box reads REMOTE for anything that touches the world (Ctrl toggles it).Switch it on: open Documents\Klei\DoNotStarveTogether\client.ini (not settings.ini — that's the single-player game's file) and under [MISC] set console_enabled = true.
Open it in-game: press ~ (tilde / backtick). Rebindable in the controls menu.
Remote vs Local — the part everyone misses. The console shows a label on the left: REMOTE (runs on the server — world, spawning, other players) or CLIENT (just you). Ctrl toggles it. If you're not the host, world / spawn / god commands have to go in REMOTE mode.
REMOTE / CLIENT label before you hit enter — Ctrl flips it, and pasting a command can flip it for you. Caves are a separate shard, so map-reveal and timed bans must be run on both the surface and caves servers. And stat commands take fractions: c_sethealth(0.5) is 50%, not 50.Type to filter, hit Copy, paste in-game. 34 commands. Placeholders in [brackets] are values you fill in.
| Command | What it does | Category |
|---|---|---|
| c_freecrafting() | Unlock crafting of everything (creative). Toggle. | Setup & crafting |
| c_skip(num) | Skip [num] day-cycle segments forward. | Setup & crafting |
| c_supergodmode() | God mode AND refill all stats to full. Toggle. | Setup & crafting |
| c_godmode() | Invulnerable; no sanity/hunger/health drain when hit. Toggle. | Player — god, health, speed |
| c_sethealth(0.9) | Set health — fraction, so 0.9 = 90%. | Player — god, health, speed |
| c_setsanity(0.9) | Set sanity (fraction). | Player — god, health, speed |
| c_sethunger(0.9) | Set hunger (fraction). | Player — god, health, speed |
| c_setmoisture(0) | Set wetness (fraction). | Player — god, health, speed |
| c_settemperature(20) | Set body temperature (degrees). | Player — god, health, speed |
| c_speedmult(2) | Run-speed multiplier — base 1, so 2 = twice as fast. | Player — god, health, speed |
| c_spawn("prefab", amount) | Spawn [amount] of a prefab under your cursor. | Spawn & give |
| c_give("prefab", amount) | Put [amount] of a prefab in your inventory (codes below). | Spawn & give |
| c_countprefabs("prefab") | Count how many of that prefab exist in the world. | Spawn & give |
| c_gonext("prefab") | Teleport to the nearest instance of that prefab. | Spawn & give |
| TheWorld:PushEvent("ms_nextcycle") | Advance to the next day cycle. | World, time & season |
| TheWorld:PushEvent("ms_setphase", "day") | Set the phase — day / dusk / night. | World, time & season |
| TheWorld:PushEvent("ms_setseason", "winter") | Set the season — autumn / winter / spring / summer. | World, time & season |
| TheWorld:PushEvent("ms_forceprecipitation", true) | Start (true) or stop (false) the rain. | World, time & season |
| TheSim:SetTimeScale(2) | Game speed — 1 = normal, 0 = pause, >1 faster. | World, time & season |
| LongUpdate(120) | Fast-forward the world simulation by [n] time units. | World, time & season |
| c_save() | Force an immediate world save. | Server & admin |
| c_shutdown(true) | Shut down the server — true saves first, false doesn't. | Server & admin |
| c_reset() | Reload the world WITHOUT saving. | Server & admin |
| c_rollback(count) | Roll back [count] saves. | Server & admin |
| c_announce("text") | Broadcast a server message. | Server & admin |
| TheNet:Kick(userid) | Kick a player. | Server & admin |
| TheNet:Ban(userid) | Ban a player. | Server & admin |
| TheNet:BanForTime("KU_id", seconds) | Temp-ban — run on both shards on a caves+surface server. | Server & admin |
| c_listallplayers() | List connected players with their usernames + index. | Player targeting |
| UserToPlayer("PlayerName") | Get a player object by name. | Player targeting |
| AllPlayers[1]:PushEvent("death") | Kill the n-th player (index from the list). | Player targeting |
| AllPlayers[1]:PushEvent("respawnfromghost") | Resurrect the n-th player. | Player targeting |
| c_move(AllPlayers[1]) | Teleport that player to your cursor. | Player targeting |
| c_despawn(AllPlayers[1]) | Despawn that character. | Player targeting |
Use these with c_spawn or c_give. The console auto-suggests prefab names as you type, so you don't need to memorise them.
| ID | Item | Category |
|---|---|---|
| log | Log | Resources |
| twigs | Twigs | Resources |
| cutgrass | Cut Grass | Resources |
| flint | Flint | Resources |
| rocks | Rocks (stone) | Resources |
| goldnugget | Gold Nugget | Resources |
| cutreeds | Cut Reeds | Resources |
| nightmarefuel | Nightmare Fuel | Resources |
| charcoal | Charcoal | Refined materials |
| rope | Rope | Refined materials |
| boards | Boards | Refined materials |
| cutstone | Cut Stone | Refined materials |
| gears | Gears | Refined materials |
| beefalowool | Beefalo Wool | Refined materials |
| silk | Silk | Refined materials |
| thulecite | Thulecite | Refined materials |
| meat | Meat | Food & misc |
| smallmeat | Morsel | Food & misc |
| monstermeat | Monster Meat | Food & misc |
| berries | Berries | Food & misc |
| carrot | Carrot | Food & misc |
| seeds | Seeds | Food & misc |
| healingsalve | Healing Salve | Food & misc |
| gunpowder | Gunpowder | Food & misc |
Tip: typing in the console auto-guesses prefab names, so a half-remembered code usually still works.
Documents\Klei\DoNotStarveTogether\client.ini and under [MISC] set console_enabled = true, then press ~ in-game. Note it's client.ini — settings.ini is the single-player game's file and won't do anything.REMOTE runs the command on the server — the world, spawning, other players. CLIENT (local) only affects you. Ctrl toggles between them, and pasting can flip it without you noticing, so check the label first. If you're not the host, world and spawn commands need REMOTE.c_spawn("prefab", amount) drops it at your cursor; c_give("prefab", amount) puts it in your inventory — e.g. c_give("log", 20). Use the prefab code (full list above); the console auto-suggests names as you type.REMOTE. Two more: health/sanity/hunger take fractions (0.5 = 50%, not 50), and temporary states like god mode clear on a world reload, so re-enter them after.Console open? Here's the rest of the toolkit.