What is Handlebars Merge Language (HML) for Pardot?

Share this article...

HML is what’s used to personalize Pardot emails, email, dynamic content, landing pages, forms, and user email signatures. Select your merge field from the Pardot merge picker, you are able to easily add personalization dynamically pulling in data specific to the prospect that is viewing your Pardot marketing assets.

Pardot upgraded to Handlebars Merge Language (HML) from the legacy Pardot Merge Language (PML). The upgrade bought additional capabilities (eg. IF/ELSE statements) and is currently used in other places on the core Salesforce Lightning platform which is a strong hint at emails becoming aligned between Salesforce & Pardot (as we’re seeing with many other objects/features). Maybe this doesn’t get your heart racing? Which is why I wrote this post, to dig further into what this upgrade could actually mean in the future.

“Sonar”

How and Where Can You Use HML in Pardot?

Good news: any Pardot customer can use HML, which includes all editions, and both Salesforce Lightning/Classic and Pardot Lightning/Classic (in any combination).

You can merge data from:

  • Prospect fields
  • Account fields
  • User fields

Into all Pardot email types, plus content features:

  • Pardot email templates,
  • List emails,
  • 1:1 emails,
  • Dynamic content,
  • Landing Pages (new January 2020)
  • Forms (new January 2020)

 

What’s Being Replaced?

Currently, you can merge Prospect and Prospect Account data using Pardot variable tags, that look like this:

  • %%email%%
  • %%assigned_user.name%%

Instead, Prospect data will be merged where you see {{ (instead of %%):

The updated ‘merge picker’ is launched using the ‘merge field’ button:

Which looks like this:

Bonus features include:

  • A search box
  • Categories for easier browsing and navigation.

If you’re used to composing emails in Salesforce Lightning, the merge picker will be familiar to you. Salesforce Merge Language (SML) is slowly being phased out since the HML release in Summer ‘18 – SML is still being used in Classic email templates (if you have any!).

What’s the Big Deal?

Aside from a better ‘merge picker’, here’s 5 notable benefits:

  • Email template alignment: HML is the same ‘merge language’ that Salesforce Lightning Templates use, ie. in Sales Cloud, Service Cloud, Communities etc. This could ultimately mean, in the future, that Pardot users will be able to merge data outside of Prospect and Account fields – yes, even custom object data!
  • Future features: all future enhancements will use PML, such as the Winter ’20 ’Snippets’ feature, that will bring reusable content across multiple emails.
  • Tracked Dynamic Links: URL merged dynamically into emails can be tracked! Here’s the challenge we’re currently facing
  • Conditional Default Data: you can set default data to be merged into the email when there is no field data. Yes, you can do this for Pardot prospect fields, but HML allows you to set conditions as well (#if tags); for example, if the prospect’s first name is blank, show “some value”. You can define this on each email, which means you are not restricted to one default field value (currently set on the Prospect field in Pardot Settings). Let’s look at that further…

HML Conditional Merge Fields

So, you’ve seen how to include prospect field values to personalise emails, forms and landing pages, but what happens when the prospect has no value for that field?

A blank field value can be solved using conditional merge fields. This code snippet will show alternative text as a fallback value when there is no value in the prospect field, which prevents awkward blank spaces or nonsense sentences.

Conditional HML works in a ‘if/else’ way, functioning as ‘if-then-show-this, if-not-then-show-that’.

First you define what you prefer prospects to see, then you define what prospects to see if the field is blank. As you will see in the example, typing {{#if starts the statement; {{/if}} closes it.

{{#if Recipient.City}}
We’ll see you in {{Recipient.City}},
{{else}}
We’re coming to your city!
{{/if}}

 

When Can You Upgrade?

As I mentioned, HML is part of the Pardot August ’19 release, which will go live between 21st-30th August.

When it’s your turn, you will see a notification banner appear on your Pardot dashboard, inviting you to ’Streamline your tailored marketing content across Salesforce’:

HML is an optional upgrade and is a ‘permanent upgrade’ – in other words, it can’t be undone, but I can’t see any downsides to doing so. The only consideration is that there’s a limit of 200 HML merge fields and 10 pieces of dynamic content per email (you will bump up against these limits when converting if your templates are very personalisation heavy!).

Pardot say that there will be guidance on how to convert but we help you convert all your PML assets as you use them. You will be able to track which are updated from the menus in Pardot:

 

Leave a Reply