Coin Flipper API

GET

Run coin flip simulations with heads and tails outcome tracking.

Coin Flipper simulates random coin flips and records heads or tails outcomes with flip counts. Paid plans can simulate multiple flips per request and calculate percentages, streak lengths, and fairness indicators.

Try it — live request, no key required

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

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

Example
{
  "status": "ok",
  "error": null,
  "data": {
    "total_flips": 10,
    "flips": [
      "Tails",
      "Heads",
      "Heads",
      "Tails",
      "Tails",
      "Heads",
      "Tails",
      "Tails",
      "Tails",
      "Tails"
    ],
    "heads_count": 3,
    "tails_count": 7,
    "heads_percentage": 30,
    "tails_percentage": 70,
    "longest_streak": {
      "length": 4,
      "type": "Tails"
    },
    "first_flip": "Tails",
    "last_flip": "Tails",
    "is_fair": false
  }
}

About the Coin Flipper API

Coin Flipper works by generating random coin flip results using fair probability (50/50), tracking individual flips, and calculating comprehensive statistics including streaks and distribution analysis.

What people use it for

Decision Making
Make random decisions and choices using fair coin flip probability
Gaming
Implement coin flip mechanics for games, sports, and random selection features
Probability Teaching
Demonstrate probability concepts and random distributions in education
Simulations
Run probability experiments and test statistical concepts with multiple flips

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 Coin Flipper

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

Questions.

Common questions about the Coin Flipper API.

Read the docs →
How many coin flip simulations does the Free plan cover?
The Free plan provides 200 credits each month, covering 100 simulations at 2 credits per call. For higher volumes, the Starter plan covers up to 100,000 simulations per month, which works out to about $0.30 per 1,000 calls.
Are streak lengths and fairness scores included on the Free plan?
No, longest streak length, streak type, percentage distributions, and the fairness indicator are premium fields. Any paid plan unlocks these statistics alongside access to custom batch flip parameters.
Can I set a custom number of flips on the Free plan?
No, the flips parameter is restricted to paid plans. Free plan requests run using the default simulation count, while upgrading to Starter or above allows you to pass a custom flip count per call.
Does the API return each individual flip outcome?
Yes, the response provides an array of individual results marked as Heads or Tails. You also get dedicated fields for the first flip, the last flip, and aggregate counts for both outcomes across the simulation.
Can this API be used to analyze coin toss streaks?
Yes, on paid plans. Coin Flipper tracks consecutive flip streaks across multi-coin simulations. It reports the length of the longest streak and identifies whether it consisted of consecutive heads or tails.

Ready to build with Coin Flipper? 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