
Changing Game Mode on Your Minecraft Server
Switch between survival, creative, adventure, and spectator modes for individual players or the whole server.
Changing a Player's Game Mode
/gamemode [mode] [player] - Changes the game mode for a specific player. If you omit the player name, it changes your own game mode.
Modes: survival, creative, adventure, spectator - written out in full. Java Edition no longer accepts shorthand such as s, c, a or sp.
Examples: /gamemode creative PlayerName, /gamemode survival @a (sets all players to survival).
You need operator permission level 2 or higher to use this command.
Setting the Default Game Mode
/defaultgamemode [mode] - Sets the default game mode for new players joining the server. Existing players are not affected.
The same thing is the "gamemode" setting in the Settings tab (default survival). That is written to server.properties, which Minecraft reads at startup, so it lands on the next restart - whereas the command works immediately.
If force-gamemode is true (Settings, default false), every player is put into the default game mode each time they join, overriding per-player changes.
Game Mode Descriptions
Survival: Players gather resources, craft, take damage, and manage hunger. The standard Minecraft experience.
Creative: Players have infinite resources, can fly, and cannot die. Good for building projects and testing.
Adventure: Players can interact with the world (buttons, levers, chests) but cannot break or place blocks unless the item they hold has the can_break / can_place_on component (the CanDestroy/CanPlaceOn tags of older versions). Used for custom maps.
Spectator: Players are invisible, can fly through blocks, and cannot interact with the world. Useful for admins observing players or for watching events.
Permission Levels
The /gamemode command requires OP permission level 2 or higher. op-permission-level is in the Settings tab and defaults to 4; set it to 1 and your operators will not be able to change game modes.
For servers that want to give players creative mode without full OP, a permissions plugin or mod like LuckPerms can grant minecraft.command.gamemode to specific players or groups. LuckPerms comes as a Paper plugin and as a Fabric, Forge or NeoForge mod, so this route works on every server type except Vanilla - check it has a build for your Minecraft version. On Vanilla the four OP levels are all there is.
This is the recommended approach for survival servers that want to give trusted builders creative access without full admin powers.