Random number generator

Enter a minimum and a maximum, say how many numbers you want, and press Generate. You can draw a single number or up to 1,000 at once, keep them unique with No repeats, sort them from smallest to largest, and copy the whole list.

Press Generate.

Updated

How to generate random numbers

  1. Set the range

    Type the lowest and highest numbers allowed. Both ends are included, so 1 to 100 can return 1 or 100. Negative numbers work too.

  2. Choose how many

    Enter any amount from 1 to 1,000. Leave No repeats ticked if each number may appear only once.

  3. Generate and copy

    Press Generate. Tick Sort results for ascending order, then press Copy to put the numbers on your clipboard, separated by commas.

How do I pick a random number between two numbers?

Type the two numbers into Minimum and Maximum, leave How many at 1 and press Generate. Every whole number in the range, including both ends, has the same chance. If you enter the numbers the wrong way round, the generator swaps them for you, and decimals are rounded to the nearest whole number.

The range can be small, like 1 to 6, or very large. The generator accepts ranges spanning up to one trillion, which is far more than a number wheel can show. The wheel is the better choice when you want an audience to watch the result appear; this page is better for big ranges and long lists.

How does "No repeats" work?

With No repeats ticked, which is the default, the generator draws numbers one at a time and throws away any number it has already produced, then draws again. The result is the same as pulling numbered tickets out of a hat without putting them back: each number can appear once at most, and every number left in the hat is equally likely on each draw.

Because of that, you cannot ask for more unique numbers than the range contains. Ask for 20 unique numbers between 1 and 10 and the page tells you that only 10 exist. Untick No repeats when duplicates are fine, for example when simulating dice-style rolls across a custom range.

Drawing raffle and ticket numbers

For a school or club raffle with numbered tickets, set the range to the tickets you sold, for example 1 to 250, and ask for as many numbers as you have prizes. Leave Sort results off: the numbers then appear in the order they were drawn, so the first number wins first prize, the second wins second prize, and so on.

If people are watching, say the range and the number of prizes before you press Generate, and read the results out straight away. Our guide to running a fair giveaway covers how to announce a draw so nobody doubts it. For a draw by name rather than number, the raffle wheel is more fun to watch.

Lottery-style picks

Lottery-style games ask for a set of different numbers from a fixed range, such as 6 numbers from 1 to 49. Set that range, enter 6, keep No repeats on and tick Sort results for a tidy ticket-style line. This is handy for classroom probability lessons and party games. It cannot predict real lottery results: every combination is equally likely, including the ones that look too neat to win.

Random sampling from a list or spreadsheet

Researchers, auditors and teachers often need a random sample: 20 survey responses out of 500, or 5 essays out of 120 to moderate. Number the rows, generate that many unique numbers across the row range, and tick Sort results so you can work down the sheet in order. If row 1 of your spreadsheet is a header, set the minimum to 2.

When you need the whole list in a random order rather than a sample, the random order generator shuffles every line for you.

Frequently asked questions

Can the random number generator avoid duplicates?

Yes. Keep No repeats ticked and every number in the result will be different. You can ask for up to as many numbers as the range contains, to a maximum of 1,000 per press.

How many numbers can I generate at once?

Up to 1,000 per press. Results are shown in a grid with thousands separators, and the Copy button puts them on your clipboard as a plain comma-separated list you can paste into a spreadsheet or message.

Are the minimum and maximum included?

Yes. Both ends of the range can be drawn. A range of 1 to 10 has ten possible numbers, and each one has a 1 in 10 chance on a single draw.

Can I use negative numbers?

Yes. Enter a negative minimum, such as -50, and a maximum such as 50. The generator works with any whole numbers, and it rounds decimals to the nearest whole number.

What is the largest range I can use?

The difference between the maximum and minimum can be up to one trillion. For small ranges you want to show on screen, such as 1 to 100, a number wheel is a more visual alternative.