Add a Link in a Campaign
You can use Mailchimp's content blocks to turn any text into a link. Learn how to create and style text links in your campaign.
Hey there! Free trials are available for Standard and Essentials plans. Start for free today.
Get the job done with a pro
From training to full-service marketing, our community of partners can help you make things happen.
Add a table of contents to your campaign layout to keep your content clear, organized, and easy to navigate. This helps your subscribers quickly find the information that interests them, so they stay engaged with your campaigns.
Mailchimp offers two ways to set up a table of contents in your campaign: the *|MC:TOC|* merge tag and custom anchor links. The *|MC:TOC|* merge tag creates a table of contents for you, which contains links to headings in your campaign. Anchor links allow you to build your own table of contents with custom wording, link style, and formatting.
In this article, you'll learn about the two ways you can add a table of contents to your campaign.
Here are some things to know before you begin this process.
The *|MC:TOC|* merge tag inserts a table of contents with links to the headings you choose. First, you'll format the heading text you want to appear in your table of contents. Then, add the *|MC:TOC|* merge tag to the section of the campaign where you want to place the table of contents.
When you send to your audience, we'll replace the merge tag with a table of contents that includes the headings you formatted in your campaign.
First, choose what type of TOC heading style to use. To apply a standard heading format to your text, choose a TOC heading style from the drop-down menu. If you want to manually style how the heading appears in the campaign body, choose TOC title, and apply additional styles. Note that changes you make here won't affect how the table of contents looks.
To format text as a TOC heading or TOC title, follow these steps.
After you format your content headings, add the *|MC:TOC|* merge tag to any Text content block to insert the table of contents. The text and link style of the table of contents will match the campaign section it's in, and can't be changed. If you need to customize it, try anchor links instead.
To add the table of contents merge tag, follow these steps.
All done! You've successfully added a table of contents to your campaign. To see how your campaign will appear in your recipients' inboxes, look at it in Preview Mode.
Preview and Test Your Email Campaign
View and Edit Section Design
If you use a custom HTML template, you can still use the *|MC:TOC|* merge tag to insert a table of contents. Just be sure you've formatted each heading with the right tags, and you'll be ready to go.
First, open the template's source code and add class="title" or class="mc-toc-title" to the < span >, < div >, < h1 >, or < h2 > tags of the headings you want to appear in the table of contents. These classes don't work with < h3 > and < h4 > tags, so try < span > tags instead if you need them.
Your formatted headings should use one of the examples in this table. Either class type can be used.
title | mc-toc-title |
---|---|
<span class="title"> | <span class="mc-toc-title"> |
<div class="title"> | <div class="mc-toc-title"> |
<h1 class="title"> | <h1 class="mc-toc-title"> |
<h2 class="title"> | <h2 class="mc-toc-title"> |
After you edit your tags, you'll add *|MC:TOC|* where you want the table of contents to appear in your template.
*|MC:TOC|*
< div class= "title" id= "alumni-news" >
For more flexibility, create links to anchors in your campaign content. It's a little more work, but it allows you to customize the text and link style in your table of contents. First, you'll add anchors to the headings in your campaign content. Then, you'll input your table of contents text, and link each item to its anchor link.
To add anchor links to your heading text, follow these steps.
Now that you've added anchor links to your campaign, you're ready to input the table of contents text and add links to each item.
To add and format your table of contents, follow these steps
You can use the buttons in the editor toolbar to customize the style and wording of your table of contents. When you edit your table of contents, be sure to only highlight the text you want to change. Depending on the edit you make, you could remove an existing link and need to re-add it. To see how your anchor links will appear to recipients, preview and test your campaign.
The *|MC:TOC|* merge tag and anchor links are not supported by all email clients, and may not work as expected when a campaign is viewed on a mobile device.
So before you send, we recommend you preview and test your campaign and send a few test emails to yourself. To see how a variety of email clients will display your table of contents, use our Inbox Preview tool.
Campaign Behavior on Mobile
Preview and Test Your Campaign
Test with Inbox Preview
Here are a few other things to keep in mind if your table of contents doesn't display as expected.
The blank < base > tag you add to your HTML should look something like this.
< head >
< base href= " ">
< /head >
Technical Support
Have a question?
Paid users can log in to access email and chat support.
You can use Mailchimp's content blocks to turn any text into a link. Learn how to create and style text links in your campaign.
Merge tags let you insert dynamic content in your campaigns. Get a list containing each merge tag and how to use it.
Use merge tags to insert dynamic content, like names or titles, in your emails. Learn about merge tags, where to access them, and how to create new ones.