Calculators & Generators tool

Random Number Generator

Generate 1 to 100 random whole numbers in any range, with both ends included, using your browser's cryptographic randomness. Free and unbiased.

Your file never leaves your device.

Inputs

Results

Simple steps

How it works

  1. 01

    Enter the minimum and maximum values.

  2. 02

    Choose how many integers to generate.

  3. 03

    Copy the locally generated list.

How the numbers are chosen

Each number comes from your browser's cryptographic random source (crypto.getRandomValues), which draws 32-bit values from the operating system. To turn a 32-bit value into a number in your range without favouring any result, the tool throws away draws from the uneven top end of the 32-bit space and draws again. This is called rejection sampling.

The common shortcut of taking the remainder (random value modulo range size) makes small numbers slightly more likely whenever the range does not divide 4,294,967,296 evenly. Rejection sampling avoids that, so every whole number from the minimum to the maximum has exactly the same chance.

Ranges, repeats and limits

Both ends are included, so 1 to 6 behaves like a die and 0 to 1 like a coin. Minimum and maximum can be negative, and the range can hold up to 4,294,967,296 different integers, for example 0 to 4,294,967,295. Only whole numbers are produced.

Each number is drawn independently, so a list of ten can contain the same value twice, just as two dice can both show a three. If you need distinct values, for example five raffle winners, generate a few more than you need and skip any repeats.

Good uses, and when to use something else

It suits everyday choices: picking a winner from numbered entries, choosing rows from a spreadsheet for a spot check, rolling dice for a board game or picking a random page to proofread.

Results are not recorded or reproducible, so nobody can check a draw afterwards. If fairness has to be shown to others, draw in front of witnesses or take a screenshot, and use an audited process for anything regulated, such as a lottery.

Good to know

Frequently asked questions

Are both endpoints included?

Yes. Minimum and maximum values are both eligible results.

How is bias avoided?

The generator uses rejection sampling with crypto.getRandomValues rather than modulo-only selection.

How many values can I make?

Generate from one to 100 integers per calculation.

Are results reproducible?

No. Cryptographic random output is not seeded or reproducible.

Are values sent to a server?

No. Numbers are generated on your device.