Java 26.2

Minecraft Enchantment Calculator

It finds the cheapest order for combining books on the anvil, counts the cost in levels, and helps you avoid «Too Expensive!».

Updated:
Exact Java 26.2 calculation

Anvil calculator

Find the cheapest order for combining ready-made books and check the anvil limit.

Version Java 26.2Real-time optimization
1

Your item

Choose the gear that should receive the enchanted books.

Diamond Sword10 enchantments available
Prior works on the item
Current penalty0levelsAfter a normal operation, the penalty becomes 1.
The item is already enchanted

Mark the enchantments already on the item. They cost nothing in later operations, but conflicting books become unavailable. Set the prior work above.

2

Enchanted books

Select an enchantment, then set the chosen book level.

Selected: 4
SharpnessBook: 1 lv. per enchantment level
V
LootingBook: 2 lv. per enchantment level
III
UnbreakingBook: 1 lv. per enchantment level
III
MendingBook: 2 lv. per enchantment level
I
3

Combination tree

The cheapest order is rebuilt after every change.

Ready
Diamond SwordItem
Looting IIIBook
1+6
Unbreaking IIIBook
Mending IBook
2+2
3+7
Sharpness VBook
4+8
Result
Diamond Sword
Looting IIIUnbreaking IIIMending ISharpness V
Prior-work penalty: 7
Total cost23levels4 operations in the optimal order
Most expensive operation8 / 39
Naive order27lv.Savings: 4 lv.
Final penalty7After 4 operations

The calculation uses anvil_cost values from the Java 26.2 vanilla datapack and item prior-work penalties.

At the anvil

Step-by-step order

Keep the base item on the left and place the donor book on the right.

4 operations · max 8 in one step
1Apply book to itemRunning total: 6 lv.
Diamond swordBase itemBookLooting IIIDiamond swordLooting III
Cost: 6 lv.Penalty becomes 1
2Combine booksRunning total: 8 lv.
BookUnbreaking IIIBookMending ICombined bookUnbreaking III, Mending I
Cost: 2 lv.Penalty becomes 1
3Apply book to itemRunning total: 15 lv.
Diamond swordBase itemBookUnbreaking III, Mending IDiamond swordLooting III, Unbreaking III, Mending I
Cost: 7 lv.Penalty becomes 3
4Apply book to itemRunning total: 23 lv.
Diamond swordBase itemBookSharpness VDiamond swordLooting III, Unbreaking III, Mending I, Sharpness V
Cost: 8 lv.Penalty becomes 7

Browse by topic

Вся вики
Anvil calculatorFind a cheaper book order and check the 39-level limit.Enchantment generatorBuild a compatible enchantment set for an item.Level plannerCalculate XP to a target and reserve levels for anvil work.Compatibility checkerCheck an enchantment pair or build a complete set for an item.Armor TrimsTry patterns on a full set and get the /give commands.Ore height mapFind the best Y level and mining method for every ore.End Portal CalculatorFind the stronghold from two Eye of Ender throws.Nether CoordinatesConvert coordinates 1:8 and check portal links.Banner EditorDesign a banner, try it on a shield, and get the /give command.Villager TradesEvery profession's trades by level, discounted prices, and book search.Armor comparisonCompare armor sets and enchantment effects.Enchanting TableThe odds of every enchantment in all three slots and how many bookshelves you need.Weapon damageHit damage, crits, the mace, and hits needed to beat a mob.Fortune and LootingHow much ores, mobs, and fishing drop with enchantments.Mining speedBlock breaking time and when a pickaxe mines instantly.Circles and spheresLayer plans for circles, ellipses, spheres, and domes with block counts.Slime chunksA slime chunk map from the seed and the ones nearest to you.Stacks and shulkersHow many stacks, chests, and shulker boxes your blocks take.Beacon and conduitPyramid, effects, range, and beam colour; the conduit frame.BrewingAny potion's recipe, its duration, and ingredients for a batch.FireworksStars, rockets, recipes, and a live show with burst height.

Enchantment builds and troubleshooting

Frequently asked questions

Why does the anvil say Too Expensive?

In Java Survival, a combination costing 40 levels or more is blocked. The limit applies to each operation, not the plan total. Having 100 levels does not remove it; renaming alone without repairs or enchantments is an exception.

How does the prior-work penalty grow?

A new item has a penalty of 0. Combining sets the new penalty to 2 × the larger input penalty + 1: 0, 1, 3, 7, 15, 31, 63. This reflects the depth of earlier combinations, not the total number of books used. Renaming alone does not increase it.

Should I combine every book into one first?

Not necessarily. Every transfer charges for the enchantments on the right-hand book, so both its contents and the two input penalties matter. The cheapest plan can mix individual books with small groups. The sum of level costs is not a number of XP points.

Can I reset the penalty and keep my enchantments?

A grindstone resets the penalty but removes ordinary enchantments and retains curses. Mending repairs durability with XP without increasing the penalty, but does not reset an existing one. If new enchantments exceed the limit, compare the same build on a fresh item.

Which item and book states does the calculation support?

The calculation uses Java 26.2 rules: one fresh book per selected enchantment, already at the desired level, with no prior work. The item can have a prior-work penalty. Material repairs, existing item enchantments, premade multi-enchantment books, and Bedrock are not modeled, so the displayed price is not an exact quote for those cases.