What this lottery number generator does
It picks a random, valid set of numbers for Powerball, Mega Millions, or any "pick k of n" game you describe, and works out the exact odds of the jackpot. Use it for a quick pick when you'd rather not choose, or for an office pool.
A random pick, not a prediction. Every combination has exactly the same chance in a fair draw. No generator, pattern, "hot" number or past result can make one ticket more likely to win than another.
The current game formats
- Powerball: five different white balls from 1 to 69, plus one red Powerball from 1 to 26. $2 per play.
- Mega Millions: five different white balls from 1 to 70, plus one gold Mega Ball from 1 to 24. $5 per play, with a multiplier included. This format started with sales on April 5, 2025 and the first drawing on April 8, 2025. It has fewer Mega Ball numbers than before, which improved the jackpot odds from about 1 in 303 million to about 1 in 290 million.
How the odds are calculated
The order of the main numbers doesn't matter, so the number of possible main-number sets is a combination, C(n, k). Each one pairs with any of the m bonus balls:
The odds of matching exactly j main numbers count the ways to pick j of your k winners and k − j of the n − k losers:
For "no bonus", replace 1 ÷ m with (m − 1) ÷ m. The calculator uses exact whole-number arithmetic (BigInt), so the big numbers aren't rounded.
Worked example: Powerball
C(69, 5) = 11,238,513 sets of white balls. Times 26 Powerballs = 292,201,338. That matches the official jackpot odds of 1 in 292,201,338. Mega Millions works the same way: C(70, 5) × 24 = 12,103,014 × 24 = 290,472,336.
| Powerball match | Odds |
|---|---|
| 5 white balls + Powerball | 1 in 292,201,338.00 |
| 5 white balls , no Powerball | 1 in 11,688,053.52 |
| 4 white balls + Powerball | 1 in 913,129.18 |
| 4 white balls , no Powerball | 1 in 36,525.17 |
| 3 white balls + Powerball | 1 in 14,494.11 |
| 3 white balls , no Powerball | 1 in 579.76 |
| 2 white balls + Powerball | 1 in 701.33 |
| 1 white ball + Powerball | 1 in 91.98 |
| 0 white balls + Powerball | 1 in 38.32 |
Adding up the chances of all nine prize tiers gives overall odds of winning any prize of 1 in 24.87 for Powerball and 1 in 23.07 for Mega Millions, the same as the official figures.
How the numbers are picked
Numbers come from your browser's cryptographic random generator with rejection sampling, so each number is equally likely and there's no modulo bias. Main numbers are drawn without replacement, like balls from a drum, and sorted. The bonus ball is drawn separately.
Limitations
- Game rules, prices and prizes are set by the lotteries and can change. Check the official game rules before you play.
- The custom mode assumes the bonus ball comes from its own separate set of numbers. Games that draw the bonus from the same drum, or that need the numbers in order, have different odds.
- Odds aren't payouts. Jackpots are shared between winners, and prize amounts vary by game and state.