Generate random numbers in any range, one or many at a time.
Set a minimum and maximum and this produces random integers in that range, inclusive of both endpoints. It uses the browser's crypto.getRandomValues(), a cryptographically secure random source, rather than the ordinary Math.random().
That distinction matters more than it might appear. Math.random() is a pseudo-random generator: fast, adequate for shuffling a carousel, and entirely predictable to anyone who observes a few outputs. For a prize draw, a giveaway, or anything where someone has an incentive to game the result, it is not appropriate.
A subtle flaw in most naive implementations. Taking a random value modulo the range size does not distribute evenly unless the range divides the generator's output space exactly.
The correct approach is rejection sampling — discard values that fall in the uneven tail and draw again. This tool does that, so every value in your range is equally likely. It is invisible in casual use and matters a great deal in a draw with a prize attached.
| Type | Source | Predictable? | Use for |
|---|---|---|---|
| Pseudo-random (PRNG) | An algorithm from a seed | Yes, given the seed | Simulations, games, testing |
| Cryptographic (CSPRNG) | Algorithm seeded with system entropy | No, in practice | Draws, tokens, keys, passwords |
| True random (TRNG) | Physical noise — thermal, radioactive decay | No | Seeding, high-security keys |
The generator here is the middle category, drawing its entropy from the operating system's pool, which collects unpredictable timing information from hardware. For everything short of generating long-term cryptographic keys, that is more than sufficient.
People are consistently poor judges of what random output should look like, and this causes needless suspicion of correctly working generators.
If you are running a giveaway, a few practical points make the result defensible: assign every entrant a number in a fixed, published order before drawing; state the range and the method in advance; draw once rather than repeatedly until you like the result; and if the stakes are high, record the draw or have a witness. For selecting several winners without repeats, draw one at a time and remove each winner from the range — or shuffle the full list, which is cleaner.
Numbers are produced in your browser. Nothing is transmitted and no result is logged, so no one — including us — can see or influence your draw. The flip side is that we cannot verify a draw for you either, which is why recording it yourself matters for anything contested.
They come from a cryptographically secure generator seeded by your operating system's entropy pool, which is unpredictable in practice. That is not the same as physical true randomness, but it is more than sufficient for draws, games and token generation.
An uneven distribution caused by taking a random value modulo the range size when the range does not divide evenly into the generator's output space. Lower numbers come up slightly more often. This tool uses rejection sampling to avoid it.
Yes, each draw is independent. Repeats are expected — drawing from 1 to 10 twenty times, a repeat is far more likely than not. If you need unique values, remove each result from the range before drawing again.
The generator itself is. For a defensible draw, publish the entrant order and range beforehand, draw once, and record it. The mathematics is only part of what makes a draw credible.
No. Generation happens entirely in your browser and nothing is logged or transmitted. Nobody else can see or influence the outcome — and equally, we cannot verify it for you afterwards.