Allay

The allay is a small flying wisp-like passive mob. It collects and delivers items for any player that gives it something, or any note block it hears repeatedly playing.

Pillager outposts
Allays can be found surrounding pillager outposts, confined inside dark oak cages. One to three allays can spawn in each cage.

Woodland mansion
Allays can also spawn inside jail cells within woodland mansions. one to three allays can spawn in each cell.

Behavior
The allay's luminous texture allows it to be seen clearly in the dark, although it doesn't illuminate its surroundings.

The allay wanders around until a player gives it an item with their key. The allay starts following the player, seeking out dropped versions of the same item and delivering them to its player. The allay returns to wandering around if any player takes its item back by an empty hand on it.

The allay locks onto the player that last gave it an item. It follows the player from up to 64 blocks away even if it can't see them, and it seeks items up to 32 blocks away from the player. After delivering items, it has a delay of three seconds until it can seek items again. The allay has a single inventory slot to hold a stack of items (usually 64 items) in addition to the item it got from the player. While the allay does not discern enchantments, special item names, or items in Shulkers when it seeks, it still carries such items in separate trips.

If the allay hears a note block play within 16 blocks of its location, it tries to path find to the note block and then spends 30 seconds around that particular note block, seeking items around it and returning them to it instead of its player. After 30 seconds, the allay will return to targeting its player. A vibration particle emanates from the note block and reaches the allay to indicate the allay has locked on to the note block. Note that because the allay and the note block interact via a vibration particle, placing wool between the note block and the allay can prevent this interaction.

The allay can pick up items within a radius of about 1.3 blocks from itself and drop items up to 3 blocks away from its target (either the player or a note block).

When an allay hears a jukebox playing, it performs a dance animation. If the jukebox stops playing, or if the allay gets too far away from the jukebox, it stops dancing.

The allay cannot enter water, although it attempts to gather items that are under water.

Allays cannot be harmed by their owners. If they are harmed by another source, they go into a panic state and start moving wildly in random directions. When killed, allays drop the items they were holding. If an allay dies while holding a totem of undying, it instead returns to full health and the totem is destroyed, as with any mob holding a totem of undying. Allays naturally regenerate per second if damaged.

In Java Edition, a lead or a named name tag performs the item's normal function, instead of giving it to the allay.

Allay duplication
If the allay is given an amethyst shard while dancing, it plays a small amethyst sound, makes a heart, and duplicates into another allay. After duplication, both allays have a five minute cooldown before being able to duplicate again.

ID




Entity data
Allays have entity data associated with them that contain various properties.




 * See Bedrock Edition level format/Entity format.
 * See Bedrock Edition level format/Entity format.

Trivia

 * The word "allay" means "to relieve or alleviate", contrasting the word "vex", which means "to anger or worry".
 * The allay was originally planned for the Nether Update.
 * Some previous names considered for the allay were the wisp and the pixie.
 * The reason why allay duplication uses amethyst shards is because the item is renewable, has a musical sound that fits with the allay, and it adds more value to amethyst geodes.
 * According to the "meet the allay" article on Minecraft.net, the reason why allays can be tamed by players is because they form a "magical connection" when that player gives it an item. This bond is what prevents players from accidentally harming their allay.
 * Originally, Mojang considered having allays naturally spawn within Forest biomes. However, the reason they went with Woodland Mansions was because they wanted to highlight the companionship aspect.