RAND

Using the Excel RAND Function

Summary

The RAND function is used to generate an evenly distributed random real number. The random number will be greater than or equal to zero and less than 1. Each time the worksheet is calculated a new random real number is returned.

Excel 2010 and later versions generate random numbers using the Mersenne Twister algorithm (MT19937).


Syntax

=RAND ()

Syntax Breakdown

()
RAND is one of the Excel functions that does not have any arguments.


Usage Notes

RAND is used to generate a random number that is greater than or equal to 0 and less than 1. Each time the worksheet is changed or opened, RAND will return a new number.

Prevent Numbers From Changing
If you want to stop the random number from updating, copy the value returned by RAND and Paste Special as Values. This converts the result to text so that it is no longer a function; thus, won't update each time a change takes place.

You can also enter then RAND function in the formula bar and press F9, as opposed to Enter or Tab, to convert the function into the result.