Calculators
Home › Calculators › Random Number Generator

Random Number Generator

Uniform random numbers in your range, as many as you need, duplicates on or off.

Generate random numbers

Every click draws a fresh set from the browser's random generator.

Quick answer: Set a minimum, a maximum and a count. Duplicates off samples without replacement, so the count cannot exceed the number of values in the range.

What "random" means in this generator

Each number this tool produces is drawn uniformly: every value in the range is equally likely, and draws do not influence each other (unless you switch duplicates off, which samples without replacement). The engine is the browser's built-in Math.random, a pseudorandom generator: it runs a deterministic algorithm from a seed you never see, producing sequences that pass statistical tests for uniformity and independence well enough for simulations, sampling exercises, games and teaching. It is not built for cryptography; do not generate passwords or keys with it.

With and without replacement

The toggle matters more than the range. Drawing with replacement models dice, coins and most Monte Carlo work: the pool never changes, and repeats are not just allowed, they are expected (in 10 draws from 1 to 100, a repeated value somewhere is unremarkable; in 100 draws it is a near-certainty by the birthday effect). Drawing without replacement models lotteries, shuffled decks and survey samples from a list: each value can appear once at most, which is why the count cannot exceed the size of the range.

Worked example

A teacher needs 12 distinct students from a class numbered 1 to 30. Set minimum 1, maximum 30, count 12, duplicates off: the tool returns 12 different numbers in one click, a simple random sample of the class list. Leave duplicates on and the same settings mimic 12 independent dice-style picks, where a student could be picked twice.

Watch out

Rerolling until the draw "looks random". Human eyes flag clusters and repeats as suspicious, but genuine uniform draws are full of them. A draw with no repeats and even spacing is the unusual one; filtering for prettiness quietly destroys the uniformity you wanted.

Frequently asked questions

Are these numbers truly random?

They are pseudorandom: generated by an algorithm, but statistically uniform and unpredictable enough for simulations, sampling and games. They are not suitable for passwords, keys or anything security-critical.

Why did I get the same number twice?

Because duplicates are on. With replacement, every draw is independent, so repeats happen naturally. Turn duplicates off to sample without replacement.

How many numbers can I generate at once?

Up to 10,000 per click. For a no-duplicates draw, the count cannot exceed the number of values in the range.