Grant Operator Status to Players
The /op command is used in Minecraft Java Edition to grant operator status to one or more players on a server. You need permission level 3 (Server admin) to run this command.
Server administrators use this command when they want to give trusted friends or staff members access to administrative privileges. It accepts either an exact player name or a target selector that matches players.
/op <targets>/op <targets>| Argument | Type | What it means |
|---|---|---|
<targets> | player | Specifies the player name or a target selector that matches the players who will receive operator status. |
/op SteveGrants operator status to the player named Steve.
/op @pGrants operator status to the nearest player.
/op @rGrants operator status to one random player currently online.
/op @aGrants operator status to all players currently on the server.
/op @sGrants operator status to the player executing the command.
/op @a[distance=..10]Grants operator status to all players within a 10-block radius.
/op @a[team=Admins]Grants operator status to all players who are on the Admins team.
/op @a[tag=moderator]Grants operator status to all players who have the moderator tag.
Measured from the game files of every Java release from 1.13 to 26.3.
Bedrock Edition also includes the /op command, where it uses the syntax /op <player: target> to grant operator status to a target player.
You need permission level 3, which is for server admins, to run the /op command in Minecraft Java Edition.
Yes, the <targets> argument accepts both direct player names and any target selector that matches players.
The /op <targets> command has been available in every Java Edition release from version 1.13 up to version 26.3.
/ban/ban-ip/banlist/datapack/deop/fetchprofile/kick/list/pardon/pardon-ip/publish/reload/save-all/save-off/save-on/setidletimeout