# RIGHT in Google Sheets: syntax and examples

URL: https://goingstellar.ro/reference/sheets/right/

RIGHT returns characters from the end of a text. It is used to cut off codes, extensions and suffixes, often together with LEN and FIND.

## Syntax

```
RIGHT(string, [number_of_characters])
```

## Arguments

- `string` (text, required: yes): The text to take characters from. A number is turned into text first.
- `number_of_characters` (number, required: no): How many characters to take from the end. Defaults to 1.

## Examples

The examples use this table, starting in A1:

| Reference | Name |
|---|---|
| INV-2026-0042 | Ana Pop |
| INV-2026-0107 | Dan Ilie |
| ORD-9 | Mia Rus |
| 12345 |  |

```
=RIGHT("Sheets",3)
```

Result: `ets`

The last three characters of a text. Run in a Google Sheet (English US locale) on 2026-11-29.

```
=RIGHT(A2)
```

Result: `2`

Without the second argument you get one character. Run in a Google Sheet (English US locale) on 2026-11-29.

```
=RIGHT(A2,4)
```

Result: `0042`

The sequence number at the end of an invoice reference, leading zeros kept. Run in a Google Sheet (English US locale) on 2026-11-29.

```
=VALUE(RIGHT(A3,4))
```

Result: `107`

VALUE turns the extracted text into a number, so the zeros disappear. Run in a Google Sheet (English US locale) on 2026-11-29.

```
=RIGHT(B2,LEN(B2)-FIND(" ",B2))
```

Result: `Pop`

Everything after the first space: the surname from a full name. Run in a Google Sheet (English US locale) on 2026-11-29.

## Common errors

- A negative count returns #VALUE!. Compute the count first and make sure it is not below 0.
- Asking for more characters than the text has returns the whole text, with no error.
- A number is converted to text with the locale decimal separator: RIGHT(1.25,3) returns .25 in en_US but ,25 in ro_RO. Do not rely on a fixed separator.
- The result is always text. "0042" keeps its zeros, and RIGHT(A2,4)=42 is FALSE until VALUE turns it into a number.

## Compared with Excel

Same syntax as Excel RIGHT. RIGHTB exists in Sheets too.

## Related functions

- [LEFT](https://goingstellar.ro/reference/sheets/left/)
- [MID](https://goingstellar.ro/reference/sheets/mid/)
- [LEN](https://goingstellar.ro/reference/sheets/len/)
- [FIND](https://goingstellar.ro/reference/sheets/find/)
- [SUBSTITUTE](https://goingstellar.ro/reference/sheets/substitute/)
- [VALUE](https://goingstellar.ro/reference/sheets/value/)

## Sources

- [RIGHT (Docs Editors Help)](https://support.google.com/docs/answer/3094087)

