Generate a random integer between inclusive bounds using browser cryptographic randomness.
How it works
Rejection sampling maps 32-bit cryptographic values uniformly to the selected interval. Bounds must be safe integers and span at most 2³² possible values. This is not a certified gaming or lottery service.
Worked example
Choosing minimum 1 and maximum 6 gives one of the six possible die faces with equal probability per draw.
When is a random integer useful?
A random whole number works well for choosing an item from a numbered list, rolling a virtual die, or assigning people to groups by index. Set the minimum to 1 and the maximum to the list length, then use the result as the position. Because both bounds are included, a range from 1 to 6 covers every face of a standard die. Use it for quick, low-stakes selections where a fair draw is enough, such as ordering a classroom presentation.
How should I read a single result?
Each draw stands alone. A number that appeared a moment ago has the same chance as any other number on the next draw, so a repeat is not a sign of a problem. Over many draws, counts across the range tend to even out, but any short run can look lopsided. If you need a sequence with no repeats, a single integer draw does not provide that, and you would need to track the results yourself. The minimum and maximum are as likely to appear as any value between them.
What limits should I keep in mind?
Bounds must be safe integers, and the span cannot exceed 2 to the 32nd power possible values, so very wide ranges fall outside the tool. The generator is not a certified gaming, lottery or prize service. If an outcome must be audited or legally verifiable, use a method that meets that requirement rather than a browser demonstration. The tool also offers no seed, so a previous sequence cannot be reproduced.
Frequently asked questions
Is this free to use?
Yes. No signup is required.
Does the input leave my device?
The operation runs locally in your browser.
Are there limitations?
Rejection sampling maps 32-bit cryptographic values uniformly to the selected interval. Bounds must be safe integers and span at most 2³² possible values. This is not a certified gaming or lottery service.
Can I reproduce a sequence of results?
No. The generator has no seed, so each run is independent and cannot be replayed. For repeatable sequences in testing, use a seeded pseudorandom generator in your own code, where you control the starting value.
What if I enter the minimum higher than the maximum?
Put the smaller number in the minimum field. The bounds describe one interval, so reversing them changes what the tool is asked to do. Bounds must also be whole numbers within the safe integer range.
Can the generator return several unique numbers at once?
This tool returns one integer per draw, and repeated draws can repeat values. To get unique picks, discard any repeat and draw again, or list every value in the range and shuffle it. Track the results you have already accepted.
Is Random Number Generator free and private?
Yes. It is free, needs no account and runs in your browser, so the values you enter are not sent to a server.