Skip to main content
 

Excel Formula: Extract first and last name from e-mail address

Author: Sun Last Modified: 2020-03-05

This tutorial introduces the formulas to extract first name and last name from given email addresses into separate cells as below screenshot shown, also, it provides the example to explain the arguments and parts of the formulas.
doc extract extension from file name 5

Extract first name

Generic formula:

LEFT(e_address,FIND("separator",)-1)

Arguments

E_address: the email address you want to extract the first name.
Separator: the delimiter between first name and last name.

How this formula work

To extract first name from the email address in cell B3, please use below formula:

=LEFT(B3,FIND("_",B3)-1)

Press Enter key.
doc extract first last name email 2

Explanation

FIND function: to find the start position of a character or text in a given text string. The formula FIND("_",B3) finds the position of character “_” in the cell B3, returns 4.

LEFT function: extract text from left side of the given text string based on the given text length. Formula LEFT(B3,FIND("_",B3)-1) can be seen as LEFT(B3,4-1), extract first 3 characters from the text in cell B3.

Extract last name

Generic formula

LEFT(RIGHT(e_address,LEN(e_address)-FIND("separacter",e_address)),FIND("@",RIGHT(e_address,LEN(e_address)-FIND("separator",e_address)))-1)

Argument

E_address: the email address you want to extract the first name.
Separator: the delimiter between first name and last name.

How this formula work

To extract last name from the email address in cell B3, please use below formula:

=LEFT(RIGHT(B3,LEN(B3)-FIND("_",B3)),FIND("@",RIGHT(B3,LEN(B3)-FIND("_",B3)))-1)

Press Enter key.
doc extract first last name email 3

Explanation

FIND function: to find the start position of a character or text in a given text string.

LEN function: count the number of a text string.

RIGHT function: to extract text from right side.

The formula RIGHT(B3,LEN(B3)-FIND("_",B3)) can be seen as:
=RIGHT(B3,LEN(B3)-4)
=RIGHT(B3,17)
="Smith@kutools.com"

Then FIND("@",RIGHT(B3,LEN(B3)-FIND("_",B3))) can be seen as
=FIND("@","Smith@kutools.com")
="6"

LEFT function: extract text from left side of the given text string based on the given text length. The formula LEFT(RIGHT(B3,LEN(B3)-FIND("_",B3)),FIND("@",RIGHT(B3,LEN(B3)-FIND("_",B3)))-1) can be seen as these:
=LEFT(RIGHT(B3,LEN(B3)-FIND("_",B3)),6-1)
=LEFT("Smith@kutools.com",5)
="Smith"

Remark

If you want to extract first and last name with first letter uppercase, you can add the PROPER function in the front of above formulas, such as:

=PROPER(LEFT(B3,FIND("_",B3)-1))
=PROPER(LEFT(RIGHT(B3,LEN(B3)-FIND("_",B3)),FIND("@",RIGHT(B3,LEN(B3)-FIND("_",B3)))-1))
doc extract first last name email 4

Sample File

doc sampleClick to download sample file


Relative Formulas


Relative Functions


The Best Office Productivity Tools

Kutools for Excel - Helps You To Stand Out From Crowd

🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions
Popular Features: Find, Highlight or Identify Duplicates  |  Delete Blank Rows  |  Combine Columns or Cells without Losing Data  |  Round without Formula ...
Super VLookup: Multiple Criteria  |  Multiple Value  |  Across Multi-Sheets  |  Fuzzy Lookup...
Adv. Drop-down List: Easy Drop Down List  |  Dependent Drop Down List  |  Multi-select Drop Down List...
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  Compare Columns to Select Same & Different Cells ...
Featured Features: Grid Focus  |  Design View  |  Big Formula Bar  |  Workbook & Sheet Manager | Resource Library (Auto Text)  |  Date Picker  |  Combine Worksheets  |  Encrypt/Decrypt Cells  |  Send Emails by List  |  Super Filter  |  Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters ...)  |  50+ Chart Types (Gantt Chart ...)  |  40+ Practical Formulas (Calculate age based on birthday ...)  |  19 Insertion Tools (Insert QR Code, Insert Picture from Path ...)  |  12 Conversion Tools (Numbers to Words, Currency Conversion ...)  |  7 Merge & Split Tools (Advanced Combine Rows, Split Excel Cells ...)  |  ... and more

Kutools for Excel Boasts Over 300 Features, Ensuring That What You Need is Just A Click Away...


Office Tab - Enable Tabbed Reading and Editing in Microsoft Office (include Excel)

  • One second to switch between dozens of open documents!
  • Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
  • Increases your productivity by 50% when viewing and editing multiple documents.
  • Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Edge and Firefox.