Skip to main content
When TrackFunnels generates an email tracking pixel for you, it needs to know which specific contact opened a given email. Because the pixel is embedded in a bulk email sent to many recipients, the only practical way to pass a per-recipient identifier is through your email platform’s built-in personalization system — and that system relies on merge codes. Understanding what merge codes are and which one to use for your platform is the key to getting accurate, contact-level attribution in GA4.

What Are Merge Codes?

Merge codes (also called merge fields, personalization tags, or variables, depending on your platform) are placeholder tokens you insert into the body or metadata of an email. When your CRM or email platform sends the message, it replaces each placeholder with the actual value stored on the recipient’s contact record. For example, suppose you want to open every email with a personalised greeting. Instead of writing a fixed name, you add the merge code for first name:
Dear |FNAME|,
When the campaign is sent, your platform replaces |FNAME| with the real first name of each recipient — Tim receives “Dear Tim,”, Sarah receives “Dear Sarah,”, and so on. The same substitution mechanism works for any contact field your platform stores, including the unique contact ID.

How TrackFunnels Uses Merge Codes

When you build an email tracking pixel in TrackFunnels (available on the Pro Plan), the setup form asks you for the Personalization Tag for Contact ID. This is the merge code that corresponds to the unique identifier your CRM assigns to every contact record. When a recipient opens the email, their email client loads the pixel. At that moment, the platform has already substituted the merge code with the real Contact ID for that recipient. TrackFunnels receives the resolved Contact ID and passes it to GA4 as the email_contact_id event parameter, giving you per-contact visibility into who opened which email. Without this merge code — or with an incorrect one — all opens would arrive in GA4 without a meaningful identifier, making contact-level analysis impossible.

Merge Codes by CRM

The table below lists the Contact ID merge code for the most popular CRM and email platforms. Each CRM uses its own terminology for these placeholders, so the Term Used column shows you what your platform calls them.
CRMTerm UsedContact ID Merge Code
MailchimpMerge Tags“ *UNIQID* “
InfusionsoftMerge Fields~Contact.Id~
ActiveCampaignPersonalization Tags%CONTACTID%
ClickFunnelsMerge TagsCheck with ClickFunnels
IntercomVariablesCheck with Intercom
PardotVariable Tags%%crm_id%%
HubSpotPersonalization Token{{ contact.hs_object_id }}
The merge codes in this table were last verified in January 2018. CRMs update their platforms regularly, so always confirm the current merge code in your platform’s official documentation before using it in a pixel.
If you can’t locate the correct Contact ID merge code for your CRM, reach out to us at [email protected] and we’ll help you track it down.