Free random number generator. Generate random integers or decimals within any range, with support for multiple results and no-duplicate mode.
A random number generator produces one or more numbers within a range you set, either as whole integers or decimals, using a random source so each result is unpredictable and (optionally) free of duplicates.
Last updated:
Random Number Generator
A random number generator sounds simple, but the useful version needs more than just "give me a random number" ā you need to control the range, decide between whole numbers and decimals, and sometimes generate several numbers at once without any repeats. This tool covers all of that in one place.
Under the hood, it draws from your browser's cryptographically secure random source when available, which produces higher-quality randomness than the basic random functions built into most programming languages ā useful whether you're picking a raffle winner or just settling an argument about who does the dishes.
Integers vs. Decimals
Whole numbers are the default choice for most everyday uses ā dice rolls, lottery numbers, picking a random team member, or choosing a winning ticket number. They're easy to work with and there's no ambiguity about the result.
Decimal mode is useful when you need a random value that isn't a round number ā simulating a measurement, generating test data for a spreadsheet, or picking a random percentage or price point. You control exactly how many digits appear after the decimal point.
Avoiding Repeats
When you're drawing multiple random numbers ā for a giveaway with several winners, a set of unique lottery picks, or a shuffled list of IDs ā you often need each number to be different from the others. Turning off duplicates ensures no number appears twice in the same batch.
There's a hard limit here: if your range is smaller than the number of unique values you're asking for, it's mathematically impossible to satisfy the request. This tool checks for that and lets you know instead of returning an incomplete or incorrect result.
Common Uses
Beyond games and raffles, random number generators are a staple in statistics for random sampling, in software testing for generating realistic test data, and in research for randomized assignment of participants to study groups.
They're also handy for everyday decisions ā picking a restaurant from a shortlist, assigning turn order in a game night, or breaking a tie ā situations where you want a genuinely unbiased outcome rather than a guess.
Practical Use Cases
Running a raffle or giveaway
Picking a fair, unbiased winner from a numbered list of entries.
Rolling virtual dice or drawing lots
Settling games, decisions, or turn order without a physical die.
Generating test data
Creating sample numeric values for spreadsheets, databases, or software testing.
Random sampling for research
Selecting a random subset of items or participants from a larger set.
Making an unbiased decision
Letting chance decide between options instead of relying on gut feeling.
This tool uses your browser's cryptographically secure random number source (the Web Crypto API) when available, falling back to standard pseudo-random generation otherwise. This is suitable for games, giveaways, sampling, and general everyday use, though not for cryptographic key generation.
Yes ā turn off "Allow duplicates" and each generated number will be unique. Keep in mind the range must be large enough to hold as many unique numbers as you're requesting; for example, you can't generate 10 unique whole numbers from a range of 1 to 5.
Whole numbers (integers) have no fractional part, like 7 or 42. Decimals include digits after the decimal point, with the number of digits controlled by the "decimal places" setting ā useful for simulating measurements, prices, or any value that isn't a round number.
Yes, set "How many numbers" to any value up to 100. This is useful for drawing multiple lottery-style picks, generating test data, or creating a batch of random samples in one click.
Yes ā set the range to match your total number of entries (for example, 1 to 250 for 250 entries), generate one number, and that's your winning entry number. Keep duplicates off if you're drawing multiple winners so nobody is picked twice.