How to Set Game Rules on Your Minecraft Bedrock Server

Complete reference for all Bedrock Edition game rules including keepInventory, mobGriefing, PvP, coordinates, and Bedrock-exclusive rules.

Game rules control core gameplay behavior — mob spawning, PvP, item drops on death, day/night cycle, and more. Bedrock has several rules that don't exist on Java Edition.

Requirements

  • Cheats must be enabled — see Enable Cheats
  • OP permissions are needed to run gamerule commands — see OP Setup

Enabling cheats disables achievements for the world. This is permanent and cannot be reversed.

How to Change a Game Rule

Open the Console

In the XGamingServer Panel, click Console in the sidebar.

Run the command

gamerule <ruleName> <value>

For example, to enable keep inventory:

gamerule keepInventory true

Changes take effect immediately — no restart needed.

To check the current value of any rule, run it without a value:

gamerule keepInventory

Complete Game Rules Reference

RuleDefaultDescription
keepInventoryfalsePlayers keep items and XP on death
pvptruePlayers can damage each other. Bedrock-exclusive
naturalRegenerationtrueHealth regenerates when hunger is full
doImmediateRespawnfalseSkip the death screen entirely
drowningDamagetruePlayers take damage when out of air
fallDamagetruePlayers take fall damage
fireDamagetruePlayers take fire, lava, and magma damage
freezeDamagetruePlayers take damage in powder snow
respawnBlocksExplodetrueBeds and respawn anchors explode in the wrong dimension. Bedrock-exclusive
RuleDefaultDescription
doDaylightCycletrueDay and night cycle progresses
doWeatherCycletrueWeather changes over time
doFireTicktrueFire spreads to nearby flammable blocks
tntExplodestrueTNT blocks can detonate
mobGriefingtrueMobs can modify blocks (creeper explosions, enderman block pickup, ghast fireballs)
randomTickSpeed1Speed of random block ticks (crop growth, leaf decay, grass spread). Bedrock default is 1 (Java default is 3). Set to 0 to freeze all growth
doTileDropstrueBlocks drop items when broken
doMobLoottrueMobs drop items and XP when killed
doEntityDropstrueNon-mob entities (minecarts, item frames) drop items

randomTickSpeed is one of the most commonly changed rules. Setting it to 3 matches Java Edition speed. Setting it higher (like 100) makes crops grow almost instantly — useful for testing.

RuleDefaultDescription
doMobSpawningtrueMobs spawn naturally in the world
doInsomniatruePhantoms spawn when players haven't slept for 3+ in-game days
doPatrolSpawningtruePillager patrols spawn in the world
doTraderSpawningtrueWandering traders spawn periodically
playersSleepingPercentage100Percentage of online players that must sleep to skip the night. Set to 0 so a single player can skip
spawnRadius10Radius (in blocks) around the world spawn point where players may randomly spawn

These rules are Bedrock-exclusive and have no Java equivalent:

RuleDefaultDescription
showCoordinatestrueShow X, Y, Z position in the top-left corner of every player's screen
showDaysPlayedfalseShow the in-game day count on screen
showDeathMessagestrueDeath messages appear in chat
showRecipeMessagestrueToast notifications when recipes are unlocked
showTagstrueDisplay name tags above players and mobs
showBorderEffecttrueShow world border particles

showCoordinates does not require cheats to toggle — it can be changed even with allow-cheats=false. However, it does require OP or being set before the world loads.

RuleDefaultDescription
commandBlockOutputtrueCommand blocks broadcast their output to chat
sendCommandFeedbacktrueCommands show their output to the player who ran them
commandBlocksEnabledtrueCommand blocks can execute
maxCommandChainLength65536Maximum number of command blocks that can chain in a single tick
functionCommandLimit10000Maximum commands per function file per tick
doLimitedCraftingfalsePlayers can only craft recipes they've unlocked
recipesUnlocktrueRecipes unlock as players collect ingredients
projectilesCanBreakBlockstrueProjectiles can destroy certain blocks

Peaceful Building Server

gamerule pvp false
gamerule mobGriefing false
gamerule doMobSpawning false
gamerule doFireTick false
gamerule keepInventory true
gamerule showCoordinates true

Hardcore Survival

gamerule naturalRegeneration false
gamerule doImmediateRespawn false
gamerule playersSleepingPercentage 100
gamerule keepInventory false

Event / Minigame Server

gamerule pvp true
gamerule keepInventory true
gamerule doImmediateRespawn true
gamerule showCoordinates true
gamerule doDaylightCycle false
gamerule doWeatherCycle false

How is this guide?

40% Off — Limited TimeGet your Minecraft Bedrock server todayInstant setup, DDoS protection, and 24/7 support included.
Get a Server

On this page