Random Number Generator

Generate a random number within a range, with a chosen number of decimal places.

  • Free to use
  • Accurate results
  • No registration required
  • Works on all devices
Enter a minimum, maximum, and decimal places to generate a random number in that range.

Your result

56.79

Random number

AI explanation

Formula

A uniformly distributed random number between the minimum and maximum, rounded to the requested decimal places

Worked example

Random number between 1 and 100

Worked example: Random number between 1 and 100
FieldValue
Minimum1
Maximum100
Decimal places2
Random number42.17

Assumptions

  • Every value in the range is equally likely (a uniform distribution).

Frequently asked questions

How do I get a new random number?

Change any field (even slightly) or click Reset — either one draws a fresh random number.

Is this suitable for cryptographic or security purposes?

No — this uses JavaScript's standard Math.random(), which is fine for games, sampling, or general randomization, but not cryptographically secure.

I need a whole number, not a decimal — is there a version for that?

Yes — see the Random Integer Generator, which sets decimal places to 0 automatically.

Related calculators

Report a calculation issue