Random Number Generator
Generate random integers in any range, locally.
Random Number Generator creates cryptographically strong random integers directly in your browser. Set a minimum, maximum, and how many numbers you need—perfect for raffles, sampling, games, and quick decisions without uploading anything.
How it works
Enter a minimum and maximum value plus how many numbers to generate, then click Generate. The tool draws uniform random integers using crypto.getRandomValues with rejection sampling, which avoids the bias that simple modulo tricks introduce.
Benefits
- Cryptographically secure randomness via Web Crypto
- Unbiased uniform distribution across your chosen range
- Supports negative ranges and large batches
- No server upload—numbers stay on your device
Use cases
- Draw winners for a raffle or giveaway
- Pick random samples for testing or statistics
- Generate dice-like or lottery-style numbers for games
- Create randomized test fixtures with numeric ranges
Best practices
- Keep min and max reasonable for your use case to avoid confusion
- Use larger batches when you need a statistical sample
- Regenerate if you suspect a draw was interrupted
- Combine with List Randomizer for randomizing named entries
Common mistakes
- Setting min greater than max, which is not a valid range
- Assuming results are unique when duplicates can occur
- Using Math.random for sensitive draws instead of this tool
- Forgetting that count changes require clicking Generate again
Privacy
Numbers are generated locally with crypto.getRandomValues. ToolHub does not receive, log, or store generated numbers unless you separately enable on-device history.
Frequently asked questions
- How random are the generated numbers?
- Each number is drawn using crypto.getRandomValues with rejection sampling, which removes modulo bias and provides cryptographically strong randomness suitable for draws, giveaways, and sampling.
- Can I generate negative numbers?
- Yes. Set a negative minimum value and the generator will include negative integers in the output range, as long as min stays less than or equal to max.
- Are duplicate numbers allowed?
- By default the generator picks each value independently, so duplicates can appear across multiple numbers—just like rolling a die more than once. Use List Randomizer if you need unique picks from a fixed list.
- What is the maximum batch size?
- You can generate up to 1,000 numbers in a single batch. Increase the count field and click Generate to produce a larger list.
- Does this tool upload my inputs?
- No. Random Number Generator runs entirely in your browser using the Web Crypto API. Nothing is sent to ToolHub servers.
- Can I use this for lottery or raffle draws?
- Yes, many people use it for quick raffles and picks. For regulated lotteries, confirm your jurisdiction's requirements for certified randomness sources.
Related tools
Dice Roller
random
Roll virtual dice with fair, local randomness.
- dice
- random
- generator
- rpg
Coin Flip
random
Flip virtual coins with fair, local randomness.
- coin
- flip
- random
- generator
UUID Generator
random
Generate UUID v4 and v7 IDs locally with bulk output.
- uuid
- guid
- random
- generator
Password Generator
random
Secure local password generator with strength meter.
- password
- security
- random
- generator
Random String Generator
random
Generate random strings with custom character sets.
- random
- string
- generator
- token
Yes/No Generator
random
Get a weighted random Yes or No answer.
- yes-no
- random
- generator
- decision