Excel 365 + Google Sheets · TEXTBEFORE
Cut any text before a character
Returns everything before the character you choose.
The formula
=TEXTBEFORE(A2, "@")What each part means
A2The text"@"Cut before this
Example
| A | B | |
|---|---|---|
| 1 | User | |
| 2 | laura.gomez@acme.com | |
| 3 | joao@brasilco.br | |
| 4 | priya.s@tech.in | |
| 5 | tom@shop.co.uk |
| A | B | |
|---|---|---|
| 1 | User | |
| 2 | laura.gomez@acme.com | laura.gomez |
| 3 | joao@brasilco.br | joao |
| 4 | priya.s@tech.in | priya.s |
| 5 | tom@shop.co.uk | tom |
Step by step
- Click cell B2.
- Type the formula:
=TEXTBEFORE(A2, "@") - Press Enter.
- Drag the small square in the bottom-right corner of the cell down to copy it to the other rows.
Where it works
- Excel 365 and Excel 2021 or newer
- Google Sheets
- Excel for the web (free)
The same formula in other languages
- English TEXTBEFORE
- Español TEXTOANTES
- Português TEXTOANTES