Throughout my daily tasks, one of the things I often find myself doing is coding HTML emails for newsletters, promotions, etc for many of my clients.

For the most part, this is simple. But to help anyone who is new to this area, or even to help a seasoned developer who is looking for some new tips, here are some things I have discovered over the years.

You must use inline style sheets.

Yes, I know this goes against every moral fiber in your body. It pains me to do it. But if you want the messages to display properly in sites like gmail, yahoo mail, MSN / Hotmail, as well as the desktop based clients such as Thunderbird, outlook express, and outlook, it must be inline style sheets.

For those who don’t know what an inline style is, here is an example.

Not all style tags are available in all email clients

What this means? There are things you just can’t do in css. Break out your old-school HTML writing skillz (yes, with a ‘z’) and some things will just have to be done the old-fashioned way.

The best chart I have found that shows what is compatible in various clients, is here at campaignmonitor.com.  There may be a better comparison chart out there. If you find one, post it in the comments and I’ll update the post.

Use Email on Acid

No, they’re not paying me to put this in here, I just genuinely love their product. And it’s cheap.

http://www.emailonacid.com

If you send more than one or two emails per month, buy their unlimited account. It’s $12.95 a month, and it has an awesome interface. Very useful for seeing how your message will appear in a huge variety of clients.

Learn to hate Outlook 2007 and 2010

These two email clients will be your hardest to code for. Why? They don’t support anything useful. Why? The use the Microsoft Word rendering engine for displaying HTML.

Accept this as a painful truth, and use it to your advantage to make more money.

After you’re done making more money, head over to http://fixoutlook.org and support the cause to petition to Microsoft that this needs to be fixed.

Post any additional tips as comments. If they’re good, i’ll add them to the post.