Personalizing Emails with Names and Fallback Values
Personalizing Emails with Names and Fallback Values
What are personalization tags?
Personalization tags let you insert information from a profile (like a person’s first name) directly into your email subject lines and content.
They work anywhere you can edit text in an email template, including:
- Subject lines
- Preheaders
- Headings and body text
Insert the first name in an email
To show the recipient’s first name, use the first name field from their profile. For example:
- In the subject line: “Hola {{ first_name }}”
- In the body: “Hola {{ first_name }}, gracias por tu compra.”
You can type the tag directly, or use the personalization picker in the editor to insert it.
Add a default value when the name is missing
Not every profile has a first name. To avoid sending emails like “Hola ,” you can set a default value (fallback) that appears when the name is missing.
Use this pattern:
{{ first_name | default:'allí' }}in Spanish (appears as “allí” when no name is available){{ first_name | default:'there' }}in English (appears as “there” when no name is available)
Example subject lines:
- Spanish:
{{ first_name | default:'allí' }}, tenemos algo para ti - English:
Hi {{ first_name | default:'there' }}, your order has shipped
Example in the email body:
Hola {{ first_name | default:'allí' }},
Queríamos contarte sobre nuestras últimas novedades.
Multilingual considerations
If you send emails in multiple languages:
- Choose a fallback that fits naturally in each language (e.g., “allí”, “amig@”, “there”, “friend”).
- Make sure you use the correct fallback in each language-specific template.
By combining the first name tag with a default value, you can safely personalize your emails without worrying about missing names.