How to Select a Random Value From a List in Google Sheets

In Google Sheets, you can use the RANDARRAY or RANDBETWEEN functions to select a random value from a list. RANDARRAY will return a single random value from a range or array of values. RANDBETWEEN will return a random integer between two given values. Both functions can be used in combination with other functions such as SORT and FILTER to get the desired results.


You can use the following formula to select a random value from a list in Google Sheets:

=INDEX(A2:A16, RANDBETWEEN(1, COUNTA(A2:A16)))

This particular formula selects a random value from the range A2:A16.

The following example shows how to use this formula in practice.

Example: Select Random Value from List in Google Sheets

Suppose we have the following list of values in Google Sheets:

We can type the following formula into cell C2 to select a random value from the range A2:A16:

=INDEX(A2:A16, RANDBETWEEN(1, COUNTA(A2:A16)))

The following screenshot shows how to use this syntax in practice:

Google Sheets select random value from list

We can see that the formula randomly selected 26 from the list of values in column A.

If you click on cell C2 and click Ctrl+C, then click Ctrl+V to paste the same formula back into cell C2, a new value will be randomly selected from the list:

We can see that the formula randomly selected 33 from the list of values this time.

Note: You can find the complete documentation for the RANDBETWEEN function in Google Sheets .

x