If you'll be using your own HTML to create your MailChimp campaigns rather than one of our available templates, there are a few things you'll want to keep in mind while creating your content. Below we'll go over some common errors made when creating HTML emails and show you how to avoid them in your own code.

Your HTML email is just one giant graphic

We don't recommended using just a single graphic as your email content. Most email programs block the automatic downloading of images by default, so your recipients will initially see a blank email and will either delete it immediately or even report you for spam. Your HTML email needs a healthy balance of graphics and text. If you're just sending a simple invitation or a simple promotional piece to your recipients and all it needs is a single graphic, you can still include text in the footer area. Your unsubscribe link, physical address, and list permission reminder will all count towards the text to image ratio.

Not testing your campaign fully

Before you send your email campaign to your entire list, you'll definitely want to do some testing. To ensure the best possible result, we recommend sending tests to all the popular web based email services, like Yahoo!, Hotmail, and Gmail. Depending on your audience you might consider setting up AOL and Comcast accounts if possible, or set up accounts with major ISP's in your area. You can also use the Inbox Inspector tool to preview how your email will appear in multiple clients. Take a look at this article for more email testing tips.

Not testing emails created by a web designer

If you asked someone else to create your email for you and you're simply pasting in the code he or she gave you, don't just trust that it will work as expected. You'll need to send yourself some test campaigns and make sure everything displays the way it should. Be sure to check that it wasn't designed too wide to fit in the preview pane of most major email programs. It's a good idea to test the images and links to make sure they work as expected and are set up as absolute paths.

Using Microsoft FrontPage, Word, or Publisher to create HTML content

When using Word, Publisher, or FrontPage to generate your HTML content, extra "junk" code can be added to your campaign inadvertently. This code can break your email design or even result in your campaign getting filtered as spam. You should only code HTML email in a good old-fashioned text editor and then import the template or paste the code into MailChimp.

Using JavaScript in HTML email

Just about every single email application out there blocks JavaScript from working as a security measure to prevent viruses. Make sure your code doesn't contain any JavaScript such as on form submit buttons, pop-up window links, image pre-loaders, widgets, etc. If you're copying HTML from an existing web page, make sure you clean the code of all JavaScript. While our Campaign Builder will remove any JavaScript we're able to detect, we still recommend testing your campaign thoroughly before sending to ensure it displays correctly.

Using CSS Incorrectly

Linked CSS files rarely work in HTML email and many email applications won't preserve your embedded CSS. For example, many browser-based email clients will strip out the HEAD and BODY tags of your HTML email so your embedded CSS doesn't interfere with the CSS on their page. We recommend embedding your CSS just above your content below the BODY tag, or even better- using inline CSS instead. We even offer an automatic CSS inliner for your custom-coded campaigns! Click here for more info.

Using spammy content

We all get spam. You know what it looks like. The subject lines are IN ALL CAPS, letters are highlighted bright red or bright blue, they SCREAM by using lots! of! exclamation! points!!!! and they use phrases like, "hottest, best, click now! limited time only!, and act now! Keep your subject lines brief and to the point. Keep your content relevant. Don't try to use gimmicky catch phrases. Avoid spammy words. More advice on avoiding spam filters here.

Hosting images on a local or private server

We've seen some people do their work on a "staging" server or on their "network drive" and forget that the general public won't have access to those servers (and so images will be broken). You'll want to upload and host all images on a public server so that they display correctly in your email. If you don't have a public server, never fear! You can upload the images to our server and then link to them in your email.

Not using "absolute" paths for images and hyperlinks

With HTML email, you need to host all of your images on your server, then use absolute paths that point back to your server. So, instead of coding an image like this:

<img src="/images/photo.gif">

You would code it like this:

<img src="http://www.mysite.com/email/images/photo.gif">

Same goes for hyperlinks. Instead of a link like this:

<a href="index.html">Click here</a>

You'd code the link like this:

<a href="http://www.mysite.com/index.html">Click here</a>

If you're coding your emails locally with some kind of WYSIWYG application, they'll often keep graphics in a folder on your computer and reference them with "relative" links (relative to the location of your HTML file). Always make sure you go back and check that all <IMG> tags use absolute paths. One little tip is to go ahead and upload all your email's graphics to your server at the very beginning of your project. That way, you'll have to use absolute paths from the get-go.

Not including our unsubscribe link

We require all email campaigns sent through MailChimp to have our properly coded *|UNSUB|* tag. There's absolutely no exception to this rule. It must be present in both the HTML email and the plain-text email.

Not including a permission reminder

You should always include a brief reminder of how you got the recipient's email address. You know, such as "You received this email because you subscribed at www.example.com for our newsletter." Trust us, it prevents tons of false abuse complaints, which could get your company's domain name blacklisted. That's right---your domain name, not just ours. Again, if you had just used one of our built-in templates, we'd do this for you.

Not including your postal address

It's required by the U.S. CAN-SPAM law now (which we also require even if you don't live in the U.S.) to include a valid physical mailing address on all emails sent through our servers. The address is automatically inserted whenever you use our built-in HTML email templates, so if you're coding your own you will need to add it manually.

Other Useful Resources:


Related Articles