PC Don’t Starve Cheat Codes & Tips
Updated June 9, 2024 at 1:33 pm
Discover essential cheat codes and practical tips to enhance your survival skills in Don’t Starve on PC. This guide will help you navigate the game more efficiently and overcome common challenges.

Understanding Cheat Codes in Don’t Starve
You might be playing “Don’t Starve” and feel the need for some extra help to make your gameplay more enjoyable. Sometimes, the game can get particularly challenging, and that’s where cheat codes come in handy. Cheat codes allow you to unlock certain features or gain advantages that can help you progress further in the game.
How to Use Cheat Codes in Don’t Starve
First, let’s walk through how you can use cheat codes in “Don’t Starve”. To enable cheats in the game, you need to modify the “settings.ini” file located in the game’s install directory. Open this file and change the line “ENABLEDEBUGCONSOLE = true”. Save the file, and you can now open the console in-game by pressing the tilde (~) key.
God Mode
One of the most popular cheat codes is God Mode, which makes your character invincible.
To activate God Mode, open the console and type:
- GetPlayer().components.health:SetInvincible(true)
This code ensures that your character cannot take any damage.
Spawning Items
If you need specific items, you can spawn them instantly using cheat codes. Here are some examples:
To spawn 10 pieces of Flint, type:
- for i=1,10 do c_spawn(‘flint’) end
For spawning 5 Logs, type:
- for i=1,5 do c_spawn(‘log’) end
These commands can be particularly useful when you’re running low on essential resources.
Changing the Weather
If you’re struggling with the harsh in-game weather, you can use cheat codes to change it. To start or stop rain, use the following commands:
To start rain:
- TheWorld:PushEvent(‘ms_forceprecipitationstart’)
To stop rain:
- TheWorld:PushEvent(‘ms_forceprecipitationend’)
Adjusting the weather can significantly affect your survival strategy.
Teleportation
Need to get somewhere fast? You can teleport to any location instantly using teleportation cheat codes. To teleport, use the following command and replace “X” and “Y” with your desired coordinates:
- c_goto((X,Y))
Instantly Build Structures
Creating structures instantly can save a lot of time. Here is how you can build specific structures quickly:
To build a Science Machine, type:
- c_spawn(‘researchlab’)
To create a Campfire, use:
- c_spawn(‘campfire’)
Restoring Health and Hunger
It’s easy to run low on health and hunger, but with cheat codes, you can restore these instantly:
To restore health, type:
- GetPlayer().components.health:SetPercent(1)
To refill hunger, use:
- GetPlayer().components.hunger:SetPercent(1)
Increase Sanity
Maintaining your character’s sanity is crucial. To set your sanity to full, type:
- GetPlayer().components.sanity:SetPercent(1)
Unlock All Crafting Recipes
If you’d like to have access to all crafting recipes without the need to gather materials, you can unlock them instantly:
Use the following command:
- GetPlayer().components.builder:GiveAllRecipes()
Taming Animals
Taming animals can be a fun and useful feature in “Don’t Starve”. Use the following command to tame Beefalo:
- c_select(GetWorld().animals:Find(‘beefalo’)).components.domesticatable:DeltaTame(1)
Exploring the Whole Map
Seeing the entire map can provide a significant strategic advantage. To reveal the whole map, type:
- minimap:SetAutoUncoverEnable(true)
Other Useful Commands
In addition to the codes above, here are a few more useful cheat codes:
To make time move faster, use:
- TheWorld:PushEvent(‘ms_setclocksegs’, {day=1,dusk=1,night=1})
To give your character maximum light, type:
- GetPlayer().components.sanity.dapperness = TUNING.DAPPERNESS_HUGE
Conclusion and Next Steps
The cheat codes listed can make your “Don’t Starve” experience much more enjoyable and manageable. Whether you’re looking for a little extra help or just want to explore all the game has to offer without the usual constraints, cheat codes are a fantastic option.
For additional tips on how to maximize your gaming experience, you might also find our insights on
challenging your mind with strategy games
whether you’re looking for single-player or multiplayer options. Have fun, and happy gaming!
Gaining Experience Quickly
Bumping up your experience points can help you unlock characters and features more quickly. Here’s a helpful cheat code for gaining experience:
To add a specified amount of experience points, type:
- GetPlayer().profile:GainXP(amount)
Replace “amount” with the number of experience points you want to add.
Speed Control
Want to speed up your character’s movements? This cheat code can help you move faster across the map:
To increase your character’s speed, type:
- GetPlayer().components.locomotor:SetExternalSpeedMultiplier(GetPlayer(), ‘speedy’, 2)
For slower movements, replace “2” with a value less than 1.
Spawn Bosses
If you’re up for a challenge or want to test your skills, you can spawn bosses using cheat codes:
To spawn Deerclops, type:
- c_spawn(‘deerclops’)
For summoning Dragonfly, use:
- c_spawn(‘dragonfly’)
Make sure you’re prepared for a tough fight!
Changing Game Day
If you want to skip to a specific day in the game, use the following cheat code:
To jump to Day 50, type:
- TheWorld:PushEvent(‘ms_setphase’, ‘day’)
- TheWorld.net.event_listeners.motd[1] = {day=50, phase=’day’, remainingtimeinphase=100}
Adjust the “50” to whatever day you prefer.
Immune to Temperature
Managing your character’s temperature is crucial to survival. Here’s how to adjust temperature settings:
To become immune to temperature effects, type:
- GetPlayer().components.temperature:SetTemperature(20)
Replace “20” with your desired temperature.
Immobilize Enemies
Dealing with hordes of enemies can be overwhelming. Immobilize them with this cheat code:
To freeze enemies, type:
- for k,v in pairs(Ents) do if v:HasTag(‘monster’) then v:Remove() end end
This command removes all monsters from your immediate vicinity.
Setting Game Difficulty
If you want to make your game easier or harder, you can adjust the difficulty settings with cheat codes:
To set the game to Easy mode, type:
- TheWorld:PushEvent(‘populateworld’, {mode_min = true})
This will make the game less challenging.
Mind Control
Take control of other creatures in the game using mind control cheats:
To control a nearby creature, type:
- c_select()
- c_move()
These commands allow you to control the movement of the selected creature.
Instantly Complete Achievements
If you’re looking to complete achievements quickly, use this code:
To unlock all achievements, type:
- GetPlayer().profile:UnlockEverything()
This will grant you all in-game achievements instantly.
Trigger Seasonal Events
Experience different seasons whenever you like with these cheat codes:
To change to winter, type:
- TheWorld.state.season = “winter”
For summer, use:
- TheWorld.state.season = “summer”
You can also set it to autumn or spring.
Custom Game Settings
Adjust various custom settings in the game to tailor your experience:
To change the light level, type:
- GetWorld().components.worldsettingstimer:StartTimer(‘setdarktime’, 0)
This command sets the light level to your preference.
Varying Monster Spawn Rates
Want fewer or more monsters? Adjust the spawn rates with these cheats:
To increase monster spawn rates, type:
- TheWorld.components.pain:AddPain(1)
To decrease, type:
- TheWorld.components.pain:AddPain(-1)
Exploration Enhancements
Enhance your exploration experience with handy cheater tools:
To gain access to an infinite torch, type:
- c_spawn(‘infinitorch’)
This will give you a torch that never runs out.
Advanced Survival Techniques
Take your survival techniques to the next level with advanced commands:
To double food output from harvests, use:
- GetPlayer().components.harvester:SetMultiplier(2)
This cheat increases the amount of food you receive.
Enhancing Player Abilities
Sometimes, it’s fun to enhance your character’s abilities to make gameplay more exciting. Here are a few cheat codes to refine your skills:
To increase your character’s health points beyond the usual limit, type:
- GetPlayer().components.health:SetMaxHealth(500)
For enhanced agility, you can use:
- GetPlayer().components.locomotor.groundspeedmultiplier = 2
These codes will make your character superhuman in health and speed.
Manipulating Seasons in Detail
Taking full control of the seasons in “Don’t Starve” can significantly impact gameplay. Here’s how you can customize the in-game seasons:
To set the game to a specific day in any season, type:
- TheWorld:PushEvent(“ms_setseasonlength”, {spring=15, summer=15, autumn=15, winter=15})
You now have total control over how long each season lasts, making the game tailored to your preferences.
Infinite Resource Generators
Unlimited resources can make your survival much easier. Here’s how to create infinite resource generators:
For endless wood, use:
- while true do GetPlayer().components.inventory:GiveItem(“log”) end
You can create similar loops for other resources such as rocks, twigs, and more with slight variations in the item name.
Instantly Solve In-Game Puzzles
If you’re stuck on an in-game puzzle and need a quick way out, there’s a cheat for that too:
Use this code to solve any puzzle instantly:
- TheWorld:PushEvent(“ms_resolve_puzzle”)
Feel free to experiment with other aspects you can automate to simplify gameplay further.
Efficient Item Management
Managing multiple items can be tedious. You can use cheat codes to organize your inventory efficiently:
To instantly organize your inventory, use:
- GetPlayer().components.inventory:Sort()
This cheat will sort all items in your inventory logically and efficiently.
Automating Base Building
Setting up a base can be time-consuming. Here’s how you can automate parts of this process:
For instant walls and fences around your base, type:
- for i=1,50 do c_spawn(“wall_wood”) end
This will create sturdy wood walls to protect your base from immediate threats.
Special Events and Festivals
Trigger special in-game events or festivals to make your experience more vibrant:
To start an in-game festival, type:
- TheWorld:PushEvent(“ms_startfestival”)
This command will initiate a lively festival showcasing numerous unique elements in the game.
Mastering Time Control
Controlling the time in “Don’t Starve” can lead to exciting gameplay experiences. Here’s how to manipulate time:
To speed up or slow down time, type:
- TheWorld:PushEvent(“ms_settimescale”, 2)
Replace “2” with your desired time scale multiplier for faster or slower time progression.
Crafting Unique Items
Creating unique items that aren’t easily available can add a new dimension to your game:
To craft a Telelocator Staff, use:
- c_spawn(“telelocator”)
This item is extremely useful for teleporting items and characters across vast distances.
Custom Command Experiments
Experimenting with custom commands can be fun and educational, allowing you to learn more about game mechanics:
For a dramatic increase in attack power, try:
- GetPlayer().components.combat.damagemultiplier = 10
This cheat code gives your character unparalleled combat abilities, making encounters with foes virtually effortless.
Spawning Companions
Spawning companions can make your adventure less lonely and more protected:
To spawn friendly pigs to assist you, type:
- c_spawn(“pigman”, 5)
This command will give you five Pigmen companions who can aid you in various tasks and battles.
In-Depth Customization
Detailed customization provides unique gameplay tailored to your preferences:
To customize both your character’s appearance and wardrobe, type:
- GetPlayer().components.skinner:SetSkin(“skin_id”)
Replace “skin_id” with your preferred skin identifier for a unique look.
Utilizing these cheat codes can make your Don’t Starve experience much more manageable, enjoyable, and customized to your liking. By understanding and implementing these codes, you can tackle challenges more effectively and explore elements of the game you might not otherwise experience.

Avery Ingram
Contributor