Floating Companion Pet Command Creation

Summon a magical floating skull companion pet that smoothly bobs up and down in mid-air while orbiting its owner and trailing sparkling particles.

Java EditionMobs & PetsEasy19 commandsTested on a real 26.2 & 26.3 server
A glowing miniature dragon head orbits an armored mannequin, leaving a trail of purple and white particles. Download the GIF Video & GIF © www.9minecraft.net

Pets & CompanionsMysticEndCutePurpleWhiteBlackServer LobbyAdventure MapDecorationBlock displaysItem displaysArmor standsSmooth animation (interpolation)Rotation math13-20 commands

This command creation adds a floating companion pet to Minecraft Java Edition without using any mods or resource packs. In the demonstration, an armored mannequin stands in for the player while a miniature glowing dragon head orbits around their shoulders, bobbing smoothly up and down using display entity interpolation.

As the companion glides through the air, it leaves a colorful trail of amethyst dust, end rod sparkles, and swirling enchant glyphs. Because it uses a lightweight item_display entity paired with an invisible armor stand anchor, the motion stays silky smooth without causing lag.

1. Setup - type these once 6 commands

  1. /scoreboard objectives add c9_timer dummy
  2. /summon armor_stand ~ ~ ~ {Tags:["c9_actor","c9_clean"],ShowArms:1b,NoBasePlate:1b,CustomName:'{"text":"Pet Owner","color":"aqua"}',CustomNameVisible:1b,equipment:{head:{id:"minecraft:golden_helmet"},chest:{id:"minecraft:diamond_chestplate"},legs:{id:"minecraft:diamond_leggings"},feet:{id:"minecraft:diamond_boots"},mainhand:{id:"minecraft:amethyst_shard"}}}
  3. /summon armor_stand ~ ~1.6 ~ {Tags:["c9_pet_anchor","c9_clean"],Invisible:1b,NoGravity:1b,Marker:1b}
  4. /summon item_display ~ ~1.6 ~ {Tags:["c9_pet","c9_clean"],item:{id:"minecraft:dragon_head"},Glowing:1b,glow_color_override:11141375,teleport_duration:2,interpolation_duration:15,transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[0f,0.1f,0f],scale:[0.55f,0.55f,0.55f]}}
  5. /summon block_display ~ ~1.6 ~ {Tags:["c9_pet_halo","c9_clean"],block_state:{Name:"minecraft:amethyst_cluster"},teleport_duration:2,interpolation_duration:15,transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.15f,0.45f,-0.15f],scale:[0.3f,0.3f,0.3f]}}
  6. /scoreboard players set #tick c9_timer 0

2. Loop - one repeating command block each (Always Active) 13 commands

  1. /scoreboard players add #tick c9_timer 1
  2. /execute if score #tick c9_timer matches 31.. run scoreboard players set #tick c9_timer 1
  3. /execute as @e[tag=c9_actor] at @s run tp @s ~ ~ ~ ~2 ~
  4. /execute as @e[tag=c9_pet_anchor] at @s run tp @s ~ ~ ~ ~4.5 ~
  5. /execute at @e[tag=c9_pet_anchor] rotated ~ 0 positioned ^ ^ ^1.4 run tp @e[tag=c9_pet] ~ ~ ~ ~ ~
  6. /execute at @e[tag=c9_pet_anchor] rotated ~ 0 positioned ^ ^ ^1.4 run tp @e[tag=c9_pet_halo] ~ ~ ~ ~ ~
  7. /execute if score #tick c9_timer matches 1 as @e[tag=c9_pet] run data merge entity @s {start_interpolation:0,interpolation_duration:15,transformation:{left_rotation:[0f,0f,0.08f,0.996f],right_rotation:[0f,0f,0f,1f],translation:[0f,0.35f,0f],scale:[0.55f,0.55f,0.55f]}}
  8. /execute if score #tick c9_timer matches 16 as @e[tag=c9_pet] run data merge entity @s {start_interpolation:0,interpolation_duration:15,transformation:{left_rotation:[0f,0f,-0.08f,0.996f],right_rotation:[0f,0f,0f,1f],translation:[0f,-0.15f,0f],scale:[0.55f,0.55f,0.55f]}}
  9. /execute if score #tick c9_timer matches 1 as @e[tag=c9_pet_halo] run data merge entity @s {start_interpolation:0,interpolation_duration:15,transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.15f,0.65f,-0.15f],scale:[0.3f,0.3f,0.3f]}}
  10. /execute if score #tick c9_timer matches 16 as @e[tag=c9_pet_halo] run data merge entity @s {start_interpolation:0,interpolation_duration:15,transformation:{left_rotation:[0f,0f,0f,1f],right_rotation:[0f,0f,0f,1f],translation:[-0.15f,0.15f,-0.15f],scale:[0.3f,0.3f,0.3f]}}
  11. /execute at @e[tag=c9_pet] run particle end_rod ~ ~0.1 ~ 0.1 0.1 0.1 0.01 1 force
  12. /execute at @e[tag=c9_pet] run particle dust{color:[0.75,0.25,1.0],scale:1.2} ~ ~ ~ 0.15 0.15 0.15 0 2 force
  13. /execute at @e[tag=c9_pet] run particle enchant ~ ~0.2 ~ 0.2 0.2 0.2 0.5 3 force

How it works

Frames from the test run

Floating Companion Pet Command Creation - frame 1Floating Companion Pet Command Creation - frame 2Floating Companion Pet Command Creation - frame 3

Recorded on our own test server: 50 frames at about 9.9 fps. Our image check saw: A miniature glowing dragon head orbits an armored stand, leaving a trail of white and purple particles, though the stand's nametag displays raw JSON code.

Commands, video and screenshots: tested and recorded by www.9minecraft.net © 9Minecraft. Sharing a video or screenshot? Please credit www.9minecraft.net.

Build it in your world

  1. Open chat in a Creative world with cheats enabled and run each command from the Setup list one by one.
  2. Notice the armored stand and the miniature glowing dragon head appear above the center block.
  3. Place a line of 13 Repeating Command Blocks (or 1 Repeating followed by 12 Chain Command Blocks) nearby.
  4. Set all of the command blocks to Always Active.
  5. Paste one command from the Loop list into each command block in order.
  6. Watch the companion pet smoothly bob up and down while orbiting the stand and trailing sparkles.
  7. To customize the pet's look, replace <code>minecraft:dragon_head</code> in setup command 4 with <code>minecraft:player_head</code> or any custom head item.

Use it with real players

To make the floating companion follow you instead of the demo armor stand, skip the second setup command (which summons c9_actor) and add one extra repeating command block to your loop: /execute at @p run tp @e[tag=c9_pet_anchor] ~ ~1.5 ~ ~4.5 ~. This locks the rotating anchor right above the nearest player's shoulders so the bobbing pet orbits you wherever you walk.

Remove it again 2 commands

  1. /kill @e[tag=c9_clean]
  2. /scoreboard objectives remove c9_timer

FAQ

How do I change the dragon head into a custom player skull?

In the fourth setup command, change item:{id:"minecraft:dragon_head"} to item:{id:"minecraft:player_head",components:{"minecraft:profile":{name:"Notch"}}} using any Minecraft username or profile texture you like.

Why does the pet move so smoothly compared to normal armor stands?

It uses an item_display entity with teleport_duration set to 2 and interpolation_duration set to 15. Minecraft automatically blends the vertical movement and orbital movement across frames on the client side.

Commands used

/data/execute/particle/scoreboard/summon/tp

Similar creations

Join 9Minecraft News & Guides