All Collections
Send
Email Templates
How to Add a Link Trigger to an Email Template
How to Add a Link Trigger to an Email Template

The process for adding a link trigger to both visual & HTML email templates.

Updated over a week ago

NOTE: This is an advanced tutorial. If you're just getting started, check out these steps first.

You can include a link trigger directly into your email template.

This will prevent you from having to add the link trigger to every email you send using that template, and is also a great option for custom unsubscribe links.

First, find your link trigger's ID, then add it to a visual or HTML email template.

NOTE: This tutorial is for after your link trigger has already been created. If you need help with that, please follow this tutorial first, and come back when it's ready.

How to find out link trigger's ID

1. Create a new broadcast

Go to Send > Broadcasts and make a new broadcast. We'll only use it to get the link trigger's ID, then you can delete it.

Type some text in the email editor (it doesn't matter what—we'll be deleting this draft once we have the ID we need), then highlight it and click the link icon in the toolbar. Add your link trigger and click 'Apply'.

3. Preview the broadcast

Once your link trigger has been added, you need to preview the broadcast so we can get at an HTML version of the link. Click the 'Preview' button in the righthand menu.

Note: Step 4 is slightly different in different browsers, but not different enough to warrant multiple sets of instructions. You'll be able to follow the instructions below in any modern browser.

With the preview open, right-click on the link and choose 'Inspect' in the menu that opens (the option is the same in all browsers except Safari, which says 'Inspect Element'). Your browser's developer panel will open, showing you the HTML of the link.

Note: You'll see in the video below that my developer panel opens beneath the webpage, but yours may open in a different position depending on your most recent Chrome settings.

You're looking for the numerical value following a bit of HTML that says trigger-id="#######"

Highlight and copy that value, and save it somewhere.

Note: In the video below, the right-click menu is not visible, but it will be for you. You're looking for the 'Inspect' option.

Make sure you note your link trigger's ID number somewhere you can access it again, because we'll be using it later.

5. Delete the broadcast draft

As long as your link trigger's ID is saved somewhere, we no longer need this broadcast draft, so feel free to discard it.

Now we're ready to add this link trigger to our email template! Please follow the steps in one of the following sections of this tutorial, based on whether your template uses our HTML or visual editor.

How to add a link trigger to a visual email template

1. Navigate to your template's editor

Click the template you'd like to modify from your account's email templates page.

In this case I'd like to add my link trigger above the current unsubscribe link section, so I'm going to add my HTML block there:

3. Click 'Edit' on your HTML block and add the following code:

<a href="YOUR-URL-HERE" trigger-id="YOUR-LINK-TRIGGER-ID">Your link text here</a>

Replace the indicated values with your own link trigger's URL and ID, as well as the text you'd like displayed for the link. If you'd like, you can also add CSS styling to this same HTML block to style your link trigger.

NOTE: Remember, the ID is the numeric value (usually 7 digits) you noted down in Step 4 above.

When you're done click the Save button on the HTML block.

4. Save the changes to your template

Save the changes to your template via the Save button in the top right of the page, and that's it!

NOTE: Adding a link trigger via an HTML block means that it won't have any default styling associated with it and as a result, it will probably look quite plain by default. However, you have the option to add CSS code to the same HTML block to style your link trigger's appearance—we have a guide on that here.

How to add a link trigger to an HTML email template

1. Navigate to your template's editor

Click the template you'd like to modify from your account's email templates page.

<a href="YOUR-URL-HERE" trigger-id="YOUR-LINK-TRIGGER-ID">Your link text here</a>

Replace the indicated values with your own link trigger's URL and ID, as well as the text you'd like displayed for the link. You can also add CSS to style your link trigger, and use the Preview button to preview your changes.

NOTE: Remember, the ID is the numeric value (usually 7 digits) you noted down in Step 4 above.

3. Save the changes to your template

When you're ready, click the Save button at the bottom left of the page, and that's it!

Did this answer your question?