Online Dice Explained: Virtual Dice Rollers, Polyhedral Dice Odds and Dice Games for Money
Quick answer
Online dice use a random number generator to pick each face, so a fair virtual die gives every face the same chance: 1 in 4 on a d4, 1 in 20 on a d20. Sums of several dice are found by counting combinations. Free dice rollers have no payout; gambling dice add a multiplier and a house edge.
| Fair d20, any face | 1 in 20 (5%) |
|---|---|
| Average roll of a dN | (N + 1) ÷ 2, e.g. 10.5 on a d20 |
| 3d6 outcomes | 6 × 6 × 6 = 216 equally likely |
| Most likely 3d6 totals | 10 and 11, 27 of 216 ways each (12.5%) |
| Free dice rollers | No stake, no payout, no house edge |
| Crypto dice | You choose the win chance; multiplier set by the house edge |
Online dice are virtual dice rolled by a computer instead of your hand. You'll find them in two very different places: free dice rollers for board games and tabletop role-playing games, and dice games for money in online casinos. Both rely on the same idea. A fair online die gives every face an equal chance, so a d6 lands on each number 1 time in 6 and a d20 lands on each number 1 time in 20.
This guide explains how a dice roller turns random numbers into faces, gives the exact probabilities for the full polyhedral set from d4 to d20 (the dice used for Dungeons & Dragons and similar games), shows how to work out sums like 3d6, and explains where gambling dice differ from a plain roller. For crypto dice specifically, see our dice crypto guide.
How online dice rollers work
Every online die starts with a random number generator (RNG): code that produces a stream of numbers with no usable pattern. Most software uses a pseudo-random generator, which is an algorithm that produces numbers that behave randomly for practical purposes. The roller then maps that number onto the faces of the die.
The mapping is where a roller can go wrong. Suppose the generator produces a random byte, a whole number from 0 to 255, and the roller computes "byte mod 6" to choose a face:
256 = 42 × 6 + 4256 possible bytes don't divide evenly into 6 faces. Four faces get 43 bytes each and two faces get 42, so those four come up slightly more often (43/256 = 16.80% vs 42/256 = 16.41%).
Well-written rollers avoid this "modulo bias" by discarding the leftover values and drawing again, or by using a large enough random number that the bias becomes negligible. You can't usually see a free roller's code, but you can test it (see the fairness check below).
Gambling dice add one more layer. A provably fair crypto dice game derives each roll from a hash of a server seed, a client seed and a counter, as one operator's implementation notes describe, so the result can be recomputed after the bet. A tabletop roller has no need for that, because nobody is paid on the result.
Polyhedral dice probabilities: d4 to d20
A standard polyhedral set has six shapes: d4, d6, d8, d10, d12 and d20. On a fair die every face is equally likely, which makes the math straightforward. Probability is favourable outcomes divided by total outcomes, as Britannica's guide to gambling odds puts it:
P(any one face on a dN) = 1 ÷ N average roll = (N + 1) ÷ 2d20: 1 ÷ 20 = 5%, average (20 + 1) ÷ 2 = 10.5. d8: 1 ÷ 8 = 12.5%, average 4.5.
| Die | Faces | Chance of any one face | As a percentage | Average roll | Chance of the top half |
|---|---|---|---|---|---|
| d4 | 4 | 1 in 4 | 25.00% | 2.5 | 75.0% (2+) |
| d6 | 6 | 1 in 6 | 16.67% | 3.5 | 66.7% (3+) |
| d8 | 8 | 1 in 8 | 12.50% | 4.5 | 62.5% (4+) |
| d10 | 10 | 1 in 10 | 10.00% | 5.5 | 60.0% (5+) |
| d12 | 12 | 1 in 12 | 8.33% | 6.5 | 58.3% (6+) |
| d20 | 20 | 1 in 20 | 5.00% | 10.5 | 55.0% (10+) |
The last column is the chance of rolling at least half the maximum: for a d20 that's 10 or more, which is 11 faces out of 20 (55%). Notice that "half or better" is always a little over 50%, because the halfway face itself counts.
Rolling a target number or higher on a d20
Many tabletop games ask you to roll a target number or higher on a d20. Count the faces that succeed:
P(roll ≥ X on a d20) = (21 − X) ÷ 20Need 15 or higher: (21 − 15) ÷ 20 = 6 ÷ 20 = 30%.
A common variant is to roll two d20s and keep the higher (or the lower). The two dice are independent, so the multiplication rule applies: the chance that both dice miss is the single-die miss chance squared.
keep higher: P = 1 − ((X − 1) ÷ 20)² keep lower: P = ((21 − X) ÷ 20)²Need 15+: keep higher = 1 − (14/20)² = 1 − 0.49 = 51%. Keep lower = (6/20)² = 9%.
| Target on a d20 | One d20 | Two d20, keep higher | Two d20, keep lower |
|---|---|---|---|
| 5+ | 80.00% | 96.00% | 64.00% |
| 8+ | 65.00% | 87.75% | 42.25% |
| 10+ | 55.00% | 79.75% | 30.25% |
| 12+ | 45.00% | 69.75% | 20.25% |
| 15+ | 30.00% | 51.00% | 9.00% |
| 18+ | 15.00% | 27.75% | 2.25% |
| 20+ | 5.00% | 9.75% | 0.25% |
Keeping the higher of two dice helps most in the middle: a 10+ goes from 55% to 79.75%. A natural 20 goes from 5% to 9.75%, nearly double but still rare.
Sums of several dice
When you add dice together, totals in the middle become more likely, because more combinations reach them. The method is always the same: count the combinations. The multiplication principle says that if one step can happen m ways and the next n ways, together they happen m × n ways.
number of outcomes for k dice with N faces = N^k3d6: 6 × 6 × 6 = 216 equally likely outcomes. 2d20: 20 × 20 = 400.
P(total) = ways to make the total ÷ N^k3d6, total 10: 27 ways ÷ 216 = 12.5%.
Here is the full 3d6 distribution, which we calculated by counting every one of the 216 combinations:
| 3d6 total | Combinations | Chance | Roughly |
|---|---|---|---|
| 3 | 1 of 216 | 0.46% | 1 in 216.0 |
| 4 | 3 of 216 | 1.39% | 1 in 72.0 |
| 5 | 6 of 216 | 2.78% | 1 in 36.0 |
| 6 | 10 of 216 | 4.63% | 1 in 21.6 |
| 7 | 15 of 216 | 6.94% | 1 in 14.4 |
| 8 | 21 of 216 | 9.72% | 1 in 10.3 |
| 9 | 25 of 216 | 11.57% | 1 in 8.6 |
| 10 | 27 of 216 | 12.50% | 1 in 8.0 |
| 11 | 27 of 216 | 12.50% | 1 in 8.0 |
| 12 | 25 of 216 | 11.57% | 1 in 8.6 |
| 13 | 21 of 216 | 9.72% | 1 in 10.3 |
| 14 | 15 of 216 | 6.94% | 1 in 14.4 |
| 15 | 10 of 216 | 4.63% | 1 in 21.6 |
| 16 | 6 of 216 | 2.78% | 1 in 36.0 |
| 17 | 3 of 216 | 1.39% | 1 in 72.0 |
| 18 | 1 of 216 | 0.46% | 1 in 216.0 |
Two six-sided dice work the same way with 36 combinations; 7 is the most likely total at 6 of 36. Our craps odds guide shows how that distribution drives every craps bet.
At least one success in several rolls
To find the chance of something happening at least once, work out the chance it never happens and subtract from 1:
P(at least one N on k rolls of a dN) = 1 − ((N − 1) ÷ N)^kAt least one 20 in 10 rolls of a d20: 1 − (19/20)^10 = 1 − 0.599 = 40.1%.
| Rolls | At least one 6 on a d6 | At least one 20 on a d20 |
|---|---|---|
| 1 | 16.7% | 5.0% |
| 5 | 59.8% | 22.6% |
| 10 | 83.8% | 40.1% |
| 20 | 97.4% | 64.2% |
| 30 | 99.6% | 78.5% |
| 50 | 100.0% | 92.3% |
Even 20 rolls of a d20 give only about a 64% chance of seeing a 20. Our chance calculator works this out for any probability and number of tries.
Checking a random dice roller against the math
The best evidence that a dice generator is fair is a large sample that matches the exact figures. In probability terms, the share of each result settles towards its true chance as the number of rolls grows; OpenStax describes probability as this long-run relative frequency.
We did this for two six-sided dice. Our script rolled 1,000,000 simulated pairs and compared the totals with the exact counts:
| Two-dice total | Exact chance | Our 1M-roll simulation |
|---|---|---|
| 2 | 2.78% | 2.75% |
| 3 | 5.56% | 5.56% |
| 4 | 8.33% | 8.25% |
| 5 | 11.11% | 11.14% |
| 6 | 13.89% | 13.89% |
| 7 | 16.67% | 16.62% |
| 8 | 13.89% | 13.95% |
| 9 | 11.11% | 11.13% |
| 10 | 8.33% | 8.35% |
| 11 | 5.56% | 5.58% |
| 12 | 2.78% | 2.77% |
No total was more than 0.09 percentage points from the exact figure. That's what a fair generator looks like at a million rolls.
You can run a smaller version on any online dice roller. Roll a d6 600 times and tally the faces: each should land near 100. Expect natural scatter of roughly 10 either way; a face sitting at 60 or 140 would be a red flag.
Gambling dice vs non-gambling dice
The same random number can feed very different products:
| Free dice roller / virtual tabletop | Crypto dice (roll under/over) | Craps | |
|---|---|---|---|
| What you roll | Any polyhedral dice | A number from 0 to 100 | Two six-sided dice |
| Stake and payout | None | Stake × multiplier | Fixed payouts per bet |
| Who sets the odds | The die | You choose the win chance | The bet you pick |
| House edge | None | 1% in our model | 1.41% on the pass line (our calculation) |
| Verification | Usually none needed | Provably fair seeds | Physical or audited RNG |
The key difference is the payout. A free roller just reports a number. A gambling game pays slightly less than fair odds. In crypto dice at a 1% edge, a 50% chance pays 1.98x instead of the fair 2x, so every 100 USDT bet returns 99 USDT on average. Our dice game guide simulates what that does to a bankroll, and the dice odds calculator shows the price of any target.
Common mistakes
- Expecting a 20 within 20 rolls. "1 in 20" is an average rate; the chance of at least one 20 in 20 rolls is about 64%.
- Thinking a cold die is due. Each roll is independent, online or physical.
- Adding chances instead of multiplying. Two dice both rolling 6 is 1/6 × 1/6 = 1/36, not 2/6.
- Treating a free roller like a casino game. Rolling for fun has no edge; once money and a payout are attached, the house edge applies to every roll.
More dice guides, from craps to crypto dice, are on our dice games hub.
Frequently asked questions
Are online dice rollers really random?
A well-built roller uses a random number generator and maps its output evenly onto the die's faces, so each face has the same chance. You can't check the code of most free rollers, but you can test one: roll a d6 600 times and each face should appear roughly 100 times, with natural variation of a dozen or so either way.
What are the odds of rolling a natural 20 on a d20?
1 in 20, or 5%, on every roll. A d20 has 20 equally likely faces and one of them is a 20. Previous rolls don't change it. Over 20 rolls the chance of at least one 20 is 1 − (19/20)^20, about 64%, not 100%.
Can I use dungeons and dragons dice online instead of physical dice?
Yes. A virtual roller that picks faces uniformly gives the same probabilities as a balanced physical die: 1 in N for each face of a dN. Many groups use online dice for remote play. The math in this guide applies equally to both.
What is the difference between a dice roller and a dice game for money?
A dice roller just produces numbers. A dice gambling game attaches a stake and a payout to the result, and the payout is set slightly below fair odds, which is the house edge. In crypto dice at a 1% edge, a 50% chance pays 1.98x instead of the fair 2x.
What is the most likely total with three six-sided dice?
10 and 11 are tied as most likely. Each can be made 27 ways out of 216 equally likely combinations, a 12.5% chance. The extremes, 3 and 18, can each be made only one way, about 0.46%.
Sources
- 9.5 Counting Principles — OpenStax (College Algebra). Multiplication Principle: m ways then n ways gives m x n; P(n,r) = n!/(n-r)!; C(n,r) = n!/(r!(n-r)!)
- Two Basic Rules of Probability — OpenStax, Rice University. Multiplication rule; independent events
- Terminology — OpenStax, Rice University. Probability as long-run relative frequency; law of large numbers
- Gambling: Chances, probabilities and odds — Encyclopaedia Britannica. Probability = favourable/total; odds = unfavourable to favourable
- Provably Fair: Implementation — Stake.com. Server seed hashed before play, client seed, nonce, cursor; HMAC_SHA256 output split into floats