What it does
This tool generates whole numbers between a minimum and a maximum. Both ends are included. You choose how many values you want, whether they must be distinct, whether to sort them, and how to separate the output. Every value comes from the browser; nothing is fetched from a server or chosen in advance.
It is the digital equivalent of drawing numbered slips from a hat, with one important difference: when duplicates are off, the slip is not put back. That is sampling without replacement. It is the right model for picking distinct raffle winners, assigning unique test IDs, or choosing a subset of numbered items.
Unique values and order
With “No duplicates” on, each value appears at most once. The tool checks the requested count against the size of the range before generating. A request for 12 unique numbers from 1 to 10 is impossible, so it is reported as an error instead of returning a shorter list. With the option off, the same value can appear repeatedly, which is what you want for independent draws.
“As generated” keeps the random arrival order. “Lowest to highest” and “Highest to lowest” sort the result after generation. Sorting changes only the presentation; it does not make the values less random. The separator controls whether the output is one number per line, a space-separated row, or a comma-separated list.
Where the randomness comes from
Modern browsers expose crypto.getRandomValues, which draws from the operating system’s entropy pool. The generator uses that source when it is present. To avoid modulo bias, it rejects values outside the largest evenly divisible part of the random range instead of folding every result with a remainder. That detail matters when the requested range does not divide evenly into a power of two.
Very old browsers may not provide Web Crypto. In that case the page falls back to the JavaScript pseudo-random generator so the tool still works. A fallback is not equivalent to a cryptographic source, and the page says so. For a game, a sample, or a test fixture, either source is fine. For a password or a long-lived key, use a dedicated secrets generator that refuses to run without a strong source.
Examples
Before
Minimum 1, maximum 100, count 10After
73
18
94
42
7
61
29
88
3
50Your result will be different because there is no seed. Every number is in the inclusive range, and no number repeats. If you press “Generate again,” the whole sample is redrawn; it does not keep the old values and add new ones.
Before
Minimum 1, maximum 100, count 10After
3
7
18
29
42
50
61
73
88
94Sorting makes the list easier to scan and compare, but it also reveals the shape of the sample at a glance. The underlying draw is the same kind of process; only the display order changed. A sorted list is still random as a set, even though it is no longer random as a sequence.
Limits worth knowing
- Whole numbers only. Decimal bounds are rejected. If you need a random amount of money or a random percentage, generate an integer in a scaled range and divide in your own code.
- The range must fit safe integer arithmetic. Values are JavaScript safe integers. A range wider than the safe-integer span cannot be sampled precisely and is refused rather than approximated.
- No seed and no history. You cannot reproduce a draw from the page. Save the result if it needs to be audited. Regenerating replaces the visible output.
- A fallback is not a guarantee. In a browser without Web Crypto, the source is the built-in pseudo-random generator. That is acceptable for casual use but not for secrets.
- A random draw is not a fair draw by itself. If your selection process maps numbers to people or tickets unevenly, the randomness of the number does not fix the mapping. Audit the whole process, not just the generator.
Page updated