Back to functions
Text2026-03-143 related articles

RIGHT Function in Excel

Return characters from the right end of a text string.

Syntax

RIGHT(text, [num_chars])

Arguments

text

Required

The source text string.

num_chars

Optional

The number of characters to return from the right side. If omitted, Excel returns one character.

What it returns

Returns the requested number of characters from the end of the text.

What RIGHT does

RIGHT extracts characters from the end of a text string. It is a good fit when the part you need is always attached to the right side of an ID, code, or label.

Practical examples

Return the last four characters

=RIGHT(A2,4)

This is useful for pulling suffixes, years, region codes, or the last digits of an identifier.

Default to a single character

=RIGHT(A2)

If you omit the second argument, RIGHT returns the final character only.

Common mistakes and notes

RIGHT returns text

Even if the extracted characters look numeric, Excel treats them as text until you convert them.

Fixed-length assumptions matter

RIGHT works best when the part you want always has the same length. If lengths vary, the extraction logic needs more context.

Related functions

Related articles

Deep dives, troubleshooting guides, and practical examples that use RIGHT.

Official documentation