Skip to main content
MC COMMANDS logoMC COMMANDS
Command Reference

Minecraft /gamerule Command

worldJavaBedrock

Enables, disables, or modifies game rules (like daylight cycle, fire damage, mob drops).

Version Compatibility

Java Edition:1.21.4 (1.13+)
Bedrock Edition:1.21.60

Command Syntax

Both Editions/gamerule <rule> [<value>]

Arguments Explained

Practical Examples

/gamerule keepInventory true

Prevents players from losing their inventory items when they die.

/gamerule doDaylightCycle false

Freezes the daylight cycle at its current time.

/gamerule randomTickSpeed 100

Speeds up block updates (e.g. crop growth, leaf decay) in Java (default is 3).

Advertisement

Important Notes

Be aware that some gamerules are exclusive. E.g. Bedrock has `commandBlocksEnabled` and `showCoordinates`, while Java has `playersSleepingPercentage` and `mobGriefing` behaves slightly differently.

Ready to build your command?

Use our interactive generator to create error-free /gamerule commands with a visual interface.

Open Command Generator
Advertisement