free tool, no sign-up
Random Number Generator
Pick a fair random integer between any two whole numbers, including a random number generator 1-4, dice rolls, and a number generator 1-100.
Quick ranges
One click sets the range and draws. 1–6 is a standard die.
No numbers yet. Set a range and press Generate, or click a preset.
- 1–4: four teams, four corners, or a four-sided die
- 1–6: one die; set How many to 2 and leave duplicates on for a pair
- 1–20: a twenty-sided die, or one fair pick from twenty names
- 1–100: turn duplicates off to deal out different numbers
The Random Number Generator returns whole numbers with an equal chance for every integer from the minimum through the maximum. Choose how many results you need, keep duplicates on for dice or turn them off when each pick must be different, and sort the list from smallest to largest when that is easier to read. Presets draw in one click, including a random number generator 1-6 for a die, a 1-5 random number generator for five groups, and a 1-20 number generator for a twenty-sided die, along with 1–10 and 1–100. Copy the list when you want it on the board or in a document. The draw runs in your browser with crypto.getRandomValues when the browser provides it, which suits classroom dice and fair picks.
Minimum, maximum, and how many
Three boxes control the draw. Minimum and Maximum are the smallest and largest whole numbers you will accept, and both ends count. A random number generator 1-4, with those boxes set to 1 and 4, can return 1, 2, 3, or 4. It cannot return 0 or 5. How many is the length of the list, from a single random integer up to 1,000.
Press Generate to draw. Editing a box does not replace the numbers already on the screen. Copy puts the current list on the clipboard, one number per line, without thousands separators. Thousands commas, as in 1,000, are ignored. A comma used as a decimal point, as in 2,5, is refused like any other decimal.
One-click ranges from 1–4 to 1–100
The six preset buttons fill Minimum and Maximum and draw immediately. 1–4 covers four teams, answers A through D, or the classroom game Four Corners. 1–5 is a 1-5 random number generator for five groups or five stations. 1–6 is a random number generator 1-6, the same faces as one die. 1–10 is a score out of ten, or ten stations. 1–20 is a 1-20 number generator for a twenty-sided die or a list of twenty. 1–100 is a number generator 1-100 for tickets numbered up to 100.
A preset keeps whatever is already in How many, and it keeps the duplicate and sort settings. If those settings cannot fit the new range, the previous list stays on screen and a note under the boxes explains why. The tool does not quietly shorten the list.
Duplicates and sorted lists
Allow duplicates is on at the start, which is what dice need. Two rolls from 1 to 6 can both be 4, the same way two real dice can. Turn it off when every result must be a different number, such as five distinct table numbers from 1 to 20. The switch applies the next time you press Generate or a preset. It does not rewrite the list already showing. A 1–4 range has four integers, so five unique picks will not fit, and the tool says so instead of repeating one.
Sort results is off at the start, so the list stays in draw order. Leave it off when the first number picks a student and the second picks a job. Turn it on to rearrange that same draw from smallest to largest. Sorting does not draw again, and it updates the list immediately. Copy follows the order on screen, so a sorted list is copied sorted.
How a fair random integer is chosen
Every whole number from the minimum through the maximum has the same chance on each draw. The tool does not favor the middle, the low end, or numbers that have not come up yet. On a 1–6 draw, 6 is as likely as 1. A repeat is a normal result while duplicates are allowed, not a sign that the draw is stuck.
In current browsers the pick uses crypto.getRandomValues, then discards values that would make some remainders slightly more common than others. That keeps the chances even when the range is not a power of two. If that function is missing, the tool uses Math.random instead. Either way the choice is made in the page, and the numbers you type are not sent anywhere.
Classroom dice and fair picks
For one die, click 1–6 and leave How many at 1. For two dice, set How many to 2 and leave Allow duplicates on. Each result is one face. The tool does not add them, so doubles stay visible as two matching numbers. A four-sided die is the 1–4 preset. A twenty-sided die is 1–20.
Fair picks use the same boxes. Number the students, jobs, or questions, set Minimum to 1, and set Maximum to the last number. One result chooses a single person. A longer list with duplicates off deals out a random order and does not repeat anyone. Leave Sort results off when that order is the point, such as who goes first or which group presents. The draw does not prefer the top of the roster.
Ranges the generator turns down
If the minimum is higher than the maximum, there is nothing to draw. The note asks you to lower the minimum or raise the maximum. The boxes are not swapped for you, so a reversed range is never treated as valid in silence.
Blank boxes, words, and decimals are refused, because this draws a random integer only. How many must be from 1 to 1,000, so a stray extra digit cannot ask the page for a huge list. Each bound must sit between -1,000,000,000 and 1,000,000,000. Wider numbers are turned down so every value in the range can keep an equal chance without building an enormous list in memory.
Frequently Asked Questions
How do I use a random number generator 1-4?
Click the 1–4 preset, or type 1 and 4 into Minimum and Maximum and press Generate. The result is 1, 2, 3, or 4, each with the same chance.
Can I use this as a number generator 1-100?
Yes. The 1–100 preset sets that range and draws immediately. To make a list, set How many first, then click 1–100.
Is the random number generator 1-6 the same as rolling a die?
For one standard die, yes. Click 1–6 with How many set to 1. For two dice, set How many to 2 and leave Allow duplicates on. Each result is one face, and the tool does not total them.
What is a 1-5 random number generator useful for?
Five teams, five stations, or a choice with five options. Click 1–5. Both 1 and 5 can come up.
How do I run a 1-20 number generator?
Click the 1–20 preset. That matches a twenty-sided die, or one fair pick from a numbered list of twenty.
Can the same number come up twice?
Yes, while Allow duplicates is on. Turn it off and every number in that list is different. The range still cannot produce more unique values than it contains.
Is it fair enough for a classroom draw?
Each whole number in the range has an equal chance, and earlier results are not remembered. Browsers that support it use crypto.getRandomValues, with extra values thrown out so the odds stay even. It is meant for classroom dice and fair picks, not for gambling.
Why did it reject my range?
The minimum is above the maximum, a box is blank or not a whole number, How many is outside 1 to 1,000, you asked for more unique numbers than the range contains, or a bound is outside -1,000,000,000 to 1,000,000,000. The note under the boxes says which one it was.