Random Number Generator
Generate random numbers in any range — up to 1,000 at once, with no-duplicates and sorting options. Includes lottery-style 6 of 49 preset.
About the Random Number Generator
This random number generator produces anything from a single number to 1,000 numbers at once, in any range you choose. Set the minimum and maximum, decide how many you need, and optionally require unique values (no duplicates) or a sorted result. Quick presets cover the most common cases: 1–10, 1–100, and a lottery-style 6 unique numbers from 1 to 49.
Unlike basic generators that rely on the predictable Math.random function, this tool uses crypto.getRandomValues — the cryptographically secure generator built into your browser — with rejection sampling so every number in your range is exactly equally likely. Generation happens entirely on your device; nothing is sent to a server.
People use it for raffles and giveaways, picking lottery numbers, random sampling for surveys and experiments, assigning teams, generating test data, and classroom probability exercises. The results appear as easy-to-read chips with a one-click copy button for pasting into spreadsheets or documents.
How to Use the Random Number Generator
- 1Enter the minimum and maximum of your range.
- 2Choose how many numbers to generate (1 to 1,000).
- 3Tick "No duplicates" and/or "Sort results" if needed.
- 4Click Generate, then copy the results with one click.
Frequently Asked Questions
How random are the numbers — can they be predicted?
The tool uses crypto.getRandomValues, the cryptographically secure random source browsers provide for generating encryption keys. Unlike Math.random, its output cannot practically be predicted or reproduced, and rejection sampling ensures no value in your range is favoured. For raffles, sampling and games, this is as fair as random generation gets.
How do I generate lottery numbers like 6 out of 49?
Click the "Lottery: 6 of 49" preset — it sets the range to 1–49, the count to 6, enables no-duplicates and sorts the result ascending, just like numbers appear on a ticket. For other lotteries, adjust the range and count to match: for example 1–50 with 5 numbers, then generate any bonus-ball numbers separately.
Why can't I generate 100 unique numbers between 1 and 50?
Unique means no number can repeat, and the range 1–50 only contains 50 different values — so 100 unique picks are mathematically impossible. The tool checks this and shows an error instead of looping forever. Either widen the range to at least the count you need, or untick the no-duplicates option to allow repeats.
Can I use this generator to pick a giveaway winner?
Yes — it's a common use. Number your entrants 1 to N (for example, by comment order), set the range to 1–N with a count of 1, and generate. For multiple winners, set the count higher and tick no-duplicates so nobody wins twice. Screenshot the result for transparency; the draw is cryptographically fair.
Are duplicate numbers a bug when the unique option is off?
No — with duplicates allowed, every draw is independent, so repeats are expected and statistically inevitable in larger batches. Drawing 100 numbers from 1–100 without the unique option will almost always contain repeats (the birthday paradox makes collisions likely surprisingly fast). Tick "No duplicates" whenever each value must appear only once.