Overview
Dynamic variables personalize sequence emails with Apollo data and custom field values. Basic dynamic variables insert a field value. Advanced dynamic variables add conditional logic and modifiers, so you can display different copy when a field is present, blank, or matches a specific value.
Use advanced dynamic variables in the subject or body of sequence email templates and email steps. Conditional blocks support standard Apollo fields and supported custom fields. Use {{#if}}, {{#else}}, and {{#endif}} to create fallback copy, compare values, and build nested conditions. You can also use -> operators to format text or adjust date values.
Check out the following sections to add and use advanced dynamic variables.
Use Advanced Dynamic Variables in a Sequence Email
Add advanced dynamic variables to the subject or body of an email step.
To use an advanced dynamic variable in a sequence email:
- Launch Apollo and click Sequences.
- Create a sequence or click an existing sequence.
- Open an existing email step, or add a new one.
- Enter the conditional logic in the email subject or body.
- Preview the email with contacts that have different field values to confirm that each conditional branch displays the correct copy.
- Click Save.
You have now added an advanced dynamic variable to a sequence email.
Use {{#if}}, {{#else}}, and {{#endif}} in sequence email subject lines and bodies with standard Apollo fields and supported custom fields. Apollo supports nested conditional blocks and comparisons such as ==, <, <=, >, and >=. Apollo also accepts spaces inside conditional tags, so {{ #if first_name }} works the same as {{#if first_name}}.
In AI email steps, add plain-language guidance to Custom Instructions. Apollo may treat conditional tags in this field as unresolved variables.
A conditional block chooses which branch Apollo renders. Variables inside the selected branch must still resolve. Add fallback handling or populate the field to prevent the email from moving to Not sent.
Types of Advanced Dynamic Variables
You can use the following types of advanced dynamic variables:
- Empty Fallback
- Dynamic Fallback
- Conditional Comparisons and Custom Fields
- Letter Case and Pluralization Operators
- Current Date and Time Operators
- Custom Date Operators
Each type helps you adjust your email copy based on available field values or send-time context.
Empty Fallback
Use an empty fallback when you want Apollo to display content only when a field contains data. Add the field variable inside the {{#if}} block.
For example, use the following conditional to greet a contact when their first name is available:
{{#if contact.first_name}}Hi {{contact.first_name}},{{#endif}}
If the contact’s first name is John, Apollo displays:
Hi John,
If the first-name field is blank, Apollo omits the entire greeting.
Dynamic Fallback
Use a dynamic fallback when you want Apollo to replace a missing field with text you provide.
For example, use the following conditional to greet a contact by name or use a generic greeting when their first name is unavailable:
Hi {{#if contact.first_name}}{{contact.first_name}}{{#else}}there{{#endif}},
If the contact’s first name is John, Apollo displays:
Hi John,
If the first-name field is blank, Apollo displays:
Hi there,
Each part of the conditional controls the result:
-
{{#if contact.first_name}}checks whether the first-name field contains data. -
{{contact.first_name}}displays the first name when the field contains data. -
{{#else}}theredisplays the fallback text when the field is blank. -
{{#endif}}closes the conditional block.
To add literal fallback copy, use a conditional block with {{#else}}. Use -> only with supported text and date operators.
Apollo still needs values for variables in the branch it selects. If the selected branch includes an unresolved variable, Apollo blocks that message from sending. Use plain text in the {{#else}} branch when you want a reliable fallback.
Conditional Comparisons and Custom Fields
Use conditional comparisons to display different copy when a standard or custom field matches a specific value. You can compare text, numbers, and true or false values.
For example, use an account custom field to tailor your copy by industry:
{{#if account.custom_industry == "Technology"}}...
Replace account.custom_industry with the custom-field variable Apollo inserts from the dynamic variables menu for your field.
Apollo supports the following comparison operators:
| Operator | Description |
|---|---|
== |
Matches the specified value. |
< |
Is less than the specified value. |
<= |
Is less than or equal to the specified value. |
> |
Is greater than the specified value. |
>= |
Is greater than or equal to the specified value. |
You can nest conditional blocks to compare multiple values. Add one {{#endif}} statement for every {{#if}} statement.
Letter Case and Pluralization Operators
Use letter case and pluralization operators to change how Apollo displays a text value.
Use these operators with text fields, including supported standard and custom fields.
| Dynamic Variable | Description | Example |
|---|---|---|
{{contact.title->lowercase}} |
Converts every letter to lowercase. |
Engineering Manager becomes engineering manager. |
{{contact.title->uppercase}} |
Converts every letter to uppercase. |
Engineering Manager becomes ENGINEERING MANAGER. |
{{contact.title->capitalize_each_word}} |
Capitalizes the first letter of every word. |
engineering manager becomes Engineering Manager. |
{{contact.title->plural}} |
Converts the value to its plural form. |
Engineering Manager becomes Engineering Managers. |
Chain supported operators with -> to apply more than one change:
{{contact.title->capitalize_each_word->plural}}
This variable displays engineering manager as Engineering Managers.
Current Date and Time Operators
Use current date and time variables to personalize email copy based on the applicable date or time of day. For date calculations, add a supported -> operator to a now_* variable.
| Dynamic Variable | Description | Example |
|---|---|---|
{{now_month}} |
Displays the current month. | April |
{{now_day}} |
Displays the current day of the month. | 15 |
{{now_weekday}} |
Displays the current day of the week. | Wednesday |
{{now_year}} |
Displays the current year. | 2026 |
{{now_year->plus_1}} |
Moves the current date forward by one year, then displays the resulting year. | If the current year is 2026, Apollo displays 2027. |
{{now_month->plus_1}} |
Moves the current date forward by one month, then displays the resulting month. | If the current month is April, Apollo displays May. |
{{now_month->minus_2}} |
Moves the current date back by two months, then displays the resulting month. | If the current month is April, Apollo displays February. |
{{now_day->plus_3}} |
Moves the current date forward by three business days, then displays the resulting day of the month. | Apollo skips weekends when applying the offset. |
{{now_weekday->plus_2}} |
Moves the current date forward by two business days, then displays the resulting weekday. | If the applicable day is Monday, Apollo displays Wednesday. |
{{now_time_of_day}} |
Displays morning, afternoon, or evening based on the applicable time zone. |
If the applicable time is 9:00 AM, Good {{now_time_of_day}}, displays as Good morning,. |
Apollo applies the offset before it displays the requested date component. For now_day and now_weekday, non-zero offsets skip weekends.
Apollo returns {{now_time_of_day}} values in lowercase and English:morning: 5:00 AM to 11:59 AMafternoon: 12:00 PM to 5:59 PMevening: 6:00 PM to 4:59 AM
For sequence emails, Apollo uses the contact’s time zone when Send in contact’s time zone is enabled and the contact has a time zone. Otherwise, Apollo uses the sequence schedule’s time zone. Template previews use the sender’s time zone. If Apollo can’t identify a time zone, it uses Pacific Time.
Custom Date Operators
Access to custom fields depends on your Apollo plan. Custom date operators require a supported date custom field. If you need access to custom fields, upgrade your plan or reach out to the Apollo sales team.
Use custom date operators to extract or adjust parts of a date stored in a custom field. Add the custom field from the dynamic variables menu so Apollo uses the correct field name.
For example, suppose the account custom field product_announcement contains October 15, 2026:
-
{{account.product_announcement->day}}displays15. -
{{account.product_announcement->month}}displaysOctober. -
{{account.product_announcement->year}}displays2026. -
{{account.product_announcement->weekday}}displays the day of the week.
You can also chain a date adjustment after the date component. For example, {{account.product_announcement->year->plus_1}} displays 2027.
Example Use Case for Advanced Dynamic Variables
This example uses line breaks to make each conditional block easier to follow. Enter each conditional block as one continuous line unless you want the line breaks to appear in the email. Preview the email with contacts that have different field values before you send it.
Suppose you want to greet each contact by name, tailor your copy to an account custom field, and propose a future year:
Hi {{#if contact.first_name}}{{contact.first_name}}{{#else}}there{{#endif}},
{{#if account.custom_industry == "Technology"}}Technology teams often use Apollo to personalize outreach at scale.
{{#else}}{{#if account.custom_industry == "Marketing"}}Marketing teams often use Apollo to coordinate personalized campaigns.
{{#else}}Growing teams often use Apollo to personalize outreach at scale.{{#endif}}{{#endif}}
We'd like to show you how Apollo can support your goals for {{now_year->plus_1}}.
The first conditional greets the contact by name when a first name is available. Otherwise, Apollo uses there.
The nested conditional compares the account’s custom industry field:
- If the value is
Technology, Apollo displays the technology copy. - If the value is
Marketing, Apollo displays the marketing copy. - If the field has another value or no value, Apollo displays the general fallback.
The two nested {{#if}} statements require two {{#endif}} statements.
The {{now_year->plus_1}} variable adds one to the current year.
{{#endif}} Statements Do I Need?Add one {{#endif}} statement for every {{#if}} statement. Nested conditional blocks need multiple {{#endif}} statements because Apollo closes each block separately.
Next Steps
Ready to put advanced dynamic variables to work? These resources can help you build stronger personalization across templates, sequences, and AI research.
| Use Basic Dynamic Variables | Use basic dynamic variables to add reliable contact, company, and time-based details before layering conditional logic into your messaging. |
|---|---|
| Use Custom Dynamic Variables | Create and use custom dynamic variables to pull your team’s custom fields and AI research into personalized emails at scale. |
| Create and Use Email Templates | Create and test email templates to preview how your variables render and reuse polished messaging across your sequence steps. |
| Create a Sequence | Build a sequence with personalized email steps to turn your dynamic variables into a coordinated, multichannel outreach campaign. |
| Use AI Research to Find Better Prospects | Run AI research on prospects to generate tailored insights you can reuse as dynamic variables in emails and sequences. |