A random number generator draws values from a range you name. This random number generator has two modes. Integer mode needs whole-number bounds and includes both ends: 1 to 6 can produce 1 and 6. Decimal mode uses a half-open range [min, max). The maximum itself is not returned. That matches a unit-interval sample times the width. If you needed the maximum as a possible decimal, raise the bound a little or use integers.
If minimum is greater than maximum, the page reports an error. It will not swap the fields. Silent swaps hide a typing mistake and then look like a fair draw. Empty fields and non-numeric text are errors, not zero. The source is crypto.getRandomValues with rejection sampling for integers so the distribution is not biased by a naive modulo.
Use this page for a raffle integer, a test fixture, or a decimal in a stated interval. It is not a statistical suite and not a lottery system. For a hex token, use the Random String Generator.
Enter from a field runs generate. Each control has a visible label. Decimal mode with min equal to max is refused because the half-open width would be zero.
Integer 1 to 6 is a fair die if the browser provides Web Crypto. All six faces can appear. Decimal 0 to 1 produces values in [0, 1). 0 can appear. 1 cannot. Ten values print one per line. A count of 0 or 101 is rejected. Script-looking text in a bound is rejected as not a number.
If you needed a normal distribution or a seeded sequence you can replay, this page is the wrong tool. It draws fresh values each click. There is no seed field on purpose. A seed you type would be a different, documented generator.
Floating-point decimals are ordinary IEEE numbers. They are not decimal-exact money amounts. If the job was currency, generate integers of cents instead of a decimal dollar. Write the mode and the bounds next to the result so nobody later assumes the other rule.
Repeated clicks are independent. Seeing the same integer twice in a short list is allowed. Forcing uniqueness would be sampling without replacement, which this page does not do.
A classroom raffle that needs distinct ticket numbers should generate a longer list and skip repeats yourself, or pick from a hat. This page will not track which integers it already printed. A test suite that needs the same sequence tomorrow needs a seeded generator, which is a different contract. There is no seed here so nobody can reconstruct yesterday’s draws from a password on a sticky note.
Decimal output is printed with JavaScript’s ordinary number-to-string rules. You may see many digits after the point. That is the sample, not a rounded display of two decimal places. If the worksheet wanted two places, round after you copy, and say so next to the number.
Integers include both ends. Decimals use the half-open range [min, max). Min and max are not swapped. Source: crypto.getRandomValues.
Yes. Both minimum and maximum can appear.
Minimum is included. Maximum is excluded: the range is [min, max).
No. If min is greater than max, the status reports the problem.
No. It uses crypto.getRandomValues.