Donkey

A donkey is a mob that can be ridden when tamed.

Java Edition
Donkeys spawn in plains and savannas in herds of 2-6. 10% of all herds spawn as donkeys, with the other 90% being horses. 20% of the individual donkeys spawn as babies.

Bedrock Edition
Donkeys spawn in plains in herds of 2-6 at light level 7 or above. 20% of the individual donkeys spawn as babies.

Appearance
Adult donkeys are 1.4 blocks wide and long, and 1.6 blocks high. Foals start at half the size of adults and get progressively bigger as they age. Unlike wolves and cats, the appearances of donkeys do not change once they have been tamed, though tamed donkeys may be differentiated by giving them equipment.

Donkeys are smaller all around than the normal horses and sport long, erect ears. Their manes do not protrude, but rather are drawn directly on the back of their heads and necks. All donkeys have gray-brown coats with darker ankles, ears, manes, and tails. Donkeys can be equipped with a simple saddle, not the full covered armor and they can also be equipped with chests to store up to 15 stacks of items.

Unlike almost all other mobs, donkeys with equipped saddles or chests do not render these when under the effect of Invisibility. This was reported as a bug, but Mojang decided not to fix it.

Drops
Upon death, donkeys drop: If equipped with a chest or saddle, they drop those items. They also drop the contents of the chest.
 * 0–2 . The maximum amount is increased by 1 per level of Looting, for a maximum of 0-5 with Looting III.
 * 1–3 experience, when killed by a player or tamed wolf.

Usage
Tamed and saddled donkeys can be used as one of the fastest animal pack of transportation in the game, although they are unable to fit through single block-wide openings. They can also be used to climb hills and jump fences, which the player can't (without a potion). They can be ridden in water up to 2 blocks deep. In deeper water, donkeys separate from the player and swim uncontrolled.

Donkeys can be equipped with chests and used as pack animals.

Donkeys can be pulled along and tied up using a lead, and can be towed, swimming behind a boat by using a lead.

Equipment


Tamed donkeys can have the following slot available:
 * Saddle Slot: For equipping a saddle.
 * An additional 15 inventory slots, provided the donkey has been equipped with a chest.

Equipment can be placed on a donkey by holding left shift and then right-clicking on the donkey, or by accessing its inventory. A donkey's inventory can be accessed by mounting the donkey and opening the player inventory or by ing and then right-clicking on the donkey. A donkey can be equipped with a chest by a chest on a donkey. The chest cannot be removed except by killing the donkey, which causes the chest and its contents to drop.

Foals cannot be equipped with anything.

Riding
Once a donkey is tamed and saddled, the player can control it with the standard directional controls,, and the mouse. The player dismounts using the control.

$$, when riding a donkey, the hunger bar is replaced by the donkey's health in survival or adventure mode.

It uses a slightly different heart texture than the player's health bar. The experience bar is replaced by the horse jump bar.

A player can use any item while riding a donkey, including drinking or throwing potions; activating doors or redstone devices; using chests, crafting tables, and furnaces; breaking and placing blocks; and attacking with melee weapons or bows.

A ridden donkey automatically runs up any one block high slope. The donkey and rider can safely fit through a space as low as 2.75 blocks high. Lower clearance risks suffocating the rider if the rider's head enters a non-transparent block. The donkey itself can enter gaps as low as 1.625 blocks high, but may itself take suffocation damage when clearance is less than 1.75 blocks. They cannot fit through a 1-block-wide gap.

Unlike horses, all donkeys have the same movement speed and jump strength, although speed potions can be used on the donkey and travel via the Nether can make the donkey easily the pack animal with the fastest practical way to travel in Minecraft. Donkeys are slow moving backward, and about as fast as the player when moving sideways.

A ridden donkey can be made to, and holding the control charges for a higher leap. Donkeys are not affected by jump boost beacons or potions. The standard control dismounts from the donkey, as does going in water deeper than two blocks. Like the player, donkeys take fall damage when falling from heights.

It is impossible for a player to use a Nether portal while on a donkey. It is possible, however, to enter the portal on the donkey and then dismount, sending it through the portal on its own, or use a lead to position the donkey, then push it through the portal.

Behavior
Donkeys roam around idly, occasionally stopping to rear, swish their tails, or lower their heads as though eating the grass. Unlike sheep, the eating animation does not actually cause any grass to be consumed. A donkey may turn to look at a player who comes near. Any donkey, even a wild one, allows itself to be attached to a lead without protest. However, if the player attempts to saddle an untamed donkey, it rears and flails its front hooves. Donkeys remain passive, even when hit.

Donkeys occasionally emit an audible braying sound.

Donkeys, like most mobs, can ride in a minecart and boat. Unlike other passive mobs, donkeys slowly regenerate health.

Taming
Adult donkeys can be tamed: with an empty hand mount it repeatedly; when it no longer bucks the player and shows hearts, it is tamed. It is necessary to tame a donkey in order to breed it, give it equipment, or ride it for any length of time.

Taming depends on the donkey's "temper". They begin with a temper of 0 out of 100. When a player is riding the donkey, a random number between 0 and 99 is chosen. The donkey becomes tamed if this number is less than the temper, otherwise, the temper is increased by 5 and the player is bucked off. Temper can also be increased by feeding the donkey.

While riding an untamed donkey, a galloping sound is audible, more or less rapid. This gives a general idea of the donkey's speed. It is unknown whether there is any indication of jump height before taming.

Like all tamed animals, a death message is displayed to their owner if they are killed.

Breeding
Feeding tamed donkeys golden apples or golden carrots activates love mode.

The offspring appear more spindly than their adult versions and grow progressively larger with time until they reach their full size. The offspring do not automatically belong to the player who owns its parents. Rather, it is born as an untamed donkey and must be tamed after it grows into an adult. The foal can be fed to make it mature faster.

Breeding two donkeys creates a donkey foal. Because all donkeys have the same texture, the offspring look exactly like its parents when it is fully grown.

Cross-breeding a donkey with a horse creates a mule foal. Mules cannot breed. This unlocks the Artificial Selection achievement.

Food
Feeding a donkey food may alter its behavior and cause it to grow (if it is not yet an adult; foals normally take 20 minutes to fully mature if not fed), and restore its health. To feed a donkey, hold a valid food item and press while looking at it. If the food is invalid, the action is treated as an attempt to mount the donkey. Donkeys can be fed only when feeding would have an effect, similar to other animals. The table below lists the effects of the various foods donkeys can consume.

Statistics
All donkeys have three "equine stats" that vary between donkeys: health, (maximum) movement speed, and jump strength. These stats are created once the donkey is born or spawned, and are not affected by food.

Spawned values
When spawned in any way except breeding – for instance, using commands, spawning naturally, spawning as part of a skeleton trap, or using spawn eggs – donkeys are assigned their stats within certain ranges, specific according to their horse type.

Health
Donkey's health ranges from 15–30, but tends toward the average 22–23. Displayed hearts are health, divided by two, rounded down. A donkey with a non-even number of health points (15, 17, 19, etc.) does not display the last half-heart. If the donkey has lost one fewer health point than the inflicted damage and did not regenerate, it has an odd number of health points, otherwise, it has an even number of health points.

Movement speed
A donkey’s speed value is always 0.175, equivalent to 7.525 blocks/sec. For reference, the player's normal walking speed is 0.1, equivalent to 4.3 blocks/sec. and the player's sprinting speed is equivalent to 5.6 blocks/sec. The speed listed does not include any status effect that affects the speed of a horse or a player.

See transportation to compare the speeds of various transportation methods.

Jump strength
Donkey's jump strength is always 0.5, enough to clear $1 9/16$ blocks.

The following derived equation can be used to calculate a donkey jump height from its jump strength attribute (with an rss of 5.510e-19). This function was fit to the data found in the table below and is therefore most accurate around these values. Where x is JumpStrength

The exact jump strengths, to 15 digits, required to clear several block heights are listed below.

Bred values
When breeding two donkeys, the foal's stats are determined by averaging both parent's stats with a third set, randomly determined as above (i.e. add both parents' stats with the random value and divide by 3). Random values are used for the third set even when the value is not randomized for donkeys spawned naturally or with a spawn egg.

Data values
Donkeys have entity data associated with them that contain various properties of the mob.

Trivia

 * If a player picks up leather dropped by an adult donkey, they receive the “Cow Tipper" achievement. This is due to the achievement being given when a player picks up any piece of leather instead of being given when killing a cow.
 * A player riding a donkey is dragged along if the donkey is being pulled by a lead, and can even be lifted up in the air in the same way.
 * Using commands, it is possible to make a donkey with no armor slot, but also no way to equip a chest.
 * In the Bedrock Edition, the donkey can be transported in a boat by riding the donkey and jumping into the boat then dismounting (leaving the donkey behind in the boat) and activating the boat from underneath/underwater. Attempting to activate the boat to pilot it from above results in the player being mounted on the donkey again rather than being placed inside the boat to pilot it.