How to Set Game Rules on Your Minecraft Bedrock Server
Configure game rules on your Minecraft Bedrock Edition dedicated server to control gameplay behavior through the XGamingServer panel.
Here is how to set game rules on your Minecraft Bedrock server. Game rules control core gameplay behavior like mob spawning, PvP, item drops on death, and more.
Requirements
Before changing game rules, you need:
- Cheats enabled - Follow our enable cheats guide
- OP permissions - Follow our adding admins guide
Changing Game Rules
Select Your Server
Log in to the XGamingServer Panel and select your Minecraft Bedrock server.
Open the Console
In the sidebar, go to Console.
Run a Gamerule Command
Type the following command and press Enter:
gamerule <rule> <value>Replace <rule> with the game rule name and <value> with true, false, or a number depending on the rule.
For example, to enable keep inventory:
gamerule keepInventory trueCommon Game Rules
Here is a list of frequently used game rules for Bedrock Edition:
| Game Rule | Values | Description |
|---|---|---|
keepInventory | true / false | Players keep items when they die |
mobGriefing | true / false | Mobs can destroy or change blocks (creepers, endermen, etc.) |
doDaylightCycle | true / false | Day and night cycle progresses |
doWeatherCycle | true / false | Weather changes over time |
doMobSpawning | true / false | Mobs spawn naturally |
pvp | true / false | Players can damage each other |
showcoordinates | true / false | Show X, Y, Z coordinates on screen |
doFireTick | true / false | Fire spreads to nearby blocks |
doImmediateRespawn | true / false | Skip the death screen and respawn instantly |
naturalRegeneration | true / false | Players regenerate health when hunger is full |
tntExplodes | true / false | TNT blocks can explode |
commandBlocksEnabled | true / false | Command blocks can execute commands |
doInsomnia | true / false | Phantoms spawn when players have not slept |
respawnBlocksExplode | true / false | Beds and respawn anchors explode in wrong dimensions |
showDeathMessages | true / false | Death messages appear in chat |
sendCommandFeedback | true / false | Command output is shown in chat |
maxCommandChainLength | number | Maximum command blocks that can chain (default: 65536) |
randomTickSpeed | number | Speed of random block ticks like crop growth (default: 1) |
playersSleepingPercentage | number | Percentage of players needed to skip the night (default: 100) |
💡 Tip: You can check the current value of any game rule by running
gamerule <rule>without a value.
📝 Note: Some game rules like
pvpandshowcoordinatesare Bedrock-exclusive and do not exist on Java Edition.
How is this guide?
How to Enable Experimental Gameplay on Your Minecraft Bedrock Server
Enable experimental features and upcoming content on your Minecraft Bedrock Edition dedicated server through the XGamingServer panel.
How to Add Behavior Packs and Addons to Your Minecraft Bedrock Server
Install behavior packs, resource packs, and addons on your Minecraft Bedrock Edition dedicated server through the XGamingServer panel.