Using gamerules in Minecraft

Game Rules control various aspects of the game play and provide additional customization for your server. You can change the game rules in console or in game as an Op. There's a lot of other Minecraft game rules, but these are some of the more commonly used. To change these game rules, you'll need to start the command with /gamerule in game or gamerule in console.

Game Rules

Rule NameDescriptionPossible ValuesDefault ValueVersion
advance_timeWhether the day-night cycle and moon phases progress.true/falsetrue1.6+
advance_weatherWhether the weather will change.true/falsetrue1.15+
command_block_outputWhether command blocks should notify admins when they perform commands.true/falsetrue1.4+
command_blocks_workWhether command blocks should be enabled.true/falsetrue1.21.9+
drowning_damageWhether the player should take damage when drowning.true/falsetrue1.15+
elytra_movement_checkWhether the server should skip checking player speed when the player is wearing elytra. This can help with lag.true/falsetrue1.9+
entity_dropsWhether entities that are not mobs should have drops.true/falsetrue1.8+
fall_damageWhether the player should take fall damage.true/falsetrue1.15+
keep_inventoryWhether the player should keep items and experience in their inventory after death.true/falsefalse1.4+
mob_griefingWhether mobs should be able to change blocks, and whether mobs can pick up items.true/falsetrue1.4+
players_sleeping_percentageWhat percentage of players must sleep to skip the night.0-1001001.17+
pvpWhether players can damage other players.true/falsetrue1.21.9+
raidsWhether raids are disabled or not.true/falsetrue1.14+
respawn_radiusThe number of blocks outward from the world spawn coordinates that a player spawns in when first joining a server or when dying without a personal spawn point.0-?101.9+
show_avancement_messagesWhether advancements should be announced in chat.true/falsetrue1.12+
spawn_phantomsWhether phantoms can spawn in the nighttime.true/falsetrue1.16+
spawn_wandering_tradersWhether wandering traders can spawn.true/falsetrue1.15+
max_entity_crammingThe maximum number of pushable entities a mob or player can push, before taking 6♥♥♥ entity cramming damage per half-second. Setting to 0 or lower disables the rule. Damage affects Survival-mode or Adventure-mode players, and all mobs but bats. Pushable entities include non-Spectator-mode players, any mob except bats, as well as boats and minecarts.0-100241.11+

Legacy Game Rules

The following are commonly used Game Rules prior to Minecraft 1.21.11

Rule NameDescriptionPossible ValuesDefault ValueVersion
announceAdvancementsWhether advancements should be announced in chattrue/falsetrue1.12+
mobGriefingWhether mobs should be able to change blocks, and whether mobs can pick up items.true/falsetrue1.4+
disableElytraMovementCheckWhether the server should skip checking player speed when the player is wearing elytra. This can help with lag.true/falsefalse1.9+
disableRaidsWhether raids are disabled or nottrue/falsefalse1.14+
doTraderSpawningWhether wandering traders can spawntrue/falsetrue1.15+
doWeatherCycleWhether the weather will changetrue/falsetrue1.15+
doDaylightCycleWhether the day-night cycle and moon phases progresstrue/falsetrue1.6+
playersSleepingPercentageWhat percentage of players must sleep to skip the night.0-1001001.17+
keepInventoryWhether the player should keep items and experience in their inventory after deathtrue/falsefalse1.4+
spawnRadiusThe number of blocks outward from the world spawn coordinates that a player spawns in when first joining a server or when dying without a personal spawnpoint0-?101.9+
commandBlockOutputWhether command blocks should notify admins when they perform commandstrue/falsefalse1.4+
doEntityDropsWhether entities that are not mobs should have dropstrue/falsetrue1.8+
doFireTickWhether fire should spread and naturally extinguishtrue/falsetrue1.4+
fallDamageWhether the player should take fall damagetrue/falsetrue1.15+
drowningDamageWhether the player should take damage when drowningtrue/falsetrue1.15+
doInsomniaWhether phantoms can spawn in the nighttimetrue/falsetrue1.16+
maxEntityCrammingThe maximum number of pushable entities a mob or player can push, before taking 6♥♥♥ entity cramming damage per half-second. Setting to 0 or lower disables the rule. Damage affects Survival-mode or Adventure-mode players, and all mobs but bats. Pushable entities include non-Spectator-mode players, any mob except bats, as well as boats and minecarts.0-100241.11+