Tom Morris



2009.05.07

  No. 944 

How to send the perfect HTML e-mail 2009-05-07T00:05:04ZPermalink

It's very simple. You simply remove all the HTML elements and attributes, processing instructions, DOCTYPE headers and excessive whitespace. The only exception is you need to take the data from the href attributes of a and use that in the place of the text() of the element. Scan the document for mentions of "Click here", "click" and so on. Then be sure you've read RFC 1855 and acted upon it's wise counsel. Once that's all done, hit send.

Why? Well, an e-mail is not a webpage. A webpage is on the web. It's viewed by a web browser. An e-mail gets displayed in a mail user agent (MUA). E-mails get indexed by software that is calibrated for coping with text/plain. The point of HTML is that it's a representation format for hypertext documents. I have yet to see an e-mail that wouldn't be better as text/plain. And, yes, other people disagree. I don't particularly give a shit. E-mail means text/plain.

Yes, you can do multipart MIME. But that just means you are sending at least twice the amount of data across the wire. What this means is that if I am downloading mail over a dodgy GPRS connection at roaming rates, it is going to cost me at least twice as much to download your e-mail. Twitter, who recently started using bundling HTML e-mail on top of text/plain messages using multipart MIME, is now sending me 3.2K of bloat I don't care about, but I still have to pay for, with each e-mail. For what? A fancy blue box around the same information? Pointless. And sending HTML e-mail tends to encourage this utterly pointless practice.

Engineers at Twitter are smart enough to figure out how to send multipart mail. Most mail user-agents are not very smart. And the lumps of flesh who use those MUAs are even less smart. They see fancy HTML in their MUA, and they decide that they want to send me their whole e-mail in 36-point yellow. It would be much better for me, and would be a negligible cost for Twitter, to put a checkbox right on the account notifices panel.

A hint: if you are ever helping someone set up a box, when you set their e-mail client up follow these instructions and make plain-text the default. Don't disable it, but just make the default not suck. That way, when your friend wants to spam the world with inline pictures of his offspring annotated in blink tags, marquee tags and Java applets, he must do so explicitly.

Go and read Zeldman's first blast on HTML mail. He recants after all the marketing droids pile on. But it's important. Just as you should make webpages that conform to web standards, you should make e-mail that conforms to e-mail standards. A central e-mail standard is text/plain.

Links from del.icio.us

Comments
blog comments powered by Disqus


Tom Morris 9f4907d871750fd4c9b9bad7086701b51d6abd10 bd9f81a05283ed85e699175ed057b4a497f20b77 802c68123e12bf69d99a25a87cef360f18813fe4
Currently in: East Sussex, England
Usually in: East Sussex, United Kingdom
AIM: tommorris
YIM: tom.morris

I am a , an , like to code in and (and Java, but let’s not talk about that), and noodle about with and the .

I have an MA in philosophy from Heythrop College, University of London. My philosophical interests are in analytic metaphysics, ontology, modality, the work of , , , and . I have a strange, unfulfilled interest in . I’ve been influenced by Gadamer, by , , and .

Musically, I like jazz fusion, soul and P-Funk. My musical nirvana would be a mixture of Beethoven, Miles Davis and George Clinton topped with a side-serving of Erykah, Jill and Angie.

I also write for the Citizendium, an online encyclopedia project. If you know about stuff, you should join in. I occasionally produce audio recordings for The Pod Delusion.

Elsewhere:

  • GPG Key
  • del.icio.us
  • Flickr
  • Twitter
  • Jaiku
  • LinkedIn
  • ma.gnolia
  • blip.tv
  • upcoming.org
  • MetaFilter
  • LiveJournal
  • CiteULike
  • Technorati Profile

RSS Feed Subscribe:

RDF

« May 2009 »
SuMoTuWeThFrSa
 12
3456789
10111213141516
17181920212223
24252627282930
31 

View in month context

On this day in: 2006 2007 2008