← All tools

Random number generator

Pick fair random numbers in any range — whole or with decimals, with or without repeats — or draw names from a list, split people into teams, roll dice and flip coins. Every result comes from your browser's secure random generator, so each outcome is equally likely.

Press Generate.

Enjoying Random Number Generator?Your review and ideas shape what we build next.

Review Random Number Generator

Please don't include file contents or passwords.

About the Random Number Generator

Get truly fair random results for games, giveaways, classrooms, research and everyday decisions. Generate whole numbers or numbers with decimals between any two values, one or up to 10,000 at a time, with or without repeats and sorted if you like. Switch to Pick from a list to draw winners or choose who goes first, Teams to split a group into even teams, or Dice & coins to roll any number of 4- to 100-sided dice or flip coins. Results come from your browser's cryptographically secure random generator with rejection sampling, which keeps every outcome exactly equally likely, unlike the simple methods many sites use.

How to use it

  1. Choose Numbers, Pick from a list, Teams or Dice & coins.
  2. For numbers, set From and To, how many, and the decimal places, or tap a preset such as 1–100 or Lottery 6 of 49.
  3. Tick No repeats to draw like balls from a bag, and choose the order.
  4. For a list or teams, type or paste the names, one per line.
  5. Press Generate, Pick or Make teams, then copy or download the results.

Tip: For a fair giveaway, paste the entrants into Pick from a list with No repeats ticked, share your screen or record it, and pick once. Picking again until you like the result undoes the fairness.

What “fair” means here

Many random number tools take a big random number and use the remainder after dividing by the size of the range. That makes small numbers slightly more likely whenever the range doesn't divide evenly. This generator throws away the few values that would cause the imbalance and draws again (rejection sampling), so in a range of 1 to 100 each number has exactly a 1 in 100 chance.

The randomness comes from crypto.getRandomValues, the same source browsers use for encryption keys, rather than Math.random. It can't be predicted from earlier results, which matters for draws and prizes.

Ways to use it

With or without repeats
Without repeats is a draw: once 7 comes out it can't come out again, like a raffle. With repeats each number is independent, like rolling a die several times.
Decimals
Choose 1 to 6 decimal places for values such as 0.37 or 12.5, for sampling and simulations. Every value at that precision is equally likely.
Lottery numbers
The 6 of 49 preset draws six different numbers from 1 to 49; change the range and count for other lotteries.
PIN codes
The 4-digit PIN preset gives 0000 to 9999, keeping the leading zeros.
Teams
Names are shuffled and dealt in turn, so team sizes differ by at most one.
Dice
Roll up to 100 dice with 4, 6, 8, 10, 12, 20 or 100 sides; the total is added up for you.

Random numbers in classrooms and research

Teachers use the list picker to call on students and Teams to form groups without arguments. For research, numbers without repeats give a simple random sample: number the people or items 1 to N, ask for the sample size you need with No repeats, and sort the result. The count, sum, average, lowest and highest values appear under the numbers, which helps check a batch at a glance.

Is it truly random? Computers produce random numbers from unpredictable physical noise collected by the operating system, stretched by a cryptographic algorithm. For draws, games and sampling it is as good as random can be; for official lotteries, rules usually require certified equipment.

Picking winners and making draws

For a social media giveaway, export or copy the names of everyone who entered, remove duplicate entries first (the line sorter can do that), and paste them into Pick from a list. Choose how many winners you need with No repeats ticked, so the same person can't win twice, and pick once. Taking a screenshot or recording the screen gives entrants proof that the draw was fair.

For a raffle with numbered tickets, use Numbers instead: set the range to the first and last ticket numbers, the count to the number of prizes, and tick No repeats. The first number drawn wins the first prize, the second number the second prize, and so on, so keep the order as drawn.

Common questions about chance

Can the same number come up twice in a row?
Yes, with repeats allowed. A fair generator has no memory, so after rolling a 6 the next roll is still 1 in 6. Streaks are normal.
Are some numbers lucky?
No. Over many draws every number comes up about equally often; any single draw is unpredictable.
How likely is a lottery win?
For 6 of 49 there are 13,983,816 possible combinations, so one ticket has about a 1 in 14 million chance.

Tips and tricks

Ties

To break a tie between two people, flip a coin; for more people, pick one from a list.

Order a list

Pick every item from a list with No repeats to shuffle it into a random order.

Big batches

Up to 10,000 numbers at a time; download them as a text file.

Negative numbers

Ranges can include negatives, such as −50 to 50.

Questions

How do I pick a random number between 1 and 100?

Tap the 1–100 preset, or set From to 1 and To to 100, and press Generate.

Can I generate random numbers without repeats?

Yes. Tick No repeats. The generator tells you if you ask for more numbers than the range holds.

How do I pick a random name from a list?

Choose Pick from a list, paste the names one per line and press Pick.

Is this random number generator really random?

It uses your browser's cryptographically secure generator and rejection sampling, so results can't be predicted and every outcome is equally likely.

Can it roll dice?

Yes. Dice & coins rolls up to 100 dice with 4 to 100 sides and flips up to 1,000 coins.

Is anything sent to a server?

No. The tool runs entirely in your browser, on your device. Nothing you type or make is uploaded, saved or logged.

Related tools

Updated