Random Number Generator
Pick one random number or a whole set. Choose your range, decide how many numbers you need, and every value in the range has an equal chance of coming up.
Random Number Generator
Set your range, choose how many numbers you need, and generate.
Your Random Number
—Both the minimum and the maximum can come up. Numbers are generated in your browser and are not sent to our server.
What is a random number generator?
A random number generator (RNG) picks a number from a range you choose, and every number in that range has the same chance of coming up. It is a quick way to make a fair pick when you do not want to choose yourself, or when other people need to trust that you did not.
How to use this random number generator
- Enter the lowest number in Minimum Value and the highest in Maximum Value.
- Choose how many numbers you need and how many decimal places, if any.
- Untick Allow duplicates if every number must be different, then press Generate Random Number.
Both ends of your range can come up, so 1 to 10 can return 1 or 10. Negative values work too, for example -50 to 50. Use the copy button to paste your numbers wherever you need them. If the minimum is higher than the maximum, you will see a message asking you to fix the range.
What people use a random number for
- Giveaways and raffles: Number your entries from 1 to the total, then untick Allow duplicates and ask for as many winners as you need. For 3 winners from 250 entries, use 1 to 250, a count of 3, and no duplicates.
- Games and turn order: Decide who goes first, or roll a custom die such as 1 to 20.
- Classroom and team picks: Number the names on a list and let the generator choose, so nobody feels singled out.
- Quick decisions: Give each option a number and pick one.
- Spot checks and sampling: Choose a few numbered rows or records to review when you cannot check them all.
- Decimals: Create test values or sample data, for example 0 to 1 with 2 decimal places.
If you run a public giveaway, share your range and keep a screenshot of the result so entrants can see the draw was fair.
How the numbers are picked
Your browser supplies random bits through the Web Crypto API. The tool turns those bits into a whole number inside your range. To keep things fair, it discards any value that would favour the lower numbers (a standard method called rejection sampling), so each number has the same chance. Decimals are made by working in steps of 0.1, 0.01 and so on, then dividing back. If a browser does not support Web Crypto, the tool falls back to the standard Math.random() function.
Result = (Min × 10d + k) ÷ 10d k = a whole number chosen at random from 0 to (Max − Min) × 10d Here d is the number of decimal places. For 1 to 10 with no decimals (d = 0), k is a whole number from 0 to 9, and adding 1 gives a result from 1 to 10. Earlier results never affect the next one, so when duplicates are allowed the same number can appear twice in a row. That is normal for a fair generator, not a bug.
Pseudo-random vs. truly random
A computer cannot produce perfect randomness on its own. Web Crypto draws on your device's secure random source, which is unpredictable and far stronger than a basic generator, and more than good enough for draws, games and everyday picks. Methods that measure physical noise are called truly random, but for everyday use the difference does not matter. This tool is for picking numbers, though, not for creating passwords or security keys. For that, use our Password Generator.
Frequently asked questions
Built and maintained by the Toolnix team. Last updated October 2026.