Back to functions
Text2026-06-130 related articles

TEXTAFTER Function in Excel

Return the text that appears after a chosen delimiter.

Syntax

TEXTAFTER(text,delimiter,[instance_num],[match_mode],[match_end],[if_not_found])

Arguments

text

Required

The text value you want Excel to search within.

delimiter

Required

The text that marks where the returned result should begin.

instance_num

Optional

Which occurrence of the delimiter Excel should use. Negative numbers search from the end.

match_mode

Optional

Use 1 for a case-insensitive match. The default 0 is case-sensitive.

match_end

Optional

Use 1 to treat the end of the text as a delimiter.

if_not_found

Optional

The value to return if the delimiter is not found. The default behavior returns

What it returns

Returns the portion of text that appears after the selected delimiter.

What TEXTAFTER does

TEXTAFTER extracts everything that appears after a delimiter in a text string. It is useful when imported values contain a prefix, label, or separator and you only need the trailing part.

Practical examples

Return the domain from an email address

=TEXTAFTER(A2,"@")

If A2 contains maya@example.com, the result is example.com.

Return the text after the second slash

=TEXTAFTER(A2,"/",2)

This pattern is helpful when parsing paths, codes, or structured IDs.

Common mistakes and notes

Missing delimiters return errors by default

If the delimiter does not exist in the source text, TEXTAFTER returns #N/A unless you provide if_not_found.

Delimiter matching is case-sensitive by default

If uppercase and lowercase delimiter text should match equally, set match_mode to 1.

Negative instance numbers search backward

Use a negative instance_num when you want the text after the last or second-to-last delimiter instead of searching from the front.

Related functions

Official documentation