Gamerules control Minecraft world behaviour, such as keeping inventory after death, fire spread, daylight cycle, and mob griefing.
You need to be OP on the server before you can change gamerules in game. If you are not OP yet, follow this guide first: How to OP or de-op a player on your Minecraft server.
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
For more gamerules, see the Minecraft Wiki list here: Minecraft game rule list.
If you change to a different world later, set the gamerules again for that world.
