Change Player and Entity Rotation in Minecraft
The /rotate command changes the direction a player or entity is looking in Minecraft Java Edition. You can set an exact yaw and pitch angle, or make the target look directly at a block coordinate or another entity.
Map makers and server operators use this command to direct a player's camera during cutscenes or to point mobs in a specific direction without moving their position. It requires level 2 operator permissions to run.
/rotate <target> <rotation>/rotate <target> facing <facingLocation>/rotate <target> facing entity <facingEntity> [<facingAnchor>]/rotate <target> <rotation>/rotate <target> facing <facingLocation>/rotate <target> facing entity <facingEntity> [<facingAnchor>]| Argument | Type | What it means |
|---|---|---|
<target> | target selector one target | Specifies the single player or entity to rotate, using a player name, a UUID, or a target selector like @p or @s. |
<facingEntity> | target selector one target | Selects the single player or entity that the target should turn toward, using a name, UUID, or target selector. |
<facingAnchor> | anchor | Chooses whether the target looks at the other entity's eyes or feet. |
<facingLocation> | position | Defines the three X, Y, and Z coordinates for the target to look at, which can include decimals or relative ~ and ^ symbols. |
<rotation> | rotation | Sets the exact horizontal yaw and vertical pitch angles, such as 90 0. |
/rotate @s 90 0Turns the player running the command to face a yaw of 90 and a pitch of 0.
/rotate @p 180 -45Rotates the nearest player to a horizontal angle of 180 and tilts their view upward at -45.
/rotate Steve ~45 ~10Rotates the player named Steve 45 degrees horizontally and 10 degrees vertically relative to their current view.
/rotate @e[type=armor_stand,limit=1] facing 100 64 -200Makes a single armor stand turn toward the block coordinates 100, 64, -200.
/rotate Alex facing ~ ~5 ~Makes the player Alex look at a point 5 blocks above the command's execution location.
/rotate @e[type=villager,limit=1] facing entity @r eyesTurns a single villager to look directly at the eyes of a random player.
/rotate @e[type=zombie,limit=1,sort=nearest] facing entity @e[type=iron_golem,limit=1] feetForces the closest zombie to look at the feet of a single iron golem.
Measured from the game files of every Java release from 1.13 to 26.3.
The /rotate command is only available in Minecraft Java Edition, where it was added in version 1.21.2. Bedrock Edition has no command with this name.
The /rotate command was added to Minecraft Java Edition in version 1.21.2.
No, the <target> argument only accepts a single player or entity, so you must use a selector that resolves to one target.
You need permission level 2, which means you must be a server operator or have cheats enabled in a single-player world.
/advancement/attribute/damage/defaultgamemode/effect/experience/gamemode/kill/ride/spawnpoint/spectate/spreadplayers/summon/swing/teleport/tp