Random Number Generator

Updated July 2026

Pick one or many random numbers between any minimum and maximum. Turn on no repeats for unique draws, or sort the results — handy for giveaways, raffles, dice and lotteries. Everything runs privately in your browser.

This tool generates random numbers between the minimum and maximum you choose (both inclusive). It uses cryptographically strong randomness from your browser's Web Crypto API with rejection sampling, so every value in the range is equally likely and nothing is sent to a server.
Both minimum and maximum are inclusive.
Result

How this random number generator works

A random number generator picks a value from a range where every possible number is equally likely. This tool lets you set the minimum and maximum (both inclusive), choose how many numbers to draw, and optionally require that they are unique or sorted.

Under the hood it uses your browser's Web Crypto API (crypto.getRandomValues) to gather random bytes. To turn those bytes into a number in your range without bias, it uses rejection sampling: it discards any raw value that falls outside the largest exact multiple of the range size, so no number is slightly more likely than the others. A naive modulo approach would quietly favour the lower part of the range — this avoids that.

Worked example: for a range of 1 to 6, the tool maps 8-bit bytes onto the six outcomes and throws away the few byte values that would skew the odds, re-drawing until it lands on a clean result. Over many rolls each face appears about one sixth of the time.

Reference note: the output is cryptographically strong pseudorandomness suitable for giveaways, games and everyday use. If a browser does not expose the Web Crypto API, the tool falls back to Math.random, which is still fine for casual use but not for security-sensitive purposes.

Frequently asked questions

How does this generate random numbers?
It uses your browser's built-in crypto.getRandomValues to draw random bytes, then applies rejection sampling so every integer in your chosen range is equally likely. This avoids the modulo bias of a naive remainder approach. If a browser lacks the Web Crypto API, it falls back to Math.random.
Is it truly random?
It is cryptographically strong pseudorandomness, suitable for giveaways, games and everyday use. Technically it comes from a CSPRNG seeded by the operating system rather than a physical source, but for practical purposes the output is unpredictable and unbiased.
Can I get numbers without repeats?
Yes. Tick the unique / no repeats box and every number drawn will be distinct — as long as you ask for no more numbers than the range can hold. You cannot draw 50 unique numbers between 1 and 10.
Is the minimum and maximum inclusive?
Yes. Both the minimum and the maximum are included in the range of possible results. A range of 1 to 6 can return any of 1, 2, 3, 4, 5 or 6.
Is it good for a giveaway or raffle?
Yes. Assign each entry a number, set the range to cover all entries, turn on no repeats if you are drawing several winners, and generate. The draw is unbiased and runs in front of you, so it is easy to do transparently.
Does it store my data?
No. Everything runs locally in your browser. Your inputs and the generated numbers are never sent to a server, and nothing is saved unless you copy the results yourself.
⚡ Random Number Generator — by larely ↗

Related tools

Zodiac Sign Calculator

Find your western zodiac sign and Chinese zodiac animal from your birth date.

Dice Roller

Roll virtual dice with dice notation, online and free.

Coin Flip

Flip a fair coin online — heads or tails — and flip many at once.

Secret Santa Generator

Randomly assign Secret Santa pairs for a group, with no self-matches.

Random Team Generator

Randomly split a list of names into fair teams by count or size.

Image Compressor & Converter

Compress, resize and convert JPEG, PNG and WebP images in your browser — nothing is upl…

Cipher Encoder & Decoder

Encode and decode Caesar, ROT13, Vigenère and Atbash ciphers, with brute-force.

Username Generator

Generate cool, aesthetic, gamer or professional usernames and handles instantly.

Business Name Generator

Generate brandable business and company name ideas from a keyword.

Email Signature Generator

Create a professional HTML email signature for Gmail or Outlook, in your browser.

Golden Hour Calculator

Sunrise, sunset, golden & blue hour and moon phase for any location and date — for phot…

Catering Calculator

How much food, non-alcoholic drinks, ice and cake to serve for any number of party guests.

Browse all 251 free tools →