How to use the Random Number Generator
- Enter a Minimum and a Maximum. Both values can appear in the results, and negative numbers are allowed.
- Set How many numbers to pick at once. You can pick up to 1,000.
- Turn on No repeats if a number must not come up twice. Turn on Sort to list the results in order.
- Press Generate, or press Enter in any input box, to see your results. Use Copy results to copy the numbers as a comma-separated list.
Random numbers with no repeats vs. repeats allowed: what's the difference?
No repeats works like drawing tickets from a hat without putting them back. If you pick 30 numbers from 1–30, every number from 1 to 30 appears exactly once in a random order. That makes it useful for seating charts or for deciding who presents first. You can't pick more numbers than the range contains.
Repeats allowed works like putting each ticket back in the hat before the next draw. Use it to simulate several dice rolls or to build a number where each digit is independent, such as a 4-digit PIN. For example, picking 4 digits from 0–9 with repeats allowed gives an equal chance to all 10,000 combinations from 0000 to 9999.
Is a random number generator truly random?
Computers generate random numbers in two main ways. Math.random, which many ordinary programs use, is fast. However, it's a pseudorandom generator, so anyone who knows its internal state can predict the next value. Tooljip uses the browser's cryptographically secure random number generator (crypto.getRandomValues) instead. It draws on unpredictable data collected by your operating system and is the same kind of generator used to create passwords and security keys.
Fitting a random value to a range can introduce a slight bias, known as modulo bias. To prevent it, the tool discards any random value that doesn't divide evenly into the range and draws again. As a result, every number in the range has exactly the same chance of being picked.
Ways to use a random number picker
| Use | Example settings |
|---|---|
| Raffle or giveaway (ticket numbers) | 1 to the number of entries, pick 1 (or the number of winners), no repeats |
| Classroom seating chart | 1 to the number of students, pick as many as there are students, no repeats |
| Filling a bingo card | 1–75, pick 25, no repeats |
| Replacing a die | 1–6, pick 1 |
| Temporary numeric PIN | 0–9, pick 4–6, repeats allowed |
For lottery-style picks, the lottery number generator is easier to use because it also lets you choose numbers to always include or exclude. To draw from a list of names, try the spinning wheel. For real account passwords, the password generator is much safer because it mixes letters, numbers and symbols.