Skip to content

Random Number Generator

Generate random numbers between any two values. Choose how many you need, whether repeats are allowed, and copy the whole set out in one click.

Category
Generators
Updated
Cost
Free · no sign-up

Up to 1,000 at a time.

Repeats
Order

Your numbers

Set a range and press Generate.

What makes a draw fair

A fair draw gives every number in the range exactly the same chance. That sounds automatic, and it isn't. The usual one-line implementation takes a random value from the machine and wraps it with a remainder — value % range — which quietly favours the low end of the range whenever the range doesn't divide evenly into the source.

This generator throws away the small tail of source values that would cause that skew and draws again, so nothing is nudged. It also uses the browser's cryptographic random source, the same one used to mint security tokens, rather than the ordinary Math.random.

Repeats, and why they matter

The All different setting is the one that changes the character of the draw:

  • All different — no number can appear twice. This is what a raffle, a lottery line or picking several winners needs, because a real draw removes each ticket once it's out.
  • Allow repeats — every number is drawn independently, exactly like rolling the same die several times. Two sixes in a row is not a bug.

Ask for more different numbers than the range holds and there's no valid answer — six unique numbers between 1 and 5 doesn't exist — so the tool says so rather than hanging.

Common ranges

To do thisSet the range
Roll a die1 to 6
Flip a coin0 to 1
Pick a lottery line1 to 49, six numbers, all different
Draw a winner from a list1 to however many entries
Pick a random percentage0 to 100

What this is not for

Nothing you generate is transmitted or stored. Reloading clears it, so copy anything you want to keep.

How to use the Random Number Generator

Three steps, no sign-up.

  1. Set the range

    Enter the lowest and highest number you want to draw from. Both ends are included, so 1 to 6 can return a 1 or a 6.

  2. Choose how many and whether repeats are allowed

    Ask for a single number or a whole set. Turn off repeats for a raffle or a lottery line, where each number has to be different.

  3. Generate and copy

    Press Generate for a fresh draw. Copy takes the whole set to your clipboard as a comma-separated list.

Worked examples

A single dice roll

Inputs
1 to 6 · 1 number
Result
4

A six-number lottery line, no repeats

Inputs
1 to 49 · 6 numbers · repeats off
Result
3, 11, 24, 27, 38, 45

Picking a winner from 250 entries

Inputs
1 to 250 · 1 number
Result
137

Frequently asked questions

Are the numbers really random?
They come from your browser's cryptographic random number generator, the same source used for security tokens, rather than the ordinary Math.random. The draw is also corrected for modulo bias, so every number in the range is equally likely — a naive implementation quietly favours the lower numbers.
Are both the minimum and maximum included?
Yes. The range is inclusive at both ends, so 1 to 10 can return a 1 or a 10.
What does turning off repeats do?
Every number in the set will be different, which is what you want for raffles, lottery lines and picking several winners. You cannot draw more numbers than the range holds — 8 unique numbers from 1 to 5 is impossible, and the tool says so rather than looping forever.
Is anything sent anywhere?
No. The draw happens in your browser and nothing is transmitted or stored. Reloading the page clears it, so copy anything you want to keep.
Can I use this for a prize draw?
It is fair enough for informal draws, raffles and picking a winner from a list. For anything legally regulated, use whatever certified process the rules require — this is a browser tool, not an audited one.