What is a Random Number Generator?
Draws for giveaways, sampling, test data, team selection and anything else that needs a number nobody chose.
Set a minimum and maximum, how many numbers you want, and whether repeats are allowed. Results can be sorted or left in draw order.
The numbers come from crypto.getRandomValues, the browser cryptographic random source, using rejection sampling so every value in the range is equally likely. The usual shortcut of scaling Math.random with a modulo quietly biases the low end of the range, which matters the moment anyone is picking a winner.
Frequently asked questions
Is this random enough for a giveaway?
Yes. It uses the browser cryptographic random source with rejection sampling, so the draw is unbiased across the range. For anything with legal or financial weight, use a process that can be audited and witnessed rather than any web page.
What is wrong with Math.random?
Two things. It is not a cryptographic source, and the common way of turning it into an integer with a modulo makes some values slightly more likely than others. Neither matters for a game, both matter for a draw.
Can I draw without repeats?
Yes. Turn duplicates off and each number appears at most once, which is what you want for picking winners or sampling.
Does anything get sent to a server?
No. The numbers are generated in your browser.