Dice Roller API

GET

Roll standard RPG dice expressions with individual rolls and totals.

Dice Roller simulates RPG dice rolls using standard notation like 3d6 or 2d20 with optional modifiers. It outputs the individual die outcomes, die count, and the sum of all rolls.

Try it — live request, no key required

Request
GETapi.apiverve.com/v1/diceroller
Verification
Format

No key required to try it. Get a key to use it in your app.

Example
{
  "status": "ok",
  "error": null,
  "data": {
    "dice_notation": "3d6",
    "num_dice": 3,
    "num_sides": 6,
    "modifier": 5,
    "rolls": [
      6,
      4,
      4
    ],
    "total": 14,
    "total_with_modifier": 19,
    "min_roll": 4,
    "max_roll": 6,
    "average_roll": 4.67,
    "theoretical_min": 3,
    "theoretical_max": 18,
    "theoretical_average": 10.5,
    "expression": "3d6+5"
  }
}

About the Dice Roller API

Dice Roller works by parsing dice notation (e.g., 3d6+5), simulating random dice rolls, and calculating totals with modifiers. Returns individual roll results, statistics, and theoretical probability ranges.

What people use it for

RPG Gaming
Roll dice for tabletop RPGs, D&D sessions, and role-playing game mechanics
Game Development
Implement dice rolling mechanics in digital games and gaming applications
Probability
Demonstrate probability concepts and dice statistics for educational purposes
Simulations
Generate random numbers with dice distributions for simulations and testing

Ways to call it

One endpoint, many ways in — REST with JSON, XML, YAML and CSV, plus GraphQL and an MCP interface for AI agents.

JSON
Default REST response
XML
Markup format
YAML
Human-readable
CSV
Tabular export
Beta
GraphQL
Query language
New
MCP
For AI agents

Other ways to use Dice Roller

Same data, same APIVerve account, same credit balance — one key works on all of them.

Questions.

Common questions about the Dice Roller API.

Read the docs →
What dice notation formats are supported?
The API accepts standard RPG notation in XdY format, such as 3d6 or 2d20. You can specify the number of dice to roll alongside the number of sides on each die.
Does the response show each individual die result?
Yes. The response includes an array listing the result of every individual die rolled alongside the die count and sides. You can inspect each individual roll in addition to the overall sum.
What happens if I call the endpoint without specifying any dice?
The request defaults to 1d6. The Dice Roller rolls a single six-sided die and returns the individual result, die count, sides, and total without requiring you to pass notation.
Are roll statistics and theoretical bounds included on the Free plan?
No. The Free plan returns individual rolls and the raw total. Roll statistics like the minimum roll, maximum roll, average roll, theoretical probability ranges, and the final total with modifier are premium fields available on any paid plan.
What would 20,000 dice rolls a month cost me?
At 2 credits per call, 20,000 rolls require 40,000 credits, using one-fifth of the Starter plan's 200,000 credits. That volume works out to about $0.0003 per roll, or $0.30 per 1,000 calls. The Free plan includes 100 calls per month.

Ready to build with Dice Roller? Start with 200 free credits — one key unlocks all 300+ APIs.

Explore the catalog

300+ APIs on the same key and the same response shape.

Browse all APIs