Roleplaying games like Dungeons & Dragons depend on the d20, and knowing your odds helps you choose the best action. This d20 hit chance calculator uses your attack bonus and the target’s armor class to give the chance to hit with a normal roll, advantage or disadvantage, the chance of a critical hit and the expected damage per attack and per round.
How the calculation works
- Needed roll = target armor class − attack bonus.
- Normal hit chance = (21 − needed roll) ÷ 20, never below the critical chance and never above 95 %.
- Advantage = 1 − (1 − p)². Disadvantage = p².
- Critical chance = (21 − critical threshold) ÷ 20, adjusted the same way for advantage or disadvantage.
- Expected damage = (hit chance − critical chance) × damage + critical chance × (damage + extra critical damage).
Example
A character with a +7 attack bonus attacks armor class 15, so a roll of 8 or more hits. On a normal roll that is 65 %, with advantage 87.8 % and with disadvantage 42.3 %, a swing of about 4.6 points on the d20. With 8.5 average damage, 4.5 extra on a critical hit and a 5 % critical chance, one attack averages 5.75 damage, so 2 attacks a round average 11.5.
Why it matters
A small bonus can matter a lot or very little depending on the target, and advantage is worth more than most items. Comparing hit chance and expected damage shows whether a feat that trades accuracy for damage pays off, whether to attack a tougher target with advantage or an easy one without, and how much a spell or ability that grants advantage really adds.
Good to know
The calculator assumes a natural 20, or your chosen threshold, always hits and a natural 1 always misses. Advantage and disadvantage do not stack, so enter just one. Other effects such as bless, reroll features or resistance change the numbers, so add them to the bonus or damage by hand. Expected damage is an average over many attacks, and a single fight varies a lot. Optional rules for criticals vary between tables, so adjust the extra critical damage to the rule you use.
Related tools
The dice probability calculator covers other dice, the expected value calculator averages any outcome, and the RPG hit points calculator estimates how much damage a character can take.