Dice Roller

Roll virtual dice with customizable sides and modifiers. Perfect for tabletop games and RPGs.

Rolling 2d6

Click Roll to start

Dice Configuration

How the Dice Roller Works

This online dice roller simulates rolling any number of dice, each with any number of sides, and adds a flat modifier to the total. The tool mirrors the notation used in tabletop roleplaying games: NdS+M, where N is the number of dice, S is the number of sides on each die, and M is an optional positive or negative modifier.

When you click Roll Dice, the calculator generates one random integer per die, uniformly distributed between 1 and the number of sides (inclusive), then sums all results and adds the modifier. For example, rolling 2d6+3 rolls two six-sided dice, adds the two face values together, and then adds 3 to that sum.

The tool supports between 1 and 20 dice at a time and between 2 and 100 sides per die, covering everything from the classic d6 through the percentile d100 used in many RPG systems. Modifiers can be any positive or negative integer, representing ability score bonuses, proficiency bonuses, situational penalties, or any other flat adjustment a game rule applies.

A roll history stores up to the last 20 rolls in your session, showing each roll's full notation, individual die results, and final total. After multiple rolls, session statistics appear automatically, displaying the total number of rolls made, the running average, and the highest and lowest totals you have recorded. This makes it easy to spot streaks, verify probability over time, or track a character's damage output across a combat encounter.

Dice Roll Total Formula

Total = (d₁ + d₂ + … + dₙ) + M

Where:

  • dᵢ= Result of die i: a random integer in [1, S], computed as Math.floor(Math.random() × S) + 1
  • n= Number of dice (1–20)
  • S= Number of sides per die (2–100)
  • M= Flat modifier added to the sum of all dice (any integer, positive or negative)

Understanding Standard Dice Notation

The dice notation system (also called RPG dice notation or dice algebra) is a compact shorthand universally adopted across tabletop roleplaying games, wargames, and board games. Once you understand it, you can read any rulebook or module without confusion.

The basic format is NdS: the letter d stands for "die" or "dice," the number before it is how many dice to roll, and the number after it is the number of sides. So 3d8 means "roll three eight-sided dice and add them together." When there is only one die, the leading 1 is often omitted: d20 is the same as 1d20.

Modifiers are appended after the die code with a plus or minus sign: 2d6+5 means roll two six-sided dice, sum them, then add 5. A negative modifier looks like 1d20-2. Modifiers commonly represent ability score bonuses (Strength, Dexterity, etc.), proficiency bonuses, magic item bonuses, or spell-imposed penalties.

Notation Meaning Common Use
d41 four-sided die (1–4)Dagger damage, magic missile
d61 six-sided die (1–6)Short sword, sneak attack, ability score generation
d81 eight-sided die (1–8)Longsword, rapier, hit dice for ranger/bard
d101 ten-sided die (1–10)Heavy crossbow, warlock hit die
d121 twelve-sided die (1–12)Greataxe, barbarian hit die
d201 twenty-sided die (1–20)Attack rolls, saving throws, skill checks
d100 (d%)1 percentile die (1–100)Wild magic surges, random encounter tables
4d64 six-sided dice summedD&D 5e ability score generation (drop lowest)

Understanding this notation lets you configure the dice roller precisely for any rulebook instruction. Select the number of dice and sides to match the notation, enter your modifier, and roll.

Probability and Statistics of Dice Rolls

Each die in this roller is a fair, uniform random variable: every face has an equal probability of appearing. For a single die with S sides, the probability of any specific face is exactly 1/S. For a d6, that is 1/6 ≈ 16.67%; for a d20, it is 1/20 = 5% per face.

When you roll multiple dice and sum them, the distribution of totals is no longer flat — it follows a discrete probability distribution that increasingly approximates a bell curve (normal distribution) as the number of dice grows. This is a direct consequence of the Central Limit Theorem. With 2d6, totals of 6, 7, and 8 are far more likely than 2 or 12. With 4d6, the middle values cluster even more tightly.

Key statistics for NdS+M rolls:

  • Minimum possible total: N × 1 + M = N + M
  • Maximum possible total: N × S + M
  • Expected value (mean): N × (S + 1) / 2 + M
  • Variance: N × (S² − 1) / 12

For a standard 1d6, the expected value is (6 + 1) / 2 = 3.5. For 2d6, it is 2 × 3.5 = 7. The session statistics panel in the roller tracks your running average, which should converge toward the theoretical mean as you accumulate more rolls.

A critical success (rolling the maximum on the die) and a critical failure (rolling 1) each have a probability of 1/S. On a d20 that is a 5% chance for each, which is why D&D 5e critical hits feel exciting but not overwhelming — they occur roughly once every 20 attack rolls before any advantage or disadvantage is considered.

Common RPG and Tabletop Game Uses

The dice roller covers virtually every situation you will encounter in popular tabletop RPG systems. Here are the most frequent use cases and the dice configurations they require.

Dungeons & Dragons 5th Edition

D&D 5e relies almost entirely on the d20 for its core resolution mechanic: every attack roll, saving throw, and ability check is 1d20 plus relevant modifiers. Damage rolls use a variety of dice depending on the weapon or spell. Ability score generation uses 4d6 (drop the lowest, which you can approximate by rolling 4d6 and discarding the smallest value manually). Hit points at level-up use the character class's hit die (d6 through d12) plus Constitution modifier.

Pathfinder

Pathfinder 2e uses a similar d20-based system. Spells and abilities often add multiple dice — for example, fireball deals 6d6 fire damage. Increasing spell level adds more dice, making the multi-dice feature of this roller especially useful.

Warhammer Fantasy Roleplay

WFRP uses d10 and d100 (percentile) rolls for skill tests. The d100 is rolled as two d10s read as tens and units, giving a result from 01 to 100. The d100 preset in this roller simulates that directly.

Board Games and Wargames

Many board games use 2d6 or 3d6 for movement or combat resolution. Wargames such as Warhammer 40,000 use pools of d6 for hit and wound rolls. This roller handles pools of up to 20 dice at once, covering most practical wargame scenarios.

Probability Experiments and Education

Teachers and students use virtual dice to demonstrate probability, the law of large numbers, and the Central Limit Theorem without needing physical dice. Roll the same configuration many times and watch the session average converge toward the theoretical expected value — a vivid, interactive statistics lesson.

Using the Dice Roller Effectively at the Table

Whether you are playing face-to-face with physical dice or running an online session over a virtual tabletop (VTT), this free online dice roller fits seamlessly into your workflow. Here are practical suggestions for getting the most out of it.

Bookmark quick presets mentally: The preset buttons (d4 through d100 and multi-die combos) let you switch dice types in one click. Before a session, identify which dice you use most — your weapon damage die, your spell dice, your hit die — and get familiar with selecting them quickly so rolls do not interrupt the narrative flow.

Use the modifier field for everything flat: Instead of rolling then doing mental arithmetic, enter your full modifier (ability bonus + proficiency + magic bonuses) into the modifier field before rolling. The calculator adds it automatically and displays the corrected total, reducing calculation errors during fast-paced combat.

Track advantage and disadvantage manually: D&D 5e's advantage rule calls for rolling two d20s and taking the higher (advantage) or lower (disadvantage). Set the dice count to 2 and the sides to 20, roll, then apply the higher or lower value as your final result — the individual die values are shown for exactly this purpose.

Session history as a cheat-sheet: The roll history log lets you verify a total after a moment of distraction, or show other players that a critical hit result is genuine. Up to 20 entries are stored, which covers most combat encounters.

Clear history between encounters: Use the Clear button after each encounter to reset the session statistics. This gives you a clean average for the new fight rather than mixing old and new data.

Worked Examples

D&D 5e Longsword Attack Roll

Problem:

A fighter attacks with a longsword. The player needs to roll 1d20, then add +7 (proficiency bonus +3, Strength modifier +4). The DM set AC 15. Did the attack hit?

Solution Steps:

  1. 1Configure the roller: 1 die, 20 sides, modifier = +7.
  2. 2Roll the d20. Suppose the result is 11.
  3. 3Total = 11 + 7 = 18.
  4. 4Compare 18 to AC 15: 18 ≥ 15, so the attack hits.
  5. 5Now roll damage: switch to 1d8+4 (longsword one-handed + Strength +4). Suppose the d8 shows 6. Total damage = 6 + 4 = 10.

Result:

Attack hits with a total of 18. Deals 10 slashing damage.

Ability Score Generation (4d6 Drop Lowest)

Problem:

Generate a Strength score using the standard D&D 5e method: roll 4d6 and drop the lowest die result.

Solution Steps:

  1. 1Configure the roller: 4 dice, 6 sides, modifier = 0.
  2. 2Roll 4d6. Suppose individual results are 5, 3, 6, 4.
  3. 3Identify the lowest result: 3.
  4. 4Drop the lowest and sum the remaining three: 5 + 6 + 4 = 15.
  5. 5The Strength score is 15 (before any racial bonus).

Result:

Strength score = 15 (before racial modifiers).

Fireball Spell Damage (6d6)

Problem:

A wizard casts Fireball at 3rd level, dealing 8d6 fire damage. A target failed their saving throw and takes full damage. What is the total?

Solution Steps:

  1. 1Configure the roller: 8 dice, 6 sides, modifier = 0.
  2. 2Roll 8d6. Suppose results are 4, 2, 6, 5, 1, 3, 6, 4.
  3. 3Sum all results: 4 + 2 + 6 + 5 + 1 + 3 + 6 + 4 = 31.
  4. 4No modifier applies to the base roll.
  5. 5The target takes 31 fire damage.

Result:

31 fire damage (example roll; actual results vary each cast).

Wild Magic Surge Table (d100)

Problem:

A sorcerer triggers a Wild Magic Surge. The DM asks the player to roll d100 (percentile) to look up the effect on the table.

Solution Steps:

  1. 1Configure the roller: 1 die, 100 sides, modifier = 0.
  2. 2Click Roll Dice. Suppose the result is 43.
  3. 3Total = 43 (no modifier needed for a table lookup).
  4. 4Look up entry 43–44 on the Wild Magic Surge table in the Player's Handbook.

Result:

Roll result: 43. Consult the Wild Magic Surge table for the corresponding effect.

Tips & Best Practices

  • Enter your full modifier (ability score + proficiency + magic bonuses) before rolling to get the corrected total in one step.
  • For D&D 5e advantage, set 2d20 and take the higher die shown; for disadvantage, take the lower.
  • Use the Quick Presets (d4 through 4d6) for one-click switching between the most common game dice.
  • Clear the roll history between encounters so session statistics reflect only the current fight.
  • To simulate 4d6-drop-lowest for ability scores, roll 4d6 and mentally discard the smallest individual die shown.
  • Roll d100 for any percentile table in Warhammer, Call of Cthulhu, or D&D 5e wild magic surges.
  • Negative modifiers (e.g., -2 for bane or cover penalties) are fully supported — just type a negative number in the modifier field.
  • The roll history log stores up to 20 entries, so you can scroll back and verify a contested roll result during play.

Frequently Asked Questions

The dice roller uses JavaScript's built-in Math.random() function, which is a pseudorandom number generator (PRNG) seeded by the browser at runtime. It produces results that are statistically uniform and unpredictable for practical purposes, making it suitable for all tabletop game use. For cryptographically sensitive applications, a hardware RNG would be required, but no dice game needs that level of security.
The roller supports up to 20 dice per roll, with each die having between 2 and 100 sides. This covers the vast majority of tabletop scenarios, including large damage pools (e.g., Empowered Spell with 20 dice) and wargame batch rolls. If you need more than 20 dice, roll multiple times and add the totals manually.
Set the dice count to 2 and the sides to 20 (2d20), then roll. The individual die values for both d20 results are shown side by side. For advantage, take the higher of the two values; for disadvantage, take the lower. The combined total displayed is not used — only the individual die face you choose applies to your attack roll or check.
Yes. Enter any negative integer in the modifier field (for example, -2 for a bane penalty or -5 for a Sharpshooter attack). The calculator adds it to the sum of the dice, which correctly reduces the total. Negative modifiers are common for ability score penalties, debuffs, long-range attack penalties, and harsh terrain movement costs in various rule systems.
After your first roll, a statistics panel appears showing the total number of rolls made in the current session, the running average of all totals (rounded to one decimal place), the highest total recorded, and the lowest total recorded. The statistics update live with every new roll and reset when you clear the history. This is especially useful for verifying that your dice are behaving near the expected probability over many rolls.
Roll history and statistics are stored only in the current browser session (in React state). Refreshing or closing the page clears all history. If you need to preserve results — for example, a session log for an online campaign — copy the individual roll results to a notes app or virtual tabletop chat before leaving the page.
Traditionally, percentile rolls use two ten-sided dice: one is designated the 'tens' die (0–9, read as 00–90) and the other the 'units' die (0–9), giving a range of 01–00 (where 00 = 100). This roller's d100 option generates a single uniform random integer from 1 to 100, producing the same statistical distribution. The result is equivalent for any table lookup or skill check that uses a percentile system.

Sources & References

Last updated: 2026-06-05

💡

Help us improve!

How would you rate the Dice Roller?

<>

Editorial Note

MyCalcBuddy Editorial Team

This page is maintained as an educational calculator reference.

Source

Formula Source: Standard Mathematical References

by Various

UpdatedLast reviewed: May 2026
CheckedFormula checks are based on standard references and internal QA review.