What Is Random Number Generator?
A free online random number generator. Generate one or many random numbers within a custom range using the Web Crypto API for secure randomness. Toggle unique-only mode, sort results, and view statistics including min, max, average, and sum.
Generating random numbers is a common requirement across many domains — from picking lottery numbers and conducting raffles to statistical sampling and game design. Random Number Generator uses the browser's Web Crypto API (crypto.getRandomValues()) to produce cryptographically secure pseudo-random numbers within a customizable range.
The tool lets you set a minimum and maximum value to define the range. You can generate anywhere from 1 to 100 numbers in a single run. Each generated number is displayed in a clean list with index numbers for easy reference. The unique-only mode ensures no duplicate numbers appear in the output, using a Fisher-Yates partial shuffle algorithm for efficiency.
Beyond the basic generation, the tool provides summary statistics: the minimum and maximum values in the generated set, the average (mean), and the sum. These statistics give you immediate insight into the distribution of your random numbers. The sort option arranges the output in ascending order, making it easier to scan the results for patterns.
The use of crypto.getRandomValues() means the random numbers are suitable for applications where unpredictability matters. This is a higher quality source than Math.random(), which uses a pseudo-random number generator that can be predictable in certain scenarios. For lottery-style drawings, contest winners, and cryptographic nonces, the Web Crypto API provides the appropriate level of randomness.