# Lottery Odds Calculator

> Computes the number of possible tickets, the jackpot probability and '1 in N' odds for a lottery where k numbers are drawn from a pool of n (optionally with a separate bonus-ball pool), plus a table of the odds of matching each number of main numbers.

- Calculator id: `lottery-odds` · Category: Statistics & Probability (`statistics`) · Tool name: `calculate_lottery_odds`
- Canonical page: https://tttkmbb.com/statistics/lottery-odds · This document: https://tttkmbb.com/statistics/lottery-odds.md · JSON definition: https://tttkmbb.com/statistics/lottery-odds.json

## Purpose

Computes the number of possible tickets, the jackpot probability and '1 in N' odds for a lottery where k numbers are drawn from a pool of n (optionally with a separate bonus-ball pool), plus a table of the odds of matching each number of main numbers.

**Use when:** You want the odds of winning or of matching a given number of balls in a lottery such as 6/49, Powerball (5/69 + 1/26) or EuroMillions (5/50 + 2/12).

**Do not use when:** Bonus balls are drawn from the same pool as the main numbers (UK Lotto 'bonus ball'), or you need the expected value of a ticket (use expected-value with the prize amounts).

## Input

| Parameter | Type | Unit | Required | Description |
| --- | --- | --- | --- | --- |
| `pool_size` | integer |  | required | How many different numbers the main balls are drawn from. (min 2, max 1000) |
| `picks` | integer |  | required | How many main numbers are drawn (and chosen on a ticket) without replacement. (min 1, max 20) |
| `bonus_pool_size` | integer |  | optional | Size of a separate pool for bonus balls (e.g. 26 for the Powerball). Omit if there is none. (min 1, max 1000) |
| `bonus_picks` | integer |  | optional, default 1 | How many bonus balls are drawn from the bonus pool (1 for Powerball, 2 for EuroMillions Lucky Stars). (min 1, max 5) |

## Output

| Field | Type | Unit | Description |
| --- | --- | --- | --- |
| `total_combinations` | number |  | C(pool_size, picks) × C(bonus_pool_size, bonus_picks). |
| `jackpot_probability` | number |  | 1 / total_combinations for one ticket. |
| `jackpot_odds` | string |  | Odds as '1 in N'. |
| `matches` | list |  | One row per number of main matches (from picks down to 0): matched, ways (count as a string), probability and odds ('1 in N'), plus probability_with_bonus / odds_with_bonus and probability_without_bonus / odds_without_bonus when a bonus pool is given. |

## Formula

`P(match exactly m main numbers) = C(picks, m) × C(pool_size − picks, picks − m) / C(pool_size, picks); P(all bonus balls) = 1 / C(bonus_pool_size, bonus_picks); jackpot = 1 / (C(pool_size, picks) × C(bonus_pool_size, bonus_picks))`

Hypergeometric probabilities for the main numbers, multiplied by the independent bonus-pool probability. Odds are for a single ticket per draw and ignore shared jackpots and prize amounts.

## Data Sources

- Wikipedia – Lottery mathematics — https://en.wikipedia.org/wiki/Lottery_mathematics (reference, retrieved 2026-09-24)
- Wikipedia – Hypergeometric distribution — https://en.wikipedia.org/wiki/Hypergeometric_distribution (reference, retrieved 2026-09-24)

Data freshness: `static`. Deterministic formula with fixed constants; results never go stale. Inputs supplied by the caller determine the output.

## API

- `GET https://tttkmbb.com/api/v1/calculate/lottery-odds?pool_size=…&picks=…`
- `POST https://tttkmbb.com/api/v1/calculate/lottery-odds` with JSON body `{"inputs": {…}}`
- Response: unified envelope (`success`, `request`, `result.values`, `result.units`, `sources`, `freshness`, `timestamp`, `next_actions`, `links`); see https://tttkmbb.com/docs/response-format.md
- Schema: https://tttkmbb.com/api/v1/calculators/lottery-odds · OpenAPI operationId `calculate_lottery_odds` in https://tttkmbb.com/openapi.json
- Authentication: none. Rate limit: fair use, see https://tttkmbb.com/docs/rate-limits.md.

## MCP

- Server: `https://tttkmbb.com/mcp` (Streamable HTTP, JSON-RPC 2.0, no auth)
- Tool:  `run_calculator` with `{"calculator_id": "lottery-odds", "inputs": {…}}`

## Example

- 6 of 49: inputs `{"pool_size":49,"picks":6}` → `{"total_combinations":13983816,"jackpot_probability":7.15e-8,"jackpot_odds":"1 in 13,983,816","matches":[{"matched":6,"ways":"1","odds":"1 in 13,983,816"},{"matched":5,"ways":"258","probability":0.0000184499,"odds":"1 in 54,201"},{"matched":4,"ways":"13,545","probability":0.000968619,"odds":"1 in 1,032"},{"matched":3,"ways":"246,820","probability":0.0176504,"odds":"1 in 56.66"},{"matched":2,"ways":"1,851,150","probability":0.132378},{"matched":1,"ways":"5,775,588","probability":0.413019},{"matched":0,"ways":"6,096,454","probability":0.435965}]}`
- Powerball: 5 of 69 plus 1 of 26: inputs `{"pool_size":69,"picks":5,"bonus_pool_size":26,"bonus_picks":1}` → `{"total_combinations":292201338,"jackpot_odds":"1 in 292,201,338","matches":[{"matched":5,"ways":"1","odds":"1 in 11,238,513","odds_with_bonus":"1 in 292,201,338","odds_without_bonus":"1 in 11,688,054"},{"matched":4,"ways":"320","odds_with_bonus":"1 in 913,129","odds_without_bonus":"1 in 36,525"},{},{},{},{}]}`

```
GET https://tttkmbb.com/api/v1/calculate/lottery-odds?pool_size=49&picks=6
```

## Limitations

Bonus balls are drawn from the same pool as the main numbers (UK Lotto 'bonus ball'), or you need the expected value of a ticket (use expected-value with the prize amounts). Hypergeometric probabilities for the main numbers, multiplied by the independent bonus-pool probability. Odds are for a single ticket per draw and ignore shared jackpots and prize amounts. All values are computed from the formula above; no measurement or live data is involved.

## FAQ

**Does buying two tickets double my chances?**

Yes, two different tickets give 2 / total_combinations, still about 1 in 7 million for a 6/49 game.

**Why is 'match 5 without bonus' more likely than 'match 5 with bonus' by a factor of 25 in Powerball?**

The bonus ball is an independent 1-in-26 draw: of every 26 tickets matching all five main numbers, on average one also matches the Powerball and 25 do not.

## Related

- [Hypergeometric Distribution Calculator](https://tttkmbb.com/statistics/hypergeometric-distribution.md) — General sampling-without-replacement probabilities.
- [Combinations and Permutations Calculator](https://tttkmbb.com/math/combinations-permutations.md) — Count the possible tickets.
- [Expected Value Calculator](https://tttkmbb.com/statistics/expected-value.md) — Expected value of a ticket from prize amounts and probabilities.
