Text
TEXTBEFORE
The part of a text before a delimiter.
Syntax
TEXTBEFORE(text, delimiter, [instance_num])Example: =TEXTBEFORE(A2,"@")
Available in: Excel 2024, Microsoft 365
Try it
A tiny spreadsheet with example data. Edit the formula or any number and see the result.
Formula in D2: =TEXTBEFORE(A3,"@")
| A | B | C | D | |
|---|---|---|---|---|
| 1 | Text | Other | Result | |
| 2 | Alice Johnson | alice johnson | alice | |
| 3 | alice@shop.com | ALICE@shop.com | ||
| 4 | extra spaces | |||
| 5 | SKU-2026-0415 | |||
| 6 | iced coffee, tea, sugar | |||
| 7 | Order 417 shipped |
Result in D2: alice