RIGHT Function
Returns a set number of characters from the end of a text value.
Category
Text
Available in
All versions, Microsoft 365
Returns
Text
Overview
RIGHT is LEFT's mirror image: it pulls characters from the end of the text.
Use it for suffixes — the last four digits of an account, a size code, a file extension — and with LEN and FIND for “everything after the space”.
Syntax
Arguments
| Argument | Required? | What it does |
|---|---|---|
| text | Yes | The text (or cell) to take characters from. |
| num_chars | Optional | How many characters to return from the end. Leave it out and you get 1. |
Examples
Example 1 — Last four digits of an account
Show only the last four digits of each account number on a customer letter.
| A | B | |
|---|---|---|
| 1 | Account | Last 4 |
| 2 | ACCT-55120934 | 0934 |
| 3 | ACCT-88013377 | 3377 |
| 4 | ACCT-10204561 | 4561 |
The leading zero in 0934 survives because RIGHT returns text.
Example 2 — Last name after the space
Take everything after the space: the total length minus the space's position.
| A | B | |
|---|---|---|
| 1 | Full name | Last name |
| 2 | Ana Lopez | Lopez |
| 3 | Benjamin Cho | Cho |
| 4 | Cara Singh | Singh |
- LEN(A2) counts every character — 9 for “Ana Lopez”.
- FIND(" ", A2) is the space's position — 4.
- 9 − 4 = 5, so RIGHT returns the last five characters: “Lopez”.
Common mistakes
- Numbers lose their format. RIGHT works on the underlying value, not what you see. =RIGHT(A2,2) on a cell showing $1,250.00 returns "50" because the value is 1250.
Notes

Author
Kyle Stott
Certified Microsoft Excel Expert
Kyle has worked professionally with Microsoft Excel for over a decade and has consulted on and taught Excel best practices to over 400 companies across 30+ countries.