Foxes

Foxes are nocturnal passive mobs that spawn commonly in taiga, giant tree taiga and snowy taiga biomes, which move to villages during night.

Upon death, adult foxes drop 1–2 experience orbs when killed by a player or tamed wolf.

Like other baby animals, killing a baby fox yields no experience.

Foxes always drop any items they pick up and are still holding (they cannot drop food that they have eaten, for example) and drop items they spawn with naturally with a chance of 8.5%‌ [Java Edition only]  or 100% ‌ [Bedrock Edition only], so: if a fox is killed while holding a totem of undying, then the fox consumes the totem and revives itself instead of dropping the totem.

Foxes move quickly as ocelots and they flee from nearby players and wolves. However, they do not flee if the player approaches them while sneaking. They are unaffected by sweet berry bushes, taking no damage or speed reduction while moving in them. Breeding 2 adults with sweet berries produces a kit that trusts the player. Naturally spawned kits do not trust players.

Attacking[edit]
Foxes attack chickens, rabbits, cod, salmon, tropical fish, and baby turtles on land. Foxes also attack any mobs that hurt a player they trust. Foxes attack either by running up to the target or by pouncing. A fox prepares to pounce by tilting and lowering its head and lowering its body to become shorter. They will leap into the air 2 to 5 blocks high. Foxes can jump over fences and walls. In Bedrock Edition, foxes also shake side to side before pouncing and their legs can be seen waving while in midair.

Red foxes prefer to attack chickens, rabbits, and baby turtles, all of which are on land, over cod, salmon, and tropical fish; conversely, arctic foxes prefer to attack cod, salmon, and tropical fish over land-dwelling creatures.

A fox that pounces into a snow layer becomes momentarily stuck, remaining face-down, emitting particles, and returning to normal shortly after.

Foxes attempt to run towards the closest attackable mob, even if attached to a lead.

Sleeping[edit]
During the day, if a thunderstorm is not occurring, foxes attempt to find a space with a skylight level of 14 or less and sleep. Block light has no effect on this. While it sleeps, it slowly moves its head up and down. A fox wakes if approached by a player or mob. Foxes do not flee if the player approaches while sneaking.

If the skylight at the fox's position becomes 15, either due to a block above being destroyed or the fox being moved, the fox wakes up.

Foxes can drop and pick up items in their sleep.

Trusting foxes can fall asleep even if attached to a lead.

Foxes do not sleep if they are within 12 blocks of an armor stand.

Sitting
A fox sits down sometimes during the day if the fox cannot find a shaded area to sleep. The fox sits for only a short moment, then hops back up. Foxes sit down even when attached to a lead or in a boat.

Holding items
If any item is on the ground near a fox, it travels to the item and picks it up, and the item appears in the fox's mouth. This behavior is not limited to food and animal products; a fox can pick up any item that the player can pick up. However, they prefer to pick up food items (except cake), and if they have already picked up non-food items, they drop the non-food items in favor of picking up food. A fox eventually eats any food item it picks up (besides cake) and the fox is affected by any side effects from the food, such as poison or teleportation. If there is a stage 3 or 4 sweet berry bush within a 16 block radius of a fox, it sprints towards the bush and eats the berries, dropping the item it was holding. If a fox picks up a weapon or an item with enchantments, these items affect the fox's attack as if the fox is wielding the weapon in its main hand, although the item retains its durability when used by the fox.

Night life[edit]
During the night, foxes sometimes go to villages. There, they can be seen attempting to attack villager-owned chickens. They can be heard screeching.

Breeding[edit]
When sweet berries are used on two foxes, the foxes breed, producing a baby fox. The baby fox trusts the player that bred it and does not flee from that player as it grows up; however, because baby foxes also follow nearby adult foxes, an adult running away from the player may cause the baby to do the same. A lead can be useful during this time to keep the baby fox from fleeing until it has finished maturing to an adult itself.

A naturally spawned baby fox does not trust the player, so it needs to become an adult before it can breed with another fox.‌ [Bedrock Edition only]

[needs testing]

If a red fox is bred with a snowy fox, the baby has a 50% chance of being either red or snowy.

Enemies
Wolves are aggressive towards foxes when within 18‌ [JEonly] /16‌ [BEonly]  blocks. In Java Edition, adult polar bears also sneak toward foxes to attack them; in Bedrock Edition adult polar bears attack foxes within 16 blocks. In Java Edition, baby polar bears, though normally passive, also attempt to attack foxes within 16 blocks.

Entity data[edit]
See also: Chunk format

Foxes have entity data associated with them that contains various properties of the mob.
 * Entity data
 * Tags common to all entities [show]
 * Tags common to all mobs [show]
 * Additional fields for mobs that can breed [show]
 * TrustedUUIDs: The players that the fox trusts. For a list with more than 2 elements, only the first and the last are considered.
 * The UUID of each trusted player.
 * L: Least significant bits of the Universally Unique Identifier of the friend, to be joined with M to form the friend's unique ID.
 * M: Most significant bits of the Universally Unique Identifier of the friend, to be joined with L to form the friend's unique ID.
 * Sleeping: 1 or 0 (true/false) – Whether the fox is sleeping.
 * Type: Which type of the fox this is.
 * Sitting: 1 or 0 (true/false) – Whether the fox is sitting.
 * Crouching: 1 or 0 (true/false) – Whether the fox is crouching.

Gallery[edit]

 * 

A fox with an emerald in its mouth.
 * 

A red fox pouncing at a chicken.
 * 

A red fox sleeping during the day.
 * 

A sitting red fox.
 * 

A fox sleeping under a tree while holding a feather.
 * 

A baby fox sleeping with an enchanted golden apple in its mouth.