There are a few special tags you can add to the body of your marketing email These tags are case insensitive so if you make a mistake SendGrid knows what tags you want to use.

You can also add custom tags to your emails. Custom Tags can be created by going to Marketing Email > My Recipients > Manage. From here you can choose the list you wish to create tags for by clicking on the custom tags menu item in the list table. Simply click on Add a Custom Tag and enter in your tag name. We will automatically generate the tag name based on what you’ve entered.

Be sure to use a tag name the corresponds with an actual column of data in your recipient list file. If not, the tag will not insert any data into the content of the email and the end user will see the custom tag. If you have created a new custom tag for a recipient list (one that has no column of data) then we will create a new column for you on your recipient list that you can backfill with the correct data so when using the custom tag actual data will be passed into the content of your email.

[weblink]

Place the [weblink] tag in the body to provide a link to a hosted copy of the email content. The tag is replaced with the URL, so to create a link, use the following HTML:

1
<a href="[weblink]">View this email in your browser</a>

[unsubscribe]

Place the [unsubscribe] tag in the body to provide an unsubscribe link. The tag is replaced with the URL, so to create a link, use the following HTML:

1
<a href="[unsubscribe]">Unsubscribe from these emails</a>

Sender Address Tags

There are several tags you can use to embed sender address information in your email body. Available tags are [%from_name%], [%address%], [%city%], [%state%], and [%zip%].

1
2
[%from_name%]
[%address%], [%city%], [%state%], [%zip%]

Custom Tag Sending Best Practices

At SendGrid we are always trying to help our customers send marketing email more efficiently. We recently did some research and attempted to provide some best practices when creating email custom tags. Below are some tests we ran to provide our customers custom tag benchmarks to consider when sending large volumes of marketing email.

The Test

The total number of custom tags was computed based on:

  • The MAX size of the POST Request allowed by the WEBAPID (20480000 b = almost 20Mb)
  • The MAX size of the content (characters) of each custom tag.
  • Batch sending (of 1000 recipients per batch)
  • Tests Results

  • 256 characters per content - total allowed custom tags: 75
  • 128 chars per content - total allowed custom tags: 140
  • 64 chars per content - total allowed custom tags: 250
  • Recommendations

    You should try to keep your custom tag total character count relatively small especially if you want to use more custom tags in your emails. If you choose to have custom tags with a lot of characters then try to limit the total amount of custom tags in your recipient lists. Referencing the tests above you can determine a safe amount of tags to use depending on the size of those tags that can result in efficient email batching when sending Marketing Email with SendGrid.