Random Number Generator
Generate random numbers between any range. Pick single or multiple numbers, with or without repeats. Press Space to generate instantly.
Keyboard shortcut: Space bar
Best for: Picking a winner from a numbered list, generating test values within a set range, and producing sample IDs
Limitations: Uses the browser random number generator, which is fine for testing and draws but not for cryptographic use
Best suited for: Teachers running classroom draws and developers generating quick test values
How to Use
Frequently Asked Questions
Is this truly random?
This uses JavaScript's Math.random(), a pseudorandom number generator (PRNG). It passes statistical tests for randomness and is fine for games, decisions, and simulations. For cryptographic security, use the Password Generator which uses crypto.getRandomValues().
How do I generate a random number in a range?
Set min and max to your desired boundaries and click Generate. The formula used is Math.floor(Math.random() * (max - min + 1)) + min, which gives an integer where both endpoints are equally likely.
Can I generate lottery numbers?
Yes. Click the "Lottery (1-49, pick 6)" quick chip to auto-fill the settings, then click Generate. The no-repeats option ensures all 6 numbers are unique. Adjust the range for your local lottery format.
What is the difference between random and pseudorandom?
True random numbers come from physical processes like atmospheric noise. Pseudorandom numbers use mathematical algorithms starting from a seed value. Both produce statistically uniform distributions. For everyday use, pseudorandom is perfectly adequate.
How do I pick a random number between 1 and 10?
Set min to 1, max to 10, count to 1, and click Generate or press Space. Each number from 1 to 10 has an equal 10% probability of being selected.
About This Generator
This generator produces pseudorandom numbers using your browser's cryptographic random number API, which produces results statistically indistinguishable from true randomness for practical purposes. Each generation is independent - past results do not influence future ones.
Common Uses
Random number generators are used for statistical sampling, classroom activities like choosing who presents first, prize draws and lotteries, game development, scientific simulations, and A/B testing to assign users to control or treatment groups.
Choosing a Range and Mode
Set the minimum and maximum to match your list inclusively, so 250 entries means 1 to 250. Use the unique option when drawing several winners, otherwise the same number can appear twice. For anything security related, such as a password or token, use a purpose built generator rather than this one, since unpredictability to an attacker is a different requirement from fairness in a draw.