Do you support custom email templates?

Yes!  We do. Custom email templates allow you to format the outgoing emails in any way you like--you have full control over the HTML.

Using custom email templates is something that you get as a paid customer of Recapture (since April 2019).  If you want to use custom email templates, please contact us and we'll enable it for your account if you're in a trial, or check to see if you're on the right plan if you're already paying.

Custom HTML is an alternate solution to the designer, you can't mix both of them. If you do custom HTML then you have full control over the template, if you do the designer, you get drag-and-drop editing, but you don't have the same full control.

Custom HTML templates are only available on NEW campaigns you create after the setting is changed by our support staff.  Existing campaigns are not affected--again, you can't mix the old and new.  Each campaign is either "custom" or "standard". 

Important Note for Custom HTML Users

If you create a fully custom email template from scratch using HTML, you must absolutely put this line of comment in your template (we recommend the bottom of the template, before the closing body tag), like this:

The line of code is:

<!-- RECAPTURE_OPEN_TRACKING_IMAGE -->

We will substitute a tracking pixel in that line of code before sending your email.  If you leave this out--you will have an Open Rate of 0% on that campaign!  So make sure you have it and it looks like this:

How to use Email Variables

Custom emails use SWIG template replacement, which is a fancy way of saying you put placeholders in the HTML code and we'll put in the right value for your cart/store when the email is being sent:

Template Conventions

To use the variable placeholders, you'll want to use these template conventions:

{{ object.field_name }}

There's a space on each side of the curly braces for readability-- but they are optional, so this is valid too:

{{object.field_name}}

Variables we support (per email type)

Each type of email has different data available to it, so we have different variables depending on the type of email template you're using.

Abandoned Cart Emails

Abandoned carts are not yet orders, so we know about customers and carts.  Here are the things you can use:

  • {{ action_url }} (the URL to return a customer back to their cart on your site)
  • {{ cart.first_name }}
  • {{ cart.last_name }}
  • {{ cart.email }}
  • {{ cart.grand_total }} (raw number)
  • {{ cart.grand_total_display }} (formatted string)
  • {{ cart.last_active_at }} (date)
  • {{ cart.products[0].name }}
  • {{ cart.products[0].sku }}
  • {{ cart.products[0].price }} (numeric only)
  • {{ cart.products[0].price_display }} (formatted with currency code)
  • {{ cart.products[0].image }} (path to image URL)
  • {{ user.currency }}

Post Purchase Emails (all types)

If you're using Post Purchase emails-- it's slightly different.  Reviews don't come from carts, they come from orders instead.  So you use these in the Post Purchase emails:

  • {{ action_url }} (the URL to return a customer back to their previously completed cart on your site)
  • {{ order.external_id }} (the order number, platform-specific)
  • {{ order.first_name }}
  • {{ order.last_name }}
  • {{ order.email }}
  • {{ order.grand_total }} (raw number)
  • {{ order.grand_total_display }} (formatted string)
  • {{ order.last_active_at }} (date)
  • {{ order.products[0].name }}
  • {{ order.products[0].sku }}
  • {{ order.products[0].price }} (numeric only)
  • {{ order.products[0].price_display }} (formatted with currency code)
  • {{ order.products[0].image }} (path to image URL)
  • {{ user.currency }}

Winback Emails

Winbacks have access to these variables from orders and customers.

  • {{ action_url }} (the URL to return a customer back to their cart on your site)
  • {{ order.external_id }} (the order number, platform-specific)
  • {{ order.first_name }}
  • {{ order.last_name }}
  • {{ order.email }}
  • {{ order.grand_total }} (raw number)
  • {{ order.grand_total_display }} (formatted string)
  • {{ order.last_active_at }}(date)
  • {{ order.products[0].name }}
  • {{ order.products[0].sku }}
  • {{ order.products[0].price }} (numeric only)
  • {{ order.products[0].price_display }} (formatted with currency code)
  • {{ order.products[0].image }} (path to image URL)
  • {{ user.currency }}

Broadcast Emails

Here's what is allowed in Broadcast Campaigns:
  • {{ customer.first_name }}
  • {{ customer.last_name }}
  • {{ customer.email }}
  • {{ customer.phone }}
  • {{ customer.total_order_count }}
  • {{ customer.ip_country }}
  • {{ customer.language }}

Using the Variables Properly

Variables can be used in the body of the email or the subject or both.

Example:  Suppose you want to address the user directly by their name instead of just "Hey there!".  To do that, you can put something like this in your email:

Hey {{ cart.first_name }}!  We noticed that you haven't been back since {{ cart.last_active_at }} and we'd love to see you again...

And you can also use the notion of a "default"--where if the variable is empty, we substitute the default value so it doesn't look weird.  Here's an example with a default:

Hey {{ cart.first_name | default('there') }}!

Note for Jilt Users

If you're using Jilt imported templates, the syntax they supported was SLIGHTLY different.  This syntax should be converted:

Hey {{ cart.first_name | default: 'there' }}!

Convert it to:

Hey {{ cart.first_name | default('there') }}!

We use SWIG syntax (and we're also Liquid compatible as well) The full SWIG syntax available to you is documented here:  http://eddywashere.com/blog/swig-for-designers/

Still need help? Contact Us Contact Us