Anvil calculator

On the anvil, each use increases the item's work penalty. According to the Minecraft Wiki (Anvil mechanics, current Java Edition mechanics), the penalty starts at 0 and doubles with each use: it is 0, 1, 3, 7, 15 and 31, that is, 2 to the power of c minus 1.

The cost of combining two items is the sum of the value of the enchantments and repairs brought by the sacrificed item, the penalties of the target and of the sacrificed item, and 1 level if it is renamed. Repairing with material costs 1 level per unit, plus the target's penalty.

An operation with a cost above 39 levels is refused with the message Too Expensive!. This tool shows the cost and warns when it goes above 39.

Tool

Fill in the fields to see the cost.

How to use

  1. Choose the mode: combine items or repair with material.
  2. Enter how many previous uses the target item had (0 to 10). For combining, do the same with the sacrificed item.
  3. In combine mode, enter the value of the enchantments and repairs in levels and mark whether you will rename.
  4. In material mode, enter how many material units you will use.
  5. Read the cost. If it goes above 39, the operation is refused in the game.

Frequently asked questions

Why is the limit 39 and not 40?

Because the wiki says the anvil only applies operations of up to 39 levels. A cost of 40 or more is refused.

What is the work penalty?

It is a number stored on the item that grows with each use of the anvil. According to the wiki, it doubles with each use, following 2^c − 1.

How is the penalty calculated after an operation?

By the wiki's rule, the new penalty is 2n+1, where n is the higher of the two items' penalties.

Are the values valid for Bedrock Edition?

The wiki says the enchantment multipliers differ between editions. This tool follows the rules it describes for Java Edition.

Sources