Flip surname-first names with no comma
Turn Reed Ava into Ava Reed for greetings and mailing lists.
Download Excel templateMicrosoft 365
What you'll make

The formula

| Number | Part | What it does | Result so far |
|---|---|---|---|
| 1 | TEXTAFTER(TRIM(A8)," ") | Takes the given names after the first space. | "Ava" |
| 2 | " " | Adds a space. | "Ava " |
| 3 | TEXTBEFORE(TRIM(A8)," ") | Adds the surname from before the first space. | "Ava Reed" |
| 4 | TRIM( … ) | Removes any extra spaces. | "Ava Reed" |
| 5 | IFERROR( … ) | With no space, keeps the name as it is. | "Ava Reed" |
Read it left to right. A one-word or empty cell stays as it is.
=IFERROR(TRIM(TEXTAFTER(TRIM(A8)," ")&" "&TEXTBEFORE(TRIM(A8)," ")),TRIM(A8))How to use it
Yellow bar at the top? Click Enable Editing.
- See it work. The Example tab shows 20 made-up names with the formula already in.
- Use your own names. Paste surname-first names into the green column of the Template tab. First Last names fill in by themselves.
- Move them into your letter. Copy the results. Then use Paste Special and choose Values.
Before you send
This expects a one-word surname first. Fix two-word surnames by hand, like de la Cruz or van Dijk.
Route: Get names ready for the letter
Microsoft's help: TEXTAFTER function
OTHER ROUTES YOU MIGHT LIKE

Get the second first name in a household
Ava and Noah Reed → Noah
Get the template →
Get first name field using a separator
Ava|Reed + separator | → Ava
Get the template →
Get a chosen name from a semicolon list
Ava Reed;Noah Park;Mia Chen + 2 → Noah Park
Get the template →
Fix "Dear ," when a first name is blank
(blank) → Dear colleague,
Take this route →