Sitecore Send: Campaigns complete guide

Igor Zharikov on November 11, 2023
Email marketing

About

Sitecore Send, as part of Sitecore DXP system, is a great tool to manage and send email campaigns. It allows to use different types of campaigns, but it's not always clear which to use in some situations. In this article I will review various campaign types and provide use cases when to use each.

Campaigns

Regular

Sitecore Send makes it easy for you to create an email marketing campaign. You can create a crafted email message and send it to one or multiple email marketing lists.

Regular campaign is probably the simplest type of email campaign: it’s designed for a one-time use. As soon, as campaign in configured to be sent, it’s no longer can be edited. The only way to make any changes is to create a new campaign or copy already sent campaign. But it comes with all Sitecore Send built-in features:

  • build-in Designer with lots of predefined templates
  • preview campaign before sending it to recipients
  • send it now or schedule delivery for later
  • run Spam Test to check how it rates against various popular spam filters (like Gmail, Hotmail, Outlook, Yahoo)

And of course, you can track performance of your campaign and gather all various statistics about it.

As Regular campaign is designed to be sent only once and to all recipients in the list or segment, the use case for it would be some global campaign, such as:

  • Global sales and discounts
  • Suggestions for holidays
  • Seasonal offers
  • Most recent updates or upcoming events
A/B testing

An A/B testing campaign is an email campaign that lets you test two different versions of the same campaign on part of your mailing list and then automatically send the version that performed better to the rest of the recipients on your list.

The test can be configured on:

  • Subject line
  • Content - the email itself
  • "From" - different senders

For a single A/B test only one criteria can be chosen as test variable (so it's not possible to configure 2 versions for subject and content in a single test).

Then when the content for test is prepared, you can configure other A/B testing settings:

  • Sample size for A & B and the winner size. Sitecore Send suggests to use Pareto principle (by default the split is done by this principle): 80/20. Meaning 10% of recipients will receive version A, 10% - version B, and the winning version will be sent to the rest 80% of email campaign audience. It goes without saying that the bigger the email list is the more statistically significant and accurate results you’ll get. If you have a small email list (e.g. under 1000 subscribers) you can increase the sample size to ensure you have accurate data about which variant works better.
  • Winner version criteria: highest number of opens or clicks – depending on the content of email campaign or the purpose of your test
  • Test time duration: how long the test will run before winning version will be sent

AB test settings

I can suggest to review this article for best configuration of your email campaign in Sitecore Send.

This campaign should be used in the same cases, as a regular campaign, but if you want to evaluate 2 versions of the campaign and send the best one to most of recipients.

RSS campaign

An RSS campaign is an email marketing campaign that gets updated content from an RSS feed. For example, you can connect your campaign directly to the content of your RSS. Every time a new publication appears in the RSS feed, an email is triggered automatically.

To design your campaign, you have 2 options: use special RSS Layout in the email editor or use HTML import and special syntax.

RSS layout in Designer

This is an example of showing latest 5 articles in custom HTML campaign design:

#rss:articles:5#
#rss:url# <!-- The URL of the relevant article page -->
#rss:title# <!-- The title of this article -->
#rss:summary# <!-- The summary of this article -->
#rss:image# <!-- The image URL of this article  -->
#rss:category# <!-- The category of this article  -->
#rss:publishedOn# <!-- The published date of this article  -->
#rss:id# <!-- A unique ID for this article  -->
#rss:articles:end#

RSS campaign can be used to notify user about any continuously published content: events, articles, blogs, recipes, changelogs, etc.

Repeatable

A repeatable HTML campaign is a type of campaign that automatically gets new content from a designated website resource.

Configuration

In the settings of repeatable HTML campaign, we need to provide Content URL setting.

During each campaign send Sitecore Send requests email body only once (there’s no requests for each recipient with some recipient information). So, for each customer this campaign looks the same. But you can still use personalization tags inside your campaign body.

Note. If you want to skip the campaign sending, you can return 204 status code (No Content) or any non success Http status code.

Usage

The use case for Repeatable campaign is continuously published content (the same as RSS, but maybe you don’t have an RSS feed generated – only API, or you need some advanced filtering/sorting or any other logic for your data, which RSS feed doesn’t provide by default).

Another example is continuously updated content:

  • exchange rates
  • market indexes
  • new arrivals in e-commerce
  • discounts increases during sale season
Example

Check this Git Repository. This is a simple express-based server, that provides HTML email templates can be used in the repeatable campaigns.

By this url the template can be downloaded:

repeatable email template

And here is example of one of sent emails:

repeatable email example

Automated

Sitecore Send simplifies automation creation with preconfigured templates or recipes that serve as starting points for your automation designs.

Sitecore Send Automations is really big topic, which won't be covered in details here. But you can check some documentation and my articles:

Transactional Emails

Transactional emails are messages that are sent in response to an action a user takes on a website or application. They contain data or content that is specific to that user, and are typically sent to individuals one at a time.

Different types of transactional emails

  • Password reset emails
  • Account creation emails
  • Welcome emails
  • Shipping confirmations
  • Payment invoices
  • Purchase receipts
  • Order confirmation emails
  • Payment failure notifications

Transactional emails should be sent via SMTP using Sitecore Send SMTP server. Check the documentation for configuring SMTP in Sitecore Send.

For code reference you can use this service which sends email using Sitecore Send SMTP:

public async Task Send(string to, string subject, string html, string campaignId = null, string listId = null)
{
    var from = _smtpOptions.From;
    var message = new MailMessage(from, to, subject, html)
    {
        IsBodyHtml = true,
    };
    if (!string.IsNullOrEmpty(campaignId))
    {
        message.Headers.Add("campaign_guid", campaignId);
    }

    if (!string.IsNullOrEmpty(listId))
    {
        message.Headers.Add("mailing_list_id", listId);
    }

    _logger.LogInformation("Send Email '{subject}' to {to} (from '{from}')", subject, to, from);
    using var smtp = CreateClient();
    await smtp.SendMailAsync(message);
}

private SmtpClient CreateClient()
{
    var client = new SmtpClient(_smtpOptions.Server, _smtpOptions.Port);
    client.Credentials = new NetworkCredential(_smtpOptions.User, _smtpOptions.Password);
    return client;
}

The body for the email can be prepared by your own using any template engine (Mustache, Handlebars, Razor, etc.) or you can check my article about using Sitecore Send for managing design of your Transactional emails.