Tutorials/Trading

This tutorial teaches you about how to get the most out of villager trading.
== Setting up a village ==
First, you need to set up your village. Check out these tutorials to set up your village or villager trading hall.
* Tutorials/Creating a village
* Tutorials/Villager trading hall
== Benefits of villager trading ==
Villager trading has many advantages. It allows you to:
* Obtain exclusive resources like explorer maps and globe banner pattern
* Obtain rare items like saddles and name tags
* Obtain items that are hard to get loads of otherwise, like apples
* Obtain renewable diamond equipment without having to mine for diamonds
* Obtain valuable enchantments through books, including treasure enchantments such as Mending
* Make otherwise non-renewable resources renewable, like glass and lapis lazuli
* Obtain infinite amounts of late-game food, such as golden carrots and cooked steak
* Make otherwise useless items like rotten flesh useful because they can be traded for emeralds
* Get a lot of experience while trading, for enchanting or tool mending
== Notes ==
Before you proceed, here are some things you'll have to do:
For a villager to offer useful items, you must level it up by trading. The ideal trades to do this are listed below, but as a rule of thumb, selling items for Emeralds increases a villager's experience more than buying items, and later trades offer more experience.
The items that villagers offer are random. If you get offers you don't want, you should either break and replace the job site block if you haven't traded with the villager yet, or you need a way to efficiently kill off villagers without lowering popularity. The best way to do this is by digging a 1x1 hole that is 3 blocks deep, and then use either lava or enough gravel or sand to kill them. You can also use magma blocks, campfires, and flint & steel to do the same thing. You can use zombies and husks to kill them, but they can be used for zombie discounts.
== Uses of each profession ==
=== Armorer ===
This profession is a must, as it allows you to obtain chain and diamond armor easily. In addition, you can buy bells if you plan on starting a new village. The best way to level it up is using iron. Iron is not too hard to get in large quantities after a large mining session, and it offers decent XP. Diamonds and lava buckets are too hard to obtain in large quantities to be ideal. In Java Edition, one villager is enough to provide a full set of diamond armor, while in Bedrock Edition, at least two villagers are needed.
Armorers are also the only reliable source of renewable diamond armor, as the only other way is to kill extremely rare zombies and skeletons that spawn with diamond armor. The diamond armor is enchanted upon purchase, but can be easily disenchanted using grindstone if the player wishes to add better enchantments.
=== Butcher ===
This profession does not sell anything other than food. However, it is useful to sell raw meat if the player has an efficient animal farm. Chickens and hoglins can be farmed fully automatically, meaning raw chicken and raw porkchops can be sold to butchers in large quantities. Sweet berries and dried kelp blocks can also be easily farmed and sold to obtain emeralds.
Butchers can provide a good source of cooked food. Cooked Porkchop is the most nutritious. 
=== Cartographer ===
The main reason to have a cartographer is to obtain explorer maps for ocean monuments or woodland mansions, in addition to unique banner patterns. Paper is sufficient to level it up, but if you have lots of sand, glass panes work fine, too. Once you have purchased the maps, the villager is still relatively useful, as paper can be continuously sold to it, as long as the player's sugar cane farm productivity is high enough.
=== Cleric ===
This profession is mainly useful for purchasing ender pearls, as well as bottles o' enchanting to raise your experience level, or as a portable experience storage. In addition, it allows you to trade away rotten flesh that has probably been either accumulating in your chests or thrown out. It is a little hard to level up, as aside from the flesh, it buys hard to obtain items, but this profession is still useful nonetheless. They are also one of the only renewable sources of lapis lazuli, but a 1:1 ratio of exchange makes it highly expensive. 
=== Farmer ===
The main use of this profession is to obtain emeralds by trading away crops, as well as buying golden carrots and glistering melon slices without having to craft them using gold. It is recommended to sell pumpkins, as these grow fast and are easy to mass farm. However, level them up with the melon trade, as it gives twice as much experience to the villager than the pumpkin trade.
The golden carrots obtained from these villagers can serve as a staple food for the player, thanks to their high nutritional value. The player can also buy cakes and apples relatively easily from them, so they do not need to craft the cakes manually, or chop down hundreds of oak trees for apples.
=== Fisherman ===
One of the less useful professions, it is really only useful for selling fish that you obtain from fishing sessions or from an AFK Fish Farm. While it buys string and coal, it asks for relatively high quantities, and you can sell these items to other professions. Level them up with the fish trades.
A few advantages about fishermen still exist: First, they have the cheapest coal trade compared to other coal-trading professions (10:1 instead of 15:1), so it can be useful if the player has a lot of coal from mining or killing wither skeletons. Buckets of cod can be obtained, so you don't have to go mining for iron. Second, all four types of fish they buy can be farmed in large quantities, with tropical fish and pufferfish having the better deals among the four. Third, they buy one boat for one emerald, a reasonably good deal. The boat trade is cheaper compared to the Fletcher's sticks to emerald trade in terms of wood planks (5:1 instead of 16:1), so you don't have to chop a lot of trees. You only need 15 logs to get 12 emeralds compared to 64 logs for 16 emeralds.
Nothing useful or unique can be bought from fishermen; the offers can all be easily obtained by other means.
=== Fletcher ===
This profession is useful in obtaining emeralds, as they buy sticks, which are easy to get. In addition, if you do not have Infinity on your bow, you can buy lots of arrows for a relatively cheap price. If you max them out, you can get hard-to-obtain tipped arrows, as well. Furthermore, if your fletcher sells arrows of weakness, you can mass-zombify and cure villagers without having to go to the Nether or hunt igloo basements for weakness. If you want them, level the villager up with sticks or buy a bunch of bows/crossbows unless you can afford the other trades.
If you encounter a village or an igloo with basement in early game, one of the most beneficial things you can do is to convert a villager to a fletcher, sell it sticks, and buy bow and arrows from it. this allows you to perform ranged attacks frequently, without the worry of running out of arrows. To achieve the same results, you either have to meticulously set up a chicken farm, get really lucky to find a skeleton spawner, or wait until you can get Infinity on your bow.
=== Leatherworker ===
This profession is really only useful for obtaining saddles, since leather armor is weak, and the player is likely going to keep most of their leather for themselves. It is recommended to level it up with leather unless you can afford the later trades. However, since saddles are not stackable, and the player does not usually need a large quantity of saddles, It can be argued whether this profession is really worth it. 
=== Librarian ===
This is one of the most important professions late-game, as it allows you to obtain almost every enchantment, including treasure enchantments, with the exception of Soul Speed and Swift Sneak. In addition, it buys paper, books, and ink sacs, all of which farmable, giving a good source of emeralds. This allows you to get perfect enchanted gear, although it requires a lot of XP to add the enchantments on an anvil. In addition, it takes a while before you get the enchantment you need for each villager. There is no need to level them up unless you need name tags, in which case level them up with the latest available trade.
=== Stone mason ===
This villager is useful for obtaining emeralds, as you can trade it stone (not cobblestone) and clay, especially if you have a stone generator and a Silk Touch pickaxe or if you have a clay farm or a lush cave nearby. Otherwise, you can sell them Nether Quartz, extra andesite, granite, and diorite that you picked up from a mining session, or buy quartz blocks for a large build. Level them up with the stone trade unless you have a lot of the stone variant to trade away. In Bedrock Edition, you need three masons to trade away each type of stone.
Masons also offer a renewable source of bricks, terracotta, and glazed terracotta. In version 1.17, they also sell dripstone blocks, which are pretty hard to find or farm.
=== Shepherd ===
This profession does not sell anything valuable, but it can buy wool and dyes as a good source of emeralds. There is no need to level it up. The player can have automatic wool farms and flower farms to allow for trading with shepherds.
=== Toolsmith ===
This profession is also a must, since you can obtain diamond tools and bells. Also, if you plan on using a diamond hoe, try to get a villager that sells you one, too. Like the armorer, level it up using iron.
=== Weaponsmith ===
This profession is important because you can obtain diamond axes and diamond swords easily, in addition to bells. Level it up with iron, as well.
== How to exploit villagers ==
=== Zombifying and curing ===
If you zombify a villager and cure it, preferably multiple times, you can reduce the prices and make the trades easier to do. If you cure the villager enough times, you can make all the trades cost one emerald or one item. This table shows the # of times you need to cure the villager to max out all the trades (1 emerald or 1 item). Works for both Java and Bedrock.
 Max out all trades
Villager 	# Cures
Armorer 	3
Butcher 	3
Cartographer 	5
Cleric 	7
Farmer 	6
Fisherman 	4
Fletcher 	7
Leatherworker	6
Librarian 	5
Mason 	4
Shepherd 	5
Toolsmith 	6
Weaponsmith 	5
=== Crazy villager exploits ===
This video is in Bedrock edition, but most of it works in Java edition. The first part describes a bug in zombie villagers, which is Bedrock Edition only. Skip to 4:28 for the actual villager exploits that work for both editions.
Below are a few broken villager trade loops.
* If a librarian has a maxed out bookshelf trade and a book trade, buy a bookshelf and break it without silk touch. Sell the books back to the librarian. You get 3 emeralds, subtract the cost of the bookshelf, and you get 2 free emeralds. 
* If a fletcher has the maxed out gravel to flint trade and flint to emerald trade, start with as many emeralds and the same gravel amount as the emerald amount. Give the villager an emerald and a piece of gravel for 10 flint, and sell the flint back to the villager. You get 9 emeralds each time you do this, but it costs one gravel, which you can easily get from under the ocean, mining, or in gravelly mountains. You can also sell the flint to leatherworkers, toolsmiths, and weaponsmiths, as long as you maxed them out.
* If a fisherman has the maxed out bucket of cod trade and the cod to emerald trade, start with 1 emerald. Buy a bucket of cod, pour it, and kill the cod. Sell the cod back to the villager. You don't get free emeralds, but you get a free bucket each time, which you can reuse for dripstone lava farms in 1.17 or for storing lots of powder snow, water, milk, fish, axolotl, and lava.
* This trade loop requires a cartographer with the maxed out glass pane trade and a librarian with the maxed out glass trade. Start with 3 emeralds and buy 12 glass from the librarian. Convert the glass to glass panes. You should get 32. Sell them to the cartographer for 32 emeralds. Subtract the 3 emeralds to buy the glass and you get 29 free emeralds.
* This trade loop is similar to the one above but uses a cleric with the maxed out glass bottles trade. You still need a librarian with the maxed out glass trade. Start with 3 emeralds and buy 12 glass from the librarian. Convert the glass to glass bottles. You should have 12. Sell them for 12 emeralds. Subtract the 3 emeralds and you get 9 free emeralds. This works better than the cartographer because the cartographer locks the trades before you finish selling the glass panes. If you have many cartographers, use the glass pane trade loop. If you don't have many cartographers, use the cleric trade loop.
* This trade loop doesn't give you extra emeralds, but cooks your food for you and you get more cooked food than you would get by smelting it. You need a maxed out butcher with a raw meat trade and the corresponding cooked meat trade. You can only use porkchop or chicken. You need a piece of meat of your choice. Sell the meat to the butcher and use the emerald to buy the corresponding cooked meat. If you used porkchop, you get 5 cooked porkchops, which is 4 more than you would get from smelting. If you used chicken, you get 8 cooked chickens, which is 7 more than you would get from smelting. You do not get any free emeralds, but you get 4 extra cooked porkchop or 7 extra cooked chicken. This doesn't work with fisherman because you need to pay an extra fish to get cooked fish.
* This trade loop requires a wandering trader with a two tall flower trade and a shepherd with the maxed out corresponding dye trade. Buy a two tall flower and craft it into two dye. Sell the two dye for 2 emeralds. You get one extra emerald. Another similar trade loop is to buy the dye directly from the wandering trader and sell it to the shepherd. You get 3 emeralds, minus the cost of the dye, and it is 2 extra emeralds. You can also buy 3 ink sacs and sell them to a librarian for 3 emeralds, minus the cost of the ink, and it is 2 extra emeralds.