There are certain things that appear simple at first, but turn out to be more difficult and complicated than you imagined. Sending emails from your website is one of these things.
To see why this is so, we first have to understand the types of emails sent from a website. There are two broad types of email a business sends: marketing emails and transactional emails. Marketing emails are things like newsletters. There’s no reason to complicate your website by putting it in charge of marketing emails. On the other hand, transactional emails are emails that are sent to users based on what they do on your site. An example would be a purchase confirmation email.
Let’s take the example of a WordPress site. WordPress has a default mail functionality that calls PHP’s mail method. On many servers, this method already works out of the box. If it doesn’t, it’s relatively easy to install Postfix to get basic Message Transfer Agent (MTA) functionality. There are several general issues with sending emails directly from an on server MTA:
This is the single most important reason to use a transactional email service. It’s not professional to ask users to look in their spam folders for your emails, and this is what you’ll have to do unless you implement a bunch of things that email services include out of the box. To setup proper email delivery from your server, you’ll have to add an SPF record to your DNS, create, configure & implement DKIM, create a DMARC record, ideally have a dedicated ip, and setup reverse DNS and PTR records.
When a developer tells you, “Oh, yeah, I can install Postfix so WordPress will send email. It’ll take me half an hour,” they’re likely not including all of the above, which means your emails to customers might end up treated like spam. This leads us to the second reason. Using a commercial product can seem more expensive than using built in server functionality, but it’s actually cheaper.
Many commercial services have generous free tiers. If you consider the hourly rate of a developer as part of the price needed to setup email properly on a server so that it delivers reliably, then server email can be much more expensive than a service. Why pay a software engineer to reinvent the wheel?
Additionally, the total cost of owning a mail server doesn’t stop at the setup. Once you have a server you must patch, maintain, monitor, and – when something goes wrong – fix it. Problems with email queues are numerous. When something goes wrong with your email server, you’ll be in charge of scheduling and overseeing that it gets working again. These are things you do not have to take ownership of with an email service. Overall, an email service will not only be cheaper than an MTA on your server, a service will also be more resilient.
Your first impression may be that it is more convenient to use server email. After all you don’t have to create an account or compare services. But we’ve already covered the fact that there are complications to setting up email delivery from your server. Additionally, once you get setup with an MTA, you’ll appreciate the many built in helpful features of transactional email services. With an email service, you can review previously sent email, track who opened their emails, and often look at more granular analytics – like click tracking. You can also create reusable templates.
Email services also handle the html and text portions of emails correctly. They make it easy to add opt out links to your emails. These are things that can be done manually, but again it’s more work.
Picking a Transactional Email Service
At Solid Digital we often lean on Sendgrid, but there are many services to choose from. Take some time to compare pricing and functionality among services like Mailgun, Amazon SES, Sendgrid, Mandrill by Mailchimp, Postmark, Sparkpost, and many more.
Here are some of the questions you should ask when picking a service:
- How easy is it to integrate? Or do I need help integrating the service?
- Is the api well documented?
- Does the service have a well supported WordPress plugin? (assuming you’re using WP – if not, is the service easy to integrate with the platform you’re using?)
- What kind of data and analytics does the service have?
- What is included in their free tier?
- How does pricing change based on volume?
Which of the previous services you choose is probably less important than being aware of transactional email services and using one!