# RAND Function – Google Sheets

The RAND function is used in Google Sheets to generate a random decimal between 0 and 1. 0 is the lowest possible value, but the output must be lower than 1. There are no inputs, unlike most other functions in Google Sheets.

To produce a random integer, consider using the RANDBETWEEN. Get your copy of these examples in a live Google Sheet.

## Purpose

This function returns a random decimal between 0 and 1.

## Syntax

`=RAND()`

## Similar Functions

RANDBETWEEN – Generates a random integer with a value between two numbers supplied to the function

RANDARRAY – Generates an array of random numbers

## Examples

### Example 1 – Simple Use of the RAND Function

The RAND function does not need any inputs.

When you type `=RAND()` into a cell, Google Sheets returns a random decimal value less than 1.

### Example 2 – Creating Larger Decimals

Depending on the layout of your spreadsheet, you may want a larger random decimal than those created by the RAND function. This technique adds to the function, creating a small formula to enable a larger range of numbers.

`=RAND()*(b-a)+a`
To increase the output of the function, we multiply it by`(b-a)+a`, which creates an output between `a` and `b`. To generate a random decimal between `7` and `13`, we use the formula below.
`=RAND()*(13-7)+7`