Gamerules control Minecraft world behaviour, such as keeping inventory after death, fire spread, daylight cycle, and mob griefing.
You need to be OP before you can change gamerules in game. Follow our OP guide if you still need to give yourself access.
Run Gamerule Commands In Game
- Join your Minecraft server in game.
- Open chat with
T. - Use this format:
/gamerule ruleName value
- To keep player inventories after death, run:
/gamerule keepInventory true
- To stop fire from spreading, run:
/gamerule doFireTick false
The Minecraft Wiki lists the available gamerules.
If you change to a different world later, set the gamerules again for that world.