The RAND function in excel is an in-built mathematical excel formula useful for generating numbers randomly in excel.

In this tutorial, we would learn how to use the RAND formula in excel for generating random numbers in excel.

**What is the Use of RAND Function in Excel**

The excel RAND formula is an in-built math/trig excel formula which is used to generate and return evenly distributed random number between 0 and 1. Therefore, the result of this function is a random decimal number that lies between 0 and 1.

This function can be either directly used in an excel cell or can be used as a part of another excel formula.

**Syntax and Arguments**

**=RAND()**

There are no arguments or parameters of the RAND excel formula.

**Using RAND Function in Excel with Example**

Let us first take some simple example to understand how the RAND formula works in excel.

To start with, simply type RAND with empty parenthesis in a cell in excel, like this:

=RAND()

As soon as you press Enter, the excel would generate a number between 0 and 1 in that cell.

In the above example, it generates 0.984314582 in cell B2. However, the formula output decimal number may be a different number for you.

**Also Read: **RANDARRAY Function in Excel

Now, type anything (of your choice) in any other cell and press Enter. As a result, you would notice that the random number from the RAND function changes every time you do anything in the sheet. This is because the RAND function is a volatile excel function.

To stop the random number change every time, simply copy the random number and **paste special it as values**.

Also, there is an alternative method.

If you do not want excel to change the random number, simply select the cell > click on the excel formula bar > press F9 key on your keyboard > press Enter key.

**Generate Random Numbers in Multiple Range of Cells**

In the above section, we learned how to generate random number in a single cell.

In this section, we would learn two ways to generate random numbers in range of cells.

- Firstly, select the multiple cell range. Then, type the =RAND() formula and press Ctrl+Enter keyboard keys to generate random numbers in the selected cell range.

- Another way is to use the excel fill handle tool. Enter the =RAND() formula in the first cell, and then drag the formula to other cells using the
**excel fill handle tool**.

To generate random numbers between two specified values, use the **excel RANDBETWEEN function**.

Thank You 🙂