Creating Mailchimp Emails
Mailchimp emails can be created using the visual editor or custom HTML templates.
When using custom templates, Mailchimp provides special attributes and merge tags that allow marketers to edit content directly from the Mailchimp editor.
These attributes define editable regions, repeatable blocks, and dynamic content within the email.
For the complete reference on Mailchimp template language, see the official documentation.
Creating an Email Template
Section titled “Creating an Email Template”- Navigate to Content
- Go to Email Templates
- Click Create Template
- Choose Code your own
- Select Paste in code
- Add your HTML template and save it
Once saved, the template will be available when creating new campaigns.
Editable Content Regions
Section titled “Editable Content Regions”Mailchimp allows specific parts of the template to be editable using the mc:edit attribute.
This attribute defines areas that marketers can modify in the Mailchimp editor.
Editable Text
Section titled “Editable Text”Example:
<div mc:edit="intro_text"> This text can be edited in Mailchimp.</div>Each editable region must have a unique identifier.
Editable Images
Section titled “Editable Images”Images can also be made editable by wrapping them in an editable region.
Example:
<img mc:edit="hero_image" src="hero.jpg" alt="Hero image">Marketers can replace the image directly from the Mailchimp editor.
Repeatable Content Blocks
Section titled “Repeatable Content Blocks”Mailchimp allows blocks to be duplicated using the mc:repeatable attribute.
This lets marketers add multiple instances of the same section.
Example:
<tr mc:repeatable="content_block"> <td mc:edit="content_text"> Editable content </td></tr>Users can duplicate this block in the editor to create additional sections.
Block Variants
Section titled “Block Variants”Mailchimp allows defining different variations of a repeatable block using the mc:variant attribute.
This lets marketers choose between different layouts directly from the editor.
Example:
<tr mc:repeatable="content_block" mc:variant="image_left"> <td> <img mc:edit="image_left_img" src="image.jpg" alt=""> </td> <td mc:edit="image_left_text"> Content with image on the left </td></tr>
<tr mc:repeatable="content_block" mc:variant="image_right"> <td mc:edit="image_right_text"> Content with image on the right </td> <td> <img mc:edit="image_right_img" src="image.jpg" alt=""> </td></tr>When adding a new block in the Mailchimp editor, users can choose which variant to insert.
Optional Blocks
Section titled “Optional Blocks”Sections can be hidden or removed using the mc:hideable attribute.
Example:
<tr mc:hideable> <td mc:edit="promo_block"> Promotional content </td></tr>This allows marketers to toggle sections on or off depending on the campaign.
Mailchimp Merge Tags
Section titled “Mailchimp Merge Tags”Mailchimp uses merge tags to insert dynamic data into emails.
Common examples include:
*|FNAME|**|LNAME|**|EMAIL|**|UNSUB|**|UPDATE_PROFILE|**|ARCHIVE|*
Example:
<p>Hello *|FNAME|*,</p>If the field is empty, Mailchimp will display a fallback value if configured.
Required Footer Information
Section titled “Required Footer Information”Mailchimp requires certain elements to be included in marketing emails for compliance.
Typical footer content includes:
- unsubscribe link
- mailing address
- permission reminder
Mailchimp automatically injects the account mailing address into the footer if configured in the account settings.
Example:
<p> <a href="*|UNSUB|*">Unsubscribe</a> | <a href="*|UPDATE_PROFILE|*">Update preferences</a></p>Failing to include required tags may prevent the email from being sent.
Typical Email Template Structure
Section titled “Typical Email Template Structure”Most Mailchimp email templates follow a similar structure.
Email wrapper table└ Header └ Logo└ Hero section └ Title / Image└ Content blocks └ Repeatable sections└ CTA section└ Footer └ Company information └ Unsubscribe linksExample simplified structure:
<table role="presentation" width="100%"> <tr> <td align="center">
<table width="600">
<!-- Header --> <tr> <td mc:edit="header_logo"> Logo </td> </tr>
<!-- Hero --> <tr> <td mc:edit="hero_section"> Hero content </td> </tr>
<!-- Repeatable blocks --> <tr mc:repeatable="content_block"> <td mc:edit="content_text"> Content block </td> </tr>
<!-- Footer --> <tr> <td mc:edit="footer"> <a href="*|UNSUB|*">Unsubscribe</a> </td> </tr>
</table>
</td> </tr></table>Using this structure helps ensure better compatibility with email clients.
Email Styling
Section titled “Email Styling”Email clients have limited CSS support, so templates should follow common email design practices.
To ensure compatibility:
- use inline styles
- use table-based layouts
- avoid complex CSS
- test emails across different clients
These practices help maintain consistent rendering across Gmail, Outlook, and Apple Mail.
Common Issues with mc:edit
Section titled “Common Issues with mc:edit”When working with mc:edit regions, there are a few limitations and behaviors in Mailchimp that can cause unexpected results if not handled correctly.
Avoid Nested Editable Regions
Section titled “Avoid Nested Editable Regions”Editable regions should not be nested inside other editable regions.
Mailchimp may ignore nested editable areas or cause unpredictable editing behavior.
✅ DO
<td mc:edit="content_text"> Editable content</td>❌ DON’T
<td mc:edit="content_block"> <div mc:edit="content_text"> Editable content </div></td>Place mc:edit on the Correct Element
Section titled “Place mc:edit on the Correct Element”The mc:edit attribute should be placed on the element that contains the editable content.
Placing mc:edit too deep in the structure can make editing harder for marketers.
✅ DO
<td mc:edit="hero_text"> Welcome to our newsletter</td>❌ DON’T
<td> <span mc:edit="hero_text">Welcome to our newsletter</span></td>Avoid Reusing the Same Identifier
Section titled “Avoid Reusing the Same Identifier”Each mc:edit region must have a unique identifier.
Duplicate identifiers can cause Mailchimp to overwrite content between sections.
✅ DO
<td mc:edit="section_intro"></td><td mc:edit="section_cta"></td>❌ DON’T
<td mc:edit="section"></td><td mc:edit="section"></td>Mailchimp Email Best Practices
Section titled “Mailchimp Email Best Practices”To ensure reliable rendering and editing:
- ensure all mc:edit regions have unique identifiers
- keep modules simple and reusable
- test templates in multiple email clients
- verify styles when browser autocomplete is applied
- avoid unsupported CSS properties
Do’s and Don’ts
Section titled “Do’s and Don’ts”Use editable regions for dynamic content
Section titled “Use editable regions for dynamic content”✅ DO
<div mc:edit="intro_text"> Editable content</div>❌ DON’T
<div> Hardcoded content that marketers cannot edit</div>Ensure editable regions have unique identifiers
Section titled “Ensure editable regions have unique identifiers”✅ DO
<div mc:edit="header_title"></div><div mc:edit="header_subtitle"></div>❌ DON’T
<div mc:edit="header"></div><div mc:edit="header"></div>Use repeatable blocks for flexible layouts
Section titled “Use repeatable blocks for flexible layouts”✅ DO
<tr mc:repeatable="feature_block"> <td mc:edit="feature_text"></td></tr>❌ DON’T
<tr> <td>Static content that cannot be duplicated</td></tr>Always include required Mailchimp tags
Section titled “Always include required Mailchimp tags”✅ DO
<a href="*|UNSUB|*">Unsubscribe</a>❌ DON’T
<a href="#">Unsubscribe</a>Knowledge Check
Test your understanding of this section
Loading questions...