Ender Dragon

The ender dragon is a versatile, flying boss mob found in the End, and is the first boss added to Minecraft.

Initial spawning
A single ender dragon spawns naturally in the End, immediately as the first player enters the dimension. It will spawn on any difficulty, including Peaceful, but will be unable to directly harm a player with its body in Peaceful difficulty (although it will still fire fireballs).

Respawning
Players can re-spawn the ender dragon once the fight is completed, by placing four (or fewer) end crystals atop the exit portal, one on each side.

Commands
The command, by default, summons a harmless ender dragon that hovers in place. Setting the  tag (for instance by issuing ) will create a normal ender dragon, but it will have no health bar since the bar is managed by the End's dragon fight status rather than by the dragon entity itself. If spawned away from the center of the map (X:0, Z:0), the dragon will first fly to the center before resuming normal behavior (see ).

Drops
Once defeated, the ender dragon will slowly ascend and begin to appear tattered, while having beams of light spontaneously erupting from its body. It will then explode and drop 12,000 experience (10 drops of 960 experience, one drop of 2400), enough to bring a player from level 0 to level 78. Subsequent ender dragons (ones re-spawned via the end crystals) only drop 500 experience.

It will also activate the exit portal, and drop a dragon egg onto the top. This portal is found at X=0 and Z=0 on the surface of the island. The dragon egg is only dropped by the first dragon, and never by subsequent dragons.

Every dragon kill will also create an End gateway portal within 75-100 blocks of the exit portal, up to a maximum of 20.

Behavior


The dragon has four main states of behavior:


 * Circling - the dragon begins in this state. When circling, the dragon will circle outside the ring of pillars if end crystals remain, or inside the ring of pillars if not. As crystals are destroyed, the chances of it switching to another state are increased.
 * Strafing - the dragon will fly towards a target player within 64 blocks of the portal. When it is within 64 blocks, it will fire a fireball and resume circling. If a player destroys an end crystal, the dragon will immediately switch to this state to fire a fireball at them.
 * Diving - the dragon will fly rapidly towards the target player's position at the start of the dive, then resume circling whether or not the player was actually hit.
 * Perching - the dragon flies towards the empty portal (approaching from the side opposite the player if possible) and lands on the highest block of (X:0,Z:0). The dragon is immune to arrows in this state; any arrows that hit the dragon will bounce off and be on fire. After 1.25 seconds, if a player is within 20 blocks of the portal, the dragon will roar and use its breath attack for 3 seconds, damaging players similarly to a lingering Potion of Harming. If no player is near the portal within 5 seconds, the dragon will charge at a player within 150 blocks. After four consecutive breath attacks, or if it does not find a player within 150 blocks, the dragon will take off and begin circling again. If cumulative damage taken while perched exceeds, it will take off and reset the damage accumulator. The accumulator is not reset if the dragon does not take enough damage.

The purple clouds emitted from the ender dragon's breath attack can be collected in an empty bottle to obtain Dragon's Breath.

Whenever the dragon finds itself less than 10 blocks or greater than 150 blocks to its current target, it will attempt to choose a new target. When damaged it will target a point just behind itself, causing it to turn away and choose a new target.

The dragon is not hostile towards any other entities except the player. However, other mobs may turn hostile to the ender dragon if struck. Any entities hit by the dragon's wings will be dealt damage ( damage if hit by its head) and thrown into the air, sometimes to fatal heights or even off the island. Neither of these effects are applied for $1/2$ second after the dragon takes damage.

If it takes fatal damage, the ender dragon will fly to within 10 blocks of the portal before actually dying, unless it is over 150 blocks away or inside blocks. When the dragon is respawned, a series of explosions resets the obsidian pillars, iron bars, and end crystals.

The dragon can pass through all blocks, destroying most types. Blocks not destroyed are those that naturally generate on the central End island and those that are intended to be indestructible:
 * Command Block
 * End portal (block)
 * End gateway (block)
 * Command Block
 * End portal (block)
 * End gateway (block)
 * End portal (block)
 * End gateway (block)
 * End gateway (block)



The ender dragon has a light purple health bar that appears at the top of the player's screen. Its health is periodically healed by nearby end crystals, indicated by a white beam connecting the dragon and the crystal. Destroying an end crystal while the ender dragon is being healed by it will cause the ender dragon to take damage. The ender dragon can only take damage from explosions and player based damage. The ender dragon takes $1/4$ normal damage when hit in any part that is not its head. Suffocation cannot be used, as the ender dragon will destroy most blocks it comes into contact with and doesn't take suffocation damage otherwise.

By using the shortcut, the dragon's bounding box appears, though the dragon cannot be damaged at just any spot in this large volume. Eight green hitboxes also appear, which indicate the locations on the dragon where it can be damaged: the tail, body, head and wings.

Dragon fireball
Dragon fireballs are special fireballs that the ender dragon shoots while strafing. They cannot be deflected, and do no damage on impact, except that they emit purple clouds similar to a lingering Potion of Harming II. Like the dragon's close-ranged breath attack, the clouds emitted by dragon fireballs can also be collected in a bottle to obtain the dragon's breath. In the Console Edition, dragon fireballs come from the sky rather than the dragon itself.

Fireballs fired by ender dragons also have entity data associated with them that define various properties of the entity. Their entity ID is.

Data values
Ender dragons have entity data associated with them that contain various properties of the mob. Their entity ID is.

Trivia

 * Name tags cannot be used on an ender dragon.
 * The ender dragon's hitbox is larger than the ender dragon itself, causing players to be pushed away from it.
 * If you kill a summoned dragon in the Overworld or Nether, it will not create a portal, nor an egg.
 * In spectator mode, you cannot view the perspective of the ender dragon, unlike any other mob.
 * Using F3+B to show hitboxes reveals that the ender dragon's head rotation faces in the opposite direction to that which its real head faces. This is also why the ender dragon faces the wrong way when set in a monster spawner.
 * Ender dragons, when spawned in the Overworld, will fly to coordinates x=0 and z=0 and dive at the ground.

Notch-related

 * On Reddit, Notch referred to the ender dragon as a she, and suggested her name to be "Jean?" in the same manner he called the Player "Steve?".
 * Dinnerbone later stated that he thinks the name is officially "Jean?"
 * The Xbox avatar item 'Ender Dragon Pet' has the description 'A cuter, friendlier version of his bigger, less playful Minecraft sister.'- revealing that the ender dragon is female.
 * Before it was textured, Notch reported that he was afraid to texture it as it was a complicated model. In the end, the dragon model was so complex Notch stated that he gave up making the texture manually and wrote a texture packer tool to aid him in adding the texture to the model. Notch also uploaded the code for the tool so others could use the pack.
 * Notch joked about how Minecraft was "going next gen" when deadmau5 mentioned this.
 * Notch has uploaded a video showing why ender dragons will not spawn in the main world, as they would destroy any block they come into contact with.
 * On Reddit, Notch explained why ender dragons destroy matter.