Villager

Villagers are passive mobs that inhabit villages, work at their professions, breed, and interact with each other. Their outfit varies according to their occupation and biome. A player can trade with them using emeralds as currency.

## Spawning

### Natural generation

Villagers can be found in villages, which spawn in several biomes such as plains, snowy plains, savannas, deserts, taigas, and snowy taigas‌ and can cut into other biomes such as swamps and jungles. When the village is generated, unemployed villagers spawn in them, the number of which depends on the buildings in that village, as some buildings generate villagers inside and some do not.

A cleric villager and cleric zombie villager spawn locked up in the basements of igloos (if the basement generates) under the carpet of the floor. The cleric villager can also turn into a leatherworker villager since the cauldron in the basement is closer to the villager.

### Curing

Giving a zombified villager the Weakness effect and then feeding it a golden apple will start the curing process. After five minutes, it transforms into a villager, displaying purple Nausea status effect particles for 10 seconds after being cured. The villager retains the profession it had as a zombie, if it had one before turning into a zombie villager. If the zombie villager is player spawned, it adopts a randomly chosen profession. The villager can also be a nitwit, as the game counts it as a "profession" but the nitwit villager still can't work. If employed, the cured villager offers discounts on most of its trades.

## Drops

A villager, either adult or baby, does not ordinarily drop any items when killed. However, when a player holds an emerald or other item a villager is willing to trade for, the item it offers in trade appears in its hands, alternating between items if there are multiple items the villager wants to trade.

Upon successful trading, a villager drops 3–6 XP.

Upon successful trading, while willing to breed, 8–11 XP is dropped.

## Behavior

### Movement patterns

Nitwit and unemployed villagers leave their homes at day and begin to explore the village. Generally, they wander inside the village during the day. They may go indoors or outdoors, periodically making mumbling sounds. Occasionally, two villagers may stop and turn to look at each other, in a behavior called socializing, during which they stare at another villager for 4–5 seconds at a time. They continuously stare at a nearby player unless the villager is trying to get into a house at night, farm food, work, or flee from a zombie or illager. Baby villagers may jump on beds and play tag with each other, similarly to how baby piglins and baby hoglins play tag.

Villagers tend to not travel far from their beds in a large village unless the job site or the nearest gossip site (bell) is far from their beds.

Villagers, like other mobs, can find paths around obstructions, avoid walking off cliffs of heights greater than 3 blocks, and avoid some blocks that cause harm. However, in crowded situations, one villager can push another off a cliff or into harm's way.

Villagers emit green particles if they join a village, set a bed or acquire a job site/profession.

Villagers run inside at night or during rain, closing doors behind them. They attempt to sleep at night, but if they cannot claim a bed, they stay indoors near a bed until morning. In the morning, they head outside and resume normal behavior. However, some villagers, such as nitwits, stay outside later than others unless being chased by an illager or zombie.

If a villager finds itself outside the village boundary, or a villager without a village detects a village boundary within 32 blocks, it moves quickly back within the boundary. A villager taken more than 32 blocks away from its village boundary forgets the village within about 6 seconds. Whether in a village or not, a villager is never prone to despawning.

Villagers can open all wooden doors and find paths or blocks of interest behind the doors. However, they cannot open any trapdoors, fence gates, or iron doors. Villagers can climb ladders, but do not recognize them as paths and do not deliberately use them. Any climbing of ladders seems to be a side effect of them being pushed into the block by another mob, (likely, and most often, other villagers). Unfortunately, this behavior can leave them stranded on the second floors and roofs of some village structures, as they lack the necessary AI to intentionally *descend* ladders. A simple fix for these situations is for the player to manually push the villager back toward the ladder hole and then install a wooden trapdoor at the top, after the villager is returned to the ground level. One way to prevent a villager from climbing ladders is to break the first ladder touching the ground thus requiring a player to jump to the ladder to climb.

#### Getting attacked

Villagers flee from zombies, zombie villagers, husks, drowned, zombified piglins, zoglins, vindicators, pillagers (even if their crossbow has been broken), ravagers, and vexes within 8 blocks, and evokers and illusioners within 12 blocks. Like other passive mobs, villagers sprint away when attacked. Villagers do not run away from skeletons (and their variants), spiders, or cave spiders since these hostile mobs are passive towards villagers, although a skeleton arrow might hit a villager by accident.

### Job site blocks

Unemployed villagers (other than babies and nitwits) seek employment at job site blocks (also referred to as workstations), and employed villagers use job site blocks to refresh their trades. Villagers who have made their first trade can only claim a site block that corresponds with their profession, whereas tradeless villagers may change their profession to match a site block.

Unemployed villagers claim job site blocks by searching for the nearest unclaimed site in a 48-block sphere. When a suitable site block is detected the villager will start pathfinding to it, staking a provisional claim. This can only occur while the villager is awake. A provisional claim is released if the villager cannot reach the block within 60 seconds, however the villager may try again immediately. To fully claim the site and change profession, the villager must approach within a 2-block radius of the job site's center. When a job site block is fully claimed, its owner emits green particles, and no other villager can claim the block unless the owner relinquishes it.

### Gossiping

Villagers can store certain memories about players in the form of gossip. These get spread to other villagers whenever they talk with each other. Each piece of gossip is one of five types, and it stores a value as well as a target. Gossip generates and increase in value as a result of various player actions. The target is the player who caused the gossip. Together the gossip values determine a player's reputation with the villager, which influence trading prices and the hostility of naturally spawned iron golems.

Trading with or curing a villager increase the value of the corresponding gossips for the targeted villager only. When a villager is attacked or killed, however, it instead generates the *major negative* gossip in every other villager it could see (eye-to-eye line of sight) inside a box extending 16 blocks from the villager in all coordinate directions.

When a piece of gossip is shared, it is received at a lower value than the sharer has it. Gossips also decay a certain amount (see *Decay* column) every 20 minutes. Since *major positive* gossip have a share penalty equal to its max value and a decay of 0, it cannot be shared and never decays.

A player's total reputation with a villager is determined by multiplying each gossip's value by their respective multiplier and adding the results together. For example, if a player has recently cured a villager for the first time but also attacked the villager twice, their reputation with that villager would be 5×20 + 25 - 50 = 75. After 40 minutes the gossips have decayed twice, making the player's reputation 5×20 + 23 - 10 = 113.

The prices of a villager's trades all get *reduced* by reputation times the price multiplier rounded down, meaning that a positive reputation lowers prices but a negative reputation increase them. The price multiplier is either 0.05 or 0.2 depending on the item, see trading. Prices can not get lower than 1 or higher than the item's stack size. The exact function to calculate the price affected by the gossips is **y = x - floor((5a + b + c - d - 5e) × p)**, Where *y* is the final price, *x* is the base price, *a* is the value of `major_positive`, *b* is the value of `minor_positive`, *c* is the value of `trading`, *d* is the value of `minor_negative`, *e* is the value of `major_negative`, and *p* is the value of `PriceMultiplier`.

Iron golems that were not built by a player become hostile towards players whose reputation with any nearby villager is -100 or lower. The golem checks all villagers inside a box centered on the golem and extending 10 blocks in every horizontal direction and 8 blocks in both vertical directions.

Players can set villagers on fire using flint and steel or lava without affecting gossips. The same is true for TNT activated by redstone or a dispenser. However, TNT ignited directly by a player (using flint and steel, fire charges or flaming arrows) *does* generate gossip for damaged or killed villagers, because the TNT's damage is attributed to the player.

### Picking up items

Villagers have eight hidden inventory slots, which start empty whenever the villager is spawned. Villagers do not intentionally seek out items to pick up, but they do collect any bread, carrots, potatoes, wheat, wheat seeds, beetroot, beetroot seeds, and bone meal within range (bone meal can be picked up only by farmer villagers). These are the only items they can pick up, although the player may use the `/item` replace command to put an arbitrary item into a villager's inventory. Villagers can fill all 8 inventory slots with the same item. If a player and a villager are in the pickup range of an item at the same time, the player always picks it up first. If several villagers are next to an item, the same one picks up the item every time. Consequently, in constrained space, the same villager picks up any item dropped. This behavior prevents villagers from sharing food in a one-block space.

When killed or converted to a zombie villager, any inventory item of the villager is lost, even when `/gamerule keepInventory` is set to `true`.

If `/gamerule mobGriefing` is `false`, villagers cannot pick up items, and farmer villagers cannot plant or harvest crops.

Like other mobs, villagers have four slots for worn armor, separate from their inventory. An adjacent dispenser can equip armor, elytra, mob heads or carved pumpkins to a villager, but the armor is not rendered (except for carved pumpkins and mob heads). The equipment functions as normal; for example, a villager wearing an armor piece enchanted with Thorns can inflict Thorns damage to attackers, and a villager wearing Frost Walker boots is able to create frosted ice. If a villager is converted into a zombie villager, the armor it was wearing is dropped, though it may be able to pick it up and equip it again.

### Sharing food

Villagers collect bread, carrots, potatoes, beetroots, wheat seeds, beetroot seeds, and wheat. If a villager has at least 24 of these items, it will give the extra amount to a villager with 4 or less of each these food items. That other villager can also do this until all villagers have shared all items they could (for example, on a group of three villagers one receives 50 bread, then it shares 36 to another villager to keep 24, and that same villager then shares 12 to the third villager).

In the case of wheat, villagers have a rather distinct behavior. They do the same as other crops, but if a villager has at least 32 wheat, it tries to give half of it to another villager, making both have 16 wheat.

If a villager has 8 full stacks of any kind of food or seeds and then tries to share with another, for example a bait villager in a farm where a hopper picks it all up, it will leave 24 in each stack in its inventory instead of calculating the total amount it has, and it will always try to maintain this minimum amount, thus it can never really empty its inventory down to 0 and clear a slot to pick up other stuff, unless it uses the items when trying to breed or when farming if they are a farmer.

To share, a villager finds its first inventory stack with at least 4 bread, carrots, potatoes, or beetroot or with at least 6 wheat, and then throws half the stack (rounded down) in the direction of the target villager. When wheat is shared, it is first crafted to bread, which may result in 1 or 2 less than half the stack being shared.

### Farming

During the "work" portion of their schedule farmers tend nearby crops.

* They will sometimes move to random farmland blocks they detect within ±4 on the X an Z axes and ±2 on the Y axis, rather than going to their jobsite.
* If there are fully-grown crop blocks or air above farmland within ±1 of the villager on each axis, the farmer will spend 10 seconds tending them (not counting time spend walking to the next block), one per second. The block will be harvested if necessary and (re-)planted if the farmer has any seeds.
	+ If `/gamerule mobGriefing` is `false`, villagers cannot farm.
	+ Harvesting is done regardless of the villager's current inventory, even if they lack space to pick up the results.
	+ Planting is done as from the first eligible inventory slot.

* If the farmer has bone meal, there is at least one non-fully-grown crop block within ±1 of the villager on each axis, and it has been at least 8 seconds since the villager last did some fertilization, the villager will fertilize up to four crop blocks (one every two seconds).
* When the farmer works at their composter, they will extract bone meal if it is full and will compost excess wheat and beetroot seeds. Up to 20 seeds are composted in one work session, but at least 10 of each type of seed are first kept. Inventory slots are checked in reverse order.
* Farmer villagers *cannot* turn dirt, grass blocks, or dirt paths into farmland. Nor they pick up any hoes to till the blocks.
* If a hoe is placed into a farmer villager's mainhand or offhand via commands, they still cannot till any blocks.
* Farmer villagers often share their crops and food with other villagers if they have any extras.

### Breeding

Adult villagers breed depending on the time of the day and need to be willing to spawn Baby villagers, who also require beds with at least 2 empty blocks above the head. Job sites are not required for villagers to breed.

The breeding depends on the number of valid beds. If a villager is "willing" (see § Willingness below), villagers breed as long as there are unclaimed beds available within the limits of the village. All baby villagers are initially unemployed.

Two villagers nearby one another periodically enter mating mode if both have enough food and are not on cooldown. Breeding fails (with anger particles displayed) if no unclaimed bed can be reached via pathfinding within a 48 block radius. The appearance of the child is randomly determined by either the biome type of the parents or by the biome where the breeding occurred.

#### Willingness

Villagers must be willing to breed. Willingness is determined by the amount of food items a villager has. Becoming willing consumes the villager's food stock, therefore, after mating, villagers cease to be willing until they gather a sufficient stock of food items and breed again.

Villagers must have enough beds within village bounds for baby villagers to spawn. The villager must be able to path-find the bed from their current position. (Note that mobs view slabs as full blocks for pathfinding, so putting upper half slabs above a bed invalidates the bed.)

Villagers can become willing by having either 3 bread, 12 carrots, 12 potatoes, or 12 beetroots in one slot in their inventory. Any villager with an excess of food (usually farmers) throws food to other villagers, allowing them to pick it up and obtain enough food to become willing. The player can also throw bread, carrots, beetroots, or potatoes at the villagers themselves to encourage breeding. Villagers consume the required food upon becoming willing. If `/gamerule mobGriefing` is `false`, villagers don't pick up food or break crops.

### Baby villagers

Baby villagers sprint around, entering and leaving houses at will. They sometimes stop sprinting to stare at other villagers,‌ the player, or an iron golem. If the iron golem is holding out a poppy, the children may cautiously take the flower from its hands. This is a reference to the 1986 Japanese animated movie *Castle in the Sky*, in which a giant robot covered in vines (inspiration for the iron golem) gives the main characters flowers to put on a memorial. Baby villagers tend to group and chase one another around the village as if playing tag. They also jump on beds.

Illagers ignore baby villagers until they reach adulthood.

Baby villagers give gifts of poppies or wheat seeds to players who have the Hero of the Village effect.

Baby villagers don't have too big of a head, so they look like a tiny normal villager.

Baby villagers can fit through 1×1 block gaps.

A baby villager becomes an adult 20 minutes after birth, even when in a boat or a minecart. Baby villagers with no AI do not grow up.

### Lightning

When lightning strikes within 3–4 blocks of a villager, the villager is replaced by a witch that can't despawn. Even a baby villager that is struck by lightning is turned into a two-block-tall witch.

Iron golems also attack any villagers that turned into witches.

### Iron golem summoning

Villagers can summon iron golems to protect themselves from hostile mobs.

Villagers can summon an iron golem regardless of their profession (including nitwits) or latest working time.

### Panicking

Villagers sometimes panic during a raid or a zombie siege by emitting water particles and shaking.

Villagers panic if they see a mob that is hostile toward villagers, like a zombie, zombie villager, husk, drowned, zoglin, illager, vex, wither, or ravager and flee frantically from them, sometimes hiding in houses. In Bedrock Edition, villagers panic by running around in circles around a bed in a village house, such as when a raid happens or when the player rings the village bell. *V*illagers in panic are more likely to summon iron golems. To see these mobs, the villager must have an unobstructed line of sight to it (eye-level to eye-level), and be within a certain range (spherical distance between feet center bottom-most point of the villager and hostile mob):

 Vindicator, Zoglin
 Evoker, Illusioner, Ravager
 Pillager

### Zombies

Zombies, zombie villagers, husks, and drowned seek out and attack villagers within a 35– to 52.5–block radius (depending on regional difficulty)‌, even when the villager is invisible. Zombies attempt to break down doors, but only a fraction of zombies can do so and can succeed only when difficulty is set to hard. Zombies who cannot break doors tend to crowd around a door that separates them from a villager. If a zombie or a drowned comes across a set of doors with one open, it usually tries to go through the closed door.

Both zombies and drowned either kill villagers or convert them to zombie villagers. The chance of the villager becoming a zombie villager upon death is 0% on Easy, 50% on Normal, and 100% on Hard. Baby villagers can be infected by zombies as well. Drowned are able to convert villagers to zombie villagers, even when attacking with a trident from a distance.

### Raids

During a raid, villagers flee from illagers and run to the nearest house, similar to a zombie siege. For a villager to hide, the house must have a door and at least one bed.

Before the first raid wave at least one villager rushes to ring the bell in the center of the village (if they are close enough) to warn the other villagers of an incoming raid before going into their house. When a bell is rung, all illagers within 48 blocks get the glowing effect for 3 seconds.

A villager often stays in the house it first entered, but may exit the house occasionally. The player can still trade with villagers during a raid.

On random occasions, the villager displays water particles as if sweating.

Once the player gains the Hero of the Village status after defeating a raid, villagers give them a discount for their trades and throw them gifts related to their profession. For a list of items that they can gift, see Hero of the Village Gifts.

### Staring

Villagers stare at any player that stares at them, or goes near them. This also applies for some mobs, especially wolves. A villager first turns its head towards the player, then the body. Villagers can keep staring at the player unless a raid happens or a zombie comes and chases them off.

## Schedules

Villagers have set schedules depending on their age and employment status. Schedules define the villager's goals, which mostly determine how they behave throughout the day. However, their goals can be interrupted by higher priority behaviors most villagers have, such as fleeing from an attack, trading, and getting out of the rain.

 02000 (08:00:00)
 03000 (09:00:00)
 06000 (12:00:00)
 09000 (15:00:00)
 10000 (16:00:00)
 11000 (17:00:00)
 12000 (18:00:00)

### Working

Employed villagers spend most of their day standing next to their job site blocks. From time to time, they "gather supplies" by wandering a short distance away, then returning.

Some professions have additional job-specific goals that are part of their work schedule:

* Farmers harvest and sow crops.
* Librarians inspect bookshelves.‌

When a villager reaches its job site block, it commences "work". Two times a day, this action of working resupplies any locked trades. Villagers can resupply twice per day, even without having a bed or while sitting in a minecart. A villager can "reach" its job site block if the block is in any of the 8 directly adjacent or diagonal block spaces horizontally around it at the height of their feet, or at the 9 blocks below that. Villagers can still "reach" them diagonally, even if they can't see or touch the face of the block.

Employed villagers do not breed with each other during their work schedule. Nitwits and the unemployed do not follow this rule as they would breed with each other and the employed villagers.

Leatherworker villagers work at any cauldron; the cauldron does not have to be filled with water in order for the villager to work at it.

### Wandering

All villagers wander from time to time, but for the unemployed and nitwits, they wander for the majority of their day. A wandering villager chooses a random block and walks toward it, then stands there for a variable amount of time before wandering again. If at any time it detects a job site block it can claim, it does so, assumes the skin for the associated profession, and immediately begins following the appropriate schedule.

A villager attempts to claim a job site block by finding a path to a block next to one, showing angry particles when unable to reach it. After a villager fails to reach the job site block several times, it becomes unclaimed, indicated by showing angry particles on it. The villager loses its job site block and eventually becomes unemployed if the villager is at novice-level and no nearby job site block is available. Any other nearby unemployed villager has a chance to become the block's new owner. If there are no unemployed villagers nearby, then the villager who lost the job site block seeks for another unclaimed one or tries to reclaim the same unreachable one in an endless loop (this also happens for claiming beds).

The wander schedule includes a job-specific goal called "exploring the outskirts" that causes villagers to wander near the edges of the village. This enables them to detect new beds, job site blocks, bells, and houses that players have used to extend the village.

During this time of the day, they may also share items.

### Gathering

Late in the day, adult villagers gather at a meeting place (the area around a bell). When two villagers encounter one another, they mingle (look at each other and "converse" by humming at other villagers). They may also share food, or breed if both are willing.

If a villager isn't close enough to detect a bell, it wanders randomly, searching for one.

### Playing

Baby villagers wander randomly around the village. When they encounter another baby villager, the two of them follow each other for a while and sometimes run as if racing or chasing each other.

They sometimes stop to jump and bounce on a bed or to stare at an iron golem they encounter. If the iron golem offers them a poppy, the baby villager cautiously accepts it.

### Returning home

All villagers head home a short time before sunset. They roam around until they get near their beds, then target a block beside the bed. Once they reach their beds, they do not go through a door again before sleeping.

A villager who has no bed simply waits inside a house until morning. This includes players stealing a villager's bed to sleep in, mostly the villager stays in the house and doesn't move until sunrise. But sometimes, if they detect a unclaimed bed nearby they walk out of the house and towards the bed.

### Sleeping

At sunset, villagers lie down in their beds and remain there until morning. Villagers wake early if food is thrown at them, they are pushed out of bed, or if their bed is destroyed. They also wake up when their bed is used, if they are attacked, or when a bell is rung. If possible, they return to sleeping in a bed after the interruption.

Jumping on a bed with a villager sleeping in it doesn't cause the villager to get up.

Villagers can be pushed on beds and sometimes turn their heads. A villager can be pushed off a bed, but most likely to go back to sleeping after staring at the player who pushed the villager for a few seconds.

Dropping any anvil on a villager that is sleeping causes the anvil to bounce and drop as an item, and the villager remains sleeping and does not take damage.

A villager who has no bed continues wandering in search of a bed to claim.

Villagers follow their Overworld schedules regardless of which dimension they are in. They can sleep in the Nether or the End, without causing the usual consequences of the bed exploding (See Bed), if the Overworld's time is correct. This is because the daylight cycle continues in these dimensions, even though it is not normally apparent to the player.

Sometimes when a villager gets in a bed from another direction they turn their body until their head is on the pillow of the bed. Villagers also sleep with their eyes open, just like players.

### Healing

Villagers get a brief regeneration effect once leveling up in their profession. Pink regeneration particles appear when the villager is healing.

When villagers successfully sleep, they immediately heal themselves when waking up at dawn if they are damaged.

## Professions

Each villager can have a profession except for the nitwit, indicated by their clothing as well as by the title at the top of the trading interface. A villager can choose their profession by claiming a job site block. When they go to work, they use their daily schedule to get to their claimed job site block. Some professions, like farmers and librarians, do other things. Farmers plant crops, and librarians can inspect bookshelves. If an adult villager does not have a profession (either they are unemployed or a nitwit), they wander instead.

A job site block can be claimed only if it is unclaimed and within a village boundary with at least 1 bed. Removal of a claimed job site block causes the owner to switch to another profession or become unemployed, provided that the villager has no prior trades with the player. If the villager has prior trades, it keeps its profession and claims a new job site block that matches its profession if one is available. So, once a player trades with a villager, the villager keeps its profession forever.

Nitwits and baby villagers cannot change their profession.

Villagers summoned by a spawn egg or via command `/summon` are always unemployed until they have claimed a job site block.

Novice-level villagers who have not yet traded can lose their profession and change into unemployed villagers.

Unemployed adults actively seek for an unclaimed job site block and change into the corresponding profession.

Below is a table listing the various professions, along with the specific job site block that each profession requires:

### Nitwit

Nitwit villagers wear robes that are green on top. They cannot acquire a profession, trade, or gather around bells, but are still able to breed. They are not equipped with a level stone since they cannot trade. Pressing use on a nitwit causes it to grunt and shake its head at the player. A nitwit must be born or spawned; no villagers change to nitwit from unemployed or a profession, and vice versa. Nitwits can be found naturally or by curing naturally spawned zombie villagers. Zombie villagers can also be spawned as babies, so this is the only way to encounter baby nitwits in survival mode.

### Appearance

Villagers and zombie villagers have seven skin types corresponding to the biome they spawn in. Their appearance also varies based on their profession and their five tiers. They show which trade tier they have unlocked by a badge of a varying material on their belt. A new tier is obtained every time a player trades with a villager and the badge appears as stone, iron, gold, emerald, and finally diamond.

Villagers have different outfits depending on their biome. Naturally generated villagers take on the outfit from the biome they were spawned in. When breeding occurs, the outfit of the child is determined by the biome where the breeding occurs, but it is sometimes randomly inherited from the biome type of the parents.

## See Also

* Monsters
* Villager Professions