background shape
background shape

Proof multiple template variants in SFMC

When working with dynamic email templates that can generate multiple unique variants of the email, you are most probably tasked to proof all the variants to your stakeholder for review.

Create data extension

When proofing email templates, traditionally, we select subscribers from production or testing data extensions used in the actual send. This process involves proofing each template individually, changing the subject line for distinction based on language, country, or other segmenting fields altering the email copy.

Here’s a more efficient approach:

Firstly, set up a testable, sendable data extension to store proofing records. Create a CSV file with the required column names, and add data; typically, it mirrors the structure of the data extension used as the target population for the email campaign in which the template is utilized.

Salesforce Marketing Cloud - Testable and sendable data extension settings

A good practice is to store these testable data extensions in a defined folder, simplifying proofing and ensuring centralization for easy access by any future campaign manager.

Sending proofs in one batch streamlines the process, removing the burden of searching for correct records in production or UAT data extensions suitable for a specific delivery template variant.

Add personalization AMPScript

  IF _IsTestSend THEN
      SET @sl = Concat(  Uppercase(@Country), " ", Uppercase(@Language), " ",  Uppercase(@Segment), " ", Uppercase(@Audience), " ",  "]:", @subjectline)

This AMPscript snippet is used in the context of an email send and is checking if the email is a test send (_IsTestSend is a system variable or rather called personalization string by salesforce, that is true if the send is a test).

If the condition is true (meaning it’s a test send), the AMPscript sets a variable @subjectline using the Concat function. This variable is a concatenation of various values, including:

  • Uppercase(@Country): The uppercase version of the @Country variable.
  • Uppercase(@Language): The uppercase version of the @Language variable.
  • Uppercase(@Segment): The uppercase version of the @Segment variable.
  • Uppercase(@Audience): The uppercase version of the @Audience variable.
  • “]:”: A string that separates the concatenated values.
  • @subjectline: The value of the @subjectline variable.

So, it’s essentially creating a string that combines these variables and strings, and the resulting string is assigned to the @subjectline variable. This kind of dynamic subject line modification is often used in test sends for easier identification and tracking during testing phases.

Variable @subjectline contains templates subject line set dynamically depending on the segment or language. Subject line is displayed by following snippet set to email template properties.


Proofing the template

Now, let’s proceed to proof our multivariant template. Open the template and go to the Preview and Test section.

In the Test send tab, choose Test data extensions and select the data extension created for this email template in the previous step.

Salesforce Marketing Cloud - Preview and Test email using test data extension

Set the subject prefix to the email template name or a descriptor understandable to your stakeholders. Our AMPScript will dynamically incorporate segment codes and language during the send process.

Salesforce Marketing Cloud - Adding subject line prefix to test email

If you use Adobe Campaign or are just curious, you can read the same article for guidance on proofing multiple variants of an email template and add variant to subject line of such proof email.

Oh hi there 👋
I have a FREE e-book for you.

Sign up now to get an in-depth analysis of Adobe and Salesforce Marketing Clouds!

We don’t spam! Read our privacy policy for more info.

Share With Others

Leave a Comment

Your email address will not be published. Required fields are marked *

MarTech consultant

Marcel Szimonisz

Marcel Szimonisz

I specialize in solving problems, automating processes, and driving innovation through major marketing automation platforms.

Buy me a coffee