Random Number Generator
Draw random numbers between any two values — whole or decimal, with or without repeats, sorted or in draw order — using your browser’s cryptographic random source.
About this tool
This random number generator draws values between a minimum and a maximum you choose, then shows them as a readable set. It is the digital equivalent of pulling numbered balls from a drum: every value in the range has the same chance of appearing, and separate presses of Generate numbers are independent draws with no memory of the last result.
How the randomness works: the page calls crypto.getRandomValues, the browser’s cryptographically secure random source, rather than Math.random. It then applies rejection sampling — if a raw value falls in the leftover tail that would make the range uneven, it is discarded and redrawn. That detail matters: the naive random % range trick quietly makes small numbers slightly more likely, and a generator that does it is not fair. There is no server call, no seed stored between visits, and no way for anyone to predict the next result from the page itself.
How to use it: set the minimum and maximum, choose how many numbers you need, pick the decimal precision, and decide whether repeats are allowed and whether the output should be sorted. Press Generate numbers and the draw appears with a copy button for pasting into a spreadsheet, document or message.
Worked example: six unique whole numbers between 1 and 49 is a standard lottery draw. Set min 1, max 49, count 6, “no repeats”, order random — the tool returns six distinct values such as 7, 23, 31, 44, 12 and 3. Because unique draws sample without replacement, no number can appear twice in one set. If you switch to “allow repeats”, duplicates become possible, exactly as they are in real life when each ball is put back before the next pull.
What “unique” really means: it is sampling without replacement, implemented with a partial Fisher–Yates shuffle over the range. That is not the same as “reroll until different”, which is both slower and subtly biased when the range is nearly exhausted. If you ask for 50 unique numbers from a range of 50 you get a shuffled full set; asking for more than the range allows is rejected with a clear message.
What this tool is not: it is excellent for raffles, classroom pickers, sampling, game rolls, test data and decisions — but it is not a certified lottery machine, and no browser-based tool should be described as one. It also cannot reproduce a previous draw: there is deliberately no seed, because a seed would let anyone replay your “random” sequence. If you need reproducible randomness for a simulation or a test suite, use a seeded pseudo-random generator in code and record the seed. For generating cryptographic keys or passwords, use the dedicated password generator, which is built for that job.