/gamemode command
The /gamemode command changes a player's game mode. There are four modes: Survival, Creative, Adventure and Spectator. It's one of the first commands every player learns.
Syntax
Java and Bedrock Edition
/gamemode <mode> [player] Parameters in <angle brackets> are required. Parameters in [square brackets] are optional.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| mode | survival|creative|adventure|spectator | Yes | The game mode to set. Java takes the full names (older versions also accepted the numbers 0-3). Bedrock takes the full names, abbreviations (s/c/a) or numbers (0-2, no spectator). |
| player | selector/player | No | The player whose game mode changes. Defaults to whoever runs the command. |
Usage examples
Tips and tricks
Spectator mode is only available in Java Edition. In Bedrock you have Survival, Creative and Adventure.
Switching to Creative gives you the full Creative inventory without removing the items you already have. When you switch back to Survival, you keep the items you took in Creative.
In Adventure mode, players can't break blocks unless they're holding an item with the CanDestroy tag. Perfect for adventure maps.
On servers you can switch modes quickly with a shortcut: /gm 1 (if the server supports Essentials/CMI shortcuts).
Related commands
Frequently asked questions
How do you use the /gamemode command in Minecraft?
Open the chat with the T or / key and type the command using this syntax: /gamemode <mode> [player]. The /gamemode command changes a player's game mode. There are four modes: Survival, Creative, Adventure and Spectator. It's one of the first commands every player learns.
What permissions does /gamemode require?
The /gamemode command requires permission level 2: Operator (OP 2). In singleplayer with cheats turned on, you automatically have full permissions. On a multiplayer server, you need operator status, which is granted with the /op command.
Does /gamemode work in Bedrock Edition?
Yes, the /gamemode command works in both Java Edition and Bedrock Edition, with similar syntax.



