TEXTAFTER Function in Excel: Text After a Delimiter

TEXTAFTER Function in Excel: Text After a Delimiter featured illustration

πŸ“Ž This article includes 1 downloadable practice file ↓

⏱ 2 min readUpdated 12 October 2026

TextLevel: IntermediateAvailable in: Excel 365 / 2021+

In this article
  1. Syntax
  2. Examples
  3. Example 1
  4. Example 2
  5. Example 3
  6. TEXTAFTER in practice
  7. Where you will use it
  8. Worked example
  9. Mistakes people make
  10. Related functions
  11. Continue learning

TEXTAFTER returns the text that follows a delimiter β€” domains from emails, surnames, file extensions.

Advertisement

Syntax

=TEXTAFTER(text, delimiter, [instance_num], [match_mode], [match_end], [if_not_found])
Argument What it means
instance_num βˆ’1 = after the last occurrence.

Examples

Example 1

=TEXTAFTER(A2, "@")

company.in from an email.

Example 2

=TEXTAFTER(A2, ".", -1)

File extension: xlsx.

Example 3

=TEXTAFTER(A2, " ", -1)

Surname.

TEXTAFTER in practice

Where you will use it

  • Domain from an email
  • Text after the last dash
  • Extension from a file name

Worked example

TextFormulaResult
[email protected]=TEXTAFTER(A2,{"@","-","."},-1)com
INV-2026-145=TEXTAFTER(A3,{"@","-","."},-1)145
report.final.xlsx=TEXTAFTER(A4,{"@","-","."},-1)xlsx

Results calculated in Excel.

Mistakes people make

MistakeWhat to do instead
No delimiter foundGives #N/A; use the if_not_found argument
First vs lastNegative instance counts from the end

TEXTBEFORE Β· RIGHT

πŸ“š Part of the free Excel course: Beginner β†’ Expert Β· Try it in the Formula Lab or ask the AI Helper.

⚑ Interactive Practice Lab & Formula Tester:

Test formulas dynamically in our web formula laboratory or download the companion Excel workbook.

πŸ“Ž Practice files for this article

  • πŸ“—
    Practice workbook: Text & cleaning24 tasks on realistic sales data β€” type your formula, the Check column turns green when it is right. Answers sheet included.
    ⬇ XLSX Β· 35 KB

Free to use for learning. Files with macros (.bas) are plain text β€” import them with Alt+F11 β†’ File β†’ Import File, and always test on a copy.

✨ Ask AI about this article

Stuck on a step? Ask a question and the AI answers using this article.

Free Β· AI can be wrong

Leave a Reply

Your email address will not be published. Required fields are marked *