Reliable email delivery is important to your business: your website probably has a contact form for hiring inquiries; your web application(s) rely on email for interaction with your clients, heck, you might even rely on your server to send email for e-commerce transactions. If those emails do not reliably reach you or your (prospective) customers, you’re, quite literally, losing business.
After a couple of years of struggling with email I have finally found the solution to make sure each of my emails reaches the inbox of its recipient and I’m about to share it with you.
Note: this is not a paid review. In fact, since Postmark doesn’t have an affiliate program, it’s not even a post with some affiliate links. It’s just me solving a problem for myself that I hope you will now be able to solve too.
The problem: email not reaching its recipient
I wrote about email reliability before, but let’s be honest: getting all the web servers we use for sites to send email reliably is a pain. You need to setup SPF records, preferably set up DKIM too and make sure that your web servers do not get blacklisted. One of my servers, for which I had set up SPF, for some stupid reason got blacklisted a couple of weeks ago, resulting in a couple of website review emails not reaching my customers. I hated that so much that I started looking for another solution.
On this site, I had switched from Gravity Forms to Wufoo a while back. Wufoo is another awesome web forms service, with the at that time “added value” that Wufoo would take care of the email sending for me. My main gripe with using Wufoo was that I really wanted my forms and the entries of my forms in my site’s install, not somewhere else. On top of that, Gravity Forms gives me a bit more programming flexibility, so I wanted it back. So, I had two email problems and started to look for a solution to both at the same time.
Postmark: reliable email
I found that solution in Postmark, which handles transactional email through a set of reasonably simple but reliable API’s. Using this pre-built library, I was able to replace the email sending in my website review application for Postmark within about 10 minutes.
Yes, Postmark costs a bit of money, but if you consider that at $1,50 per thousand emails, you run a lot smaller chance of losing customers over email not reaching its destination, it seems to me that that’s money well-spent.
It took me a bit longer to code a WordPress plugin that I liked for Postmark. There are a couple of WordPress plugins listed on the Postmark site, but all of them relied on CURL, which I don’t have on every server I run WordPress on, and they all ignored some of the headers that plugins like Gravity Forms passed along. So I used the same pre-built library, but adapted it this time to use the WordPress HTTP libraries and added a wrapper to more reliably pick up all the headers that might get added by plugins.
The result is a plugin that is pretty easy to use, my own Postmark Email for WordPress Plugin.
WordPress email sending tips
By default, WordPress sends email from email@example.com, where example.com is your domain. In 99% of cases this is a non-existing email address. More and more people, including Postmark, are saying that using a non-existent email to send your email from is not a good idea. I agree. So I created firstname.lastname@example.org, which gets filtered into a tag in my email.
The great thing about actually creating that email address is that you can also assign a gravatar to it. This means that when people use email clients like Sparrow, or other email clients that support Gravatar, they’ll see a nice avatar image for your email too. In my case, I made sure that image was the Yoast logo.
Go forth and email!
And please do let me know your comments about both Postmark, the plugin and your tips for reliable email in the comments!