Tour de force

WooExpert Platinum WooCommerce partner - biggest elephant in the eCommerce room.
Mailchimp Partner Mailchimp partner - you know what’s the newest cutting edge customer experience solution? Great email subject!
Clutch logo Clutch - clients say we’re top dogs in eCommerce. Throw us that stick now.
WordPress Vip WordPress VIP - Enterprise hosting partner

How can a baboon improve your newsletter targeting and distribution?

The mandrill (Mandrillus sphinx) is a primate closely related to the baboon. Mandrills mostly live in tropical rainforests and forest-savanna mosaics. They live in groups called hordes. Mandrills have an omnivorous diet consisting mostly of fruits and insects. Oh wait! Wrong type of Mandrill!

Listen to this article
0.5x 0.75x 1x 1.25x 1.5x

Mandrill is a dependable, scalable, and secure distribution API for transactional emails from websites and applications. It’s an excellent tool for sending data-driven assignable emails, including targeted e-commerce and personalized individual messages.

Primate general characteristics

Mandrill was started as an idea in 2010. under the coverage of MailChimp. It has stayed that way until 2012. when part of the crew separated from Mailchimp and turned to Mandrill thus becoming a separate product. The crew who transferred to Mandrill stayed at Mailchimp corporation, but as an isolated section. They succeeded in turning Mandrill from a skunkworks project into a product that outperforms competitor services. Over the years Mandrill has become largest Email as Service platform on the market, with more than 500,000 active customers. It handles the delivery servers and infrastructure. It is easy to use, incredibly stable and that alone makes him one of the best email marketing platforms.

Habitat essentials

Mandrill is used when you are in need to send automated email like password resets, welcome messages for newly registered users as well as marketing emails and customized newsletters.

Pet owner manual

Mandrill is generally made for developers who are working with code and who love good documentation, integrations, high delivery rates, webhooks and analytics. So if you are not comfortable with code and APIs, it’s recommended to find someone who can show you the ropes before getting started.

Species quirks

Mandrill is special because it’s powerful, scalable, affordable and it is the only email infrastructure service with a mobile app that lets you monitor delivery and troubleshoot from wherever you are.



  • Multiple domains per account – One of the features of Mandrill is the possibility to use it on multiple domains with only one Mandrill account
  • Automatic feedback loop registration – You can track spam complaints through Mandrill because its IP’s are registered for feedback loops with ISPs
  • Globally distributed infrastructure – Using servers which are placed all around the world, Mandrill reduces latency and increases speed of getting messages to users
  • Automated dedicated IP warmup
  • Dedicated IP addresses – Mandrill allows you to add one or more dedicated IP addresses for a small monthly fee
  • Dedicated IP pooling – You can define IP pools, and then tell Mandrill from which pool to send from
  • Searchable activity log – You can search for information about specific emails you’ve sent and filter outbound activity by common criteria
  • Tracking options per email – You can customize tracking options and dynamic content using special tags in your html template
  • Custom tagging – You can add custom tags to track desired categories of email
  • Automatic tagging – Mandrill automatically tags emails based on several elements such as sender and template, enabling you to easily track and filter analytics
  • Split testing – Mandrill enables you to send different templates to a predefined percentage of your users, allowing you to easily track and optimize their interactivity with your content
  • Comparative reports – You have the option to generate user-friendly reports based on multiple criteria allowing you to adjust your emails accordingly
  • Custom metadata – You can add custom information for tracking emails in order to improve your analytics
  • Webhooks – You can use Mandrill analytics in your own database and by doing that you can keep track of feedback such as open rates, clicks and unsubscriptions.

Templates & Dynamic content

Mandrill allows you to create multiple custom templates, to set your own default templates and it makes it easier to edit custom templates for multi-user projects.

  • Automatic Css inlining – This option allows you to generate emails with existing HTML and CSS, without the need to inline your styles
  • Conditional logic and merge tags – Allows you to customize your emails for individual recipients via conditional logic and merge tags
  • Multiple templates per account – You can send from more than one domain within single Mandrill account, also dedicated IP can be used for multiple domains
  • Spam filter testing – You can test your Mandrill templates using Mandrill’s Litmus integration through a series of spam filters

Customizable sending options and white labeling

Mandrill allows you to set your own options for your emails, be it by default or per message.

  • Custom tracking domains – Allows you to label your tracking URLs so recipients can recognize links. Also gives you an option to use your domain as a default for clients who don’t have their own
  • Custom reverse DNS – An option that allows you to fully white label your dedicated IP addresses, which means that you get more control over senders reputation by making it clear to ISPs that IP is associated with you and you only
  • Automatic text and HTML conversion – Mandrill allows you to provide your own HTML and he will automatically generate a text version for display in email clients that don’t support HTML, or Mandrill can generate HTML from your plain-text email so that you can track opens
  • Rules engine – Gives you the option to apply automatic actions to emails without modifying your code
  • Sub-accounts – Mandrill gives you an option to use his quota system to manage and control your system procedural emails

Mandrill comparison to other SMTP servers

Amazon SES (Simple Email Service)
Amazon SES is one of the cheapest providers for sending emails. It has a price of $0.10 per thousand emails, but it’s interface is spartan-like and not comfortable as Mandrill’s or Sendgrid’s. Also, using their API can give you a real headache sometimes. You can use a couple of tools to avoid poor interface, such as Sendy, which is self-hosted interface that uses Amazon SES API for sending your emails. With Amazon SES you can’t send emails using dedicated IP addresses, but only through verified addresses, and analytics are extremely limited. While this is the cheapest option by far, it lacks in service, features and support. Consider using Amazon SES only when you need to get emails into inboxes and nothing else.

SendGrid is possibly the number one spot for sharing in transactional email space. They have incredible email analytics, easy integration with simple API, 24/7 live support and reputation for having one of the best delivery rates. You can consider SendGrid as a service with the best overall balance. SendGrid does not offer notifications for free, lite and bronze packages but only for Silver package and above. This makes it more difficult to use since you have to do everything manually. SendGrid also uses username and password meant for him as SMTP username and password – meaning if you want to revoke someones access to send emails thru your account, you must change your account password and that makes it a little more complicated than other SMTP service providers. One issue is their price. They are the second most expensive provider currently on the market. If you are not troubled with high price and need to opt for marketing emails this is second best options on the market for you. Sendgrid is used by companies like: Pinterest, KickStarter, Airbnb…

Mailjet prides itself with user-friendly interface, neat layout and all-in-one product which is also meant to meet e-marketers expectations about sending, analyzing and enhancing their newsletters and notifications. One more advantage is the international delivery support which is very useful for every company that expects their emails to reach Gmail and Yahoo inboxes but also Orange, BT, Telekom… They have 24/7 support, but through tickets not emails, which means that you will not get answers to your question as fast as on live chat supports. Overall this tool is one of the most expensive solutions you can get as your email sending service, but they somewhat justify themselves through their service.

Mailgun is generally made for developers and that is their main benefit. It appears that their advantages are in their technicalities and getting developers on board. Besides that, their analytics are extremely basic, the setup process is quite complicated and while their pricing is within limits of normal, they are not competitive and overly expensive. And also their support sometimes takes a long time to answer your questions.

Mandrill is leading with their dashboard, interface and the simplicity of the setup process. They also have one of the highest number of free sending emails per month (12,000 emails per month) which is great if you don’t have a large number of subscribers on your lists. They also have a great mobile app, which makes it easier for you to stay updated when you’re on the move. Emails sent through them in most cases never end in spam, and they have everything very well documented. Mandrill uses webhooks to implement some of the functions such as notifications of Bounce and Spam complaints. Also they are great for Mailchimp users since they are part of that firm (but as an independent section). One more advantage of Mandrill is that it uses generated Access key to grant access for sending emails meaning that if you want to revoke sending privileges you only have to generate a new Access key. It also provides reports on keys as a password used for sending emails. Mandrill is used by companies such as: Nike, Electronic Arts, Viber, SoundCloud, Cloudflare, Hootsuite, Airbnb…

PostMark is currently the most expensive email service. They are focusing on providing a service using only the best hardware and software to secure that your receiving rates stay high, and your data secure. Postmark offers very detailed analytics for your emails, it stores 45 days worth of email logs where you can search to find out details of email that were sent over that period. Postmark also has recipient profiles, which keep track of everyone who gets your emails, complete with a list of messages that they have opened, deleted or marked as spam.

Cost Comparison

Number of emails per month
Amazon SESMandrillSendGridMailgunMailjetPostmark
250, 000$25$47.60$199.95$120$178.95$250

Why did we use Mandrill?

Mainly because of it’s generous monthly allowance of free emails (12,000). Secondly because it is very stable, it’s API is ultimately simple, easy to use and it has very good analytics of emails we send.

How to send emails through Mandrill SMTP server?

1. First You have to get Mandrill files from:

2. After You got Mandrill Api files from web you have to copy files from src directory (Mandrill dir and Mandrill.php) to your project directory

3. When you pasted files you can choose to hardcode the information needed to connect to mandrill server or to create interface for that. If you want to create interface then make one .php file with the name such as Mandrill_settings.php

4. Now create index.php that will serve as a plugin who will send all the entered data from created interface to WordPress mailer function and as such change default WordPress SMTP server to Mandrill server

5. What will you first do in index.php file is create header that will tell WordPress to handle your index.php file as a plugin:

* Plugin Name: Neuralab mandrill
* Plugin URI:
* Description: Neuralab mandrill SMTP connector
* Version: 1.0.0
* Author: Alen Meštrov
* Author URI:
* License:

6. After creating header you will have to include Mandrill.php and mandrill_settings.php (interface) files:

require_once "Mandrill.php";
require_once "mandrill_settings.php";

7. Once you imported all needed files you can create hook that will get entered data to WordPress emailer function:

add_action( 'phpmailer_init', 'neuralab_mandrill_phpmailer_init' );

8. After creating hook you can continue by creating function that will replace WordPress default settings for connecting to default SMTP server with your own custom settings:

function neuralab_mandrill_phpmailer_init( $mailer ) {

9. In that function you will fill $mailer object with your own settings who were entered in interface that we will create in next steps:

$mailer->SMTPAuth = true;
$mailer->SMTPSecure = 'tls';
$mailer->Host = get_option( 'neuralab_mandrill_host' );
$mailer->Port = get_option( 'neuralab_mandrill_port' );

$mailer->Username = get_option( 'neuralab_mandrill_username' );
$mailer->Password = get_option( 'neuralab_mandrill_api_key' );

10. Or you can choose to hardcode values into it:

$mailer->Host = “MANDRILL_HOST”;
$mailer->Port = “MANDRILL_PORT”;

$mailer->Username = Mandrill_username;
$mailer->Password = Mandrill_password;

11. After you filled $mailer with compulsory information you can add optional information such as name and email from who was email sent:

$from_name = get_option( 'neuralab_mandrill_from_name' );
if ( ! isset( $from_name ) ) {
     $from_name = 'WordPress';
$from_email = get_option( 'neuralab_mandrill_from_email' );
if ( ! isset( $from_email ) ) {
   $sitename = strtolower( $_SERVER['SERVER_NAME'] );
if ( 'www.' == substr( $sitename, 0, 4 ) ) {
   $sitename = substr( $sitename, 4 );
$from_email = 'wordpress@' . $sitename;
$mailer->From = $from_email;
$mailer->FromName = $from_name;

12. After you done everything you wanted and needed you just have to put if clause on hook that will activate it if you checked in WP admin that you want to use Mandrill server:

if(get_option( 'neuralab_mandrill_use_mandrill' )) {
    //hook in step 7.

13. After you created if clause you are officially done with index.php file of your plugin for wordpress

14. Now you can create .php file that will serve as interface in WordPress admin for entering desired information, I named it mandrill_settings.php

15. At the beginning of that file you will have to create hook that will send created input fields to WordPress function named admin_menu:

add_action( 'admin_menu' , 'neuralab_mandrill_settings_init' );

16. After that you have to create text and check boxes that will hold information about connection. Start with creating function who will draw all these boxes:

function neuralab_mandrill_settings_init() 

17. At the beginning of the function call WordPress function add_options_page() to add that page to WordPress Admin Setting Submenu:

add_options_page( __( 'Mandrill Emailer Settings' , 'neuralab_mandrill' ),
   __( 'Mandrill Emailer' , 'neuralab_mandrill' ),

18. Before i started creating input fields i created check box that will show index.php file to use mandrill or not:

   __( 'Use Mandrill for email', 'neuralab_mandrill' ),

19. After you created settings page you can start creating general settings, you will need input fields for: Mandrill username, password, API key, optional name and email from who the email was sent and Mandrill host and port. In the example is shown for first two fields:

   __( 'Mandrill user name', 'neuralab_mandrill' ),
register_setting( 'mandrill-emailer', 'neuralab_mandrill_username' );
   __( 'Mandrill API key', 'neuralab_mandrill' ),
register_setting( 'mandrill-emailer', 'neuralab_mandrill_api_key' );

20. After you created input fields for all the information needed to connect to mandrill you have to make callback functions which will get entered data from fields to index.php file who will then forward that data to WordPress mailer function:

function neuralab_mandrill_setting_callback_username() {
echo '<input name="neuralab_mandrill_username" id="neuralab_mandrill_username" '
. 'class="regular-text" type="text" value="' . get_option( 'neuralab_mandrill_username' ) . '" />';
function neuralab_mandrill_setting_callback_api_key() {
   echo '<input name="neuralab_mandrill_api_key" id="neuralab_mandrill_api_key" '
. 'class="regular-text" type="text" value="' . get_option( 'neuralab_mandrill_api_key' ) . '" />';

21. At the end after creating callback functions you have to create function that will create that settings page in WordPress admin settings submenu:

function neuralab_mandrill_settings_page() 

22. In that function we will create using html and php calling function that will shape the appearance of Mandrill settings menu:

<div class="wrap">
<div id="icon-themes" class="icon32"></div>
<h2>Mandrill Emailer Settings</h2>
<?php settings_errors(); ?>

<form method="post" action="options.php">
<?php settings_fields( 'mandrill-emailer' ); ?>
<?php do_settings_sections( 'mandrill-emailer' ); ?>
<?php submit_button(); ?>

23. After we made that function we are officially done with making plugin for WordPress that will reroute sending emails from default SMTP server to Mandrill server. For complete code go to:


If you are looking for cheap solution for your email transactional service then your choice should be Amazon SES. It is currently the cheapest provider of this service but lacks in other aspects such as his interface and API. If you are looking for quality, overall good provider, then your choice should be Mandrill because of its overall performance in every field. It has nice looking interface, very easy-to-learn API, good analytics and is somewhat cheap considering other options. With all that it has a very generous monthly allowance of allowed free emails send to customer. If you have dedicated budget you can go with SendGrid which has better support and a little better overall performance but is almost two times more expensive, and doesn’t have monthly allowance of free emails.

Subscribe to our quarterly newsletter

Please fill in this field.
Please thick this field to proceed.

Related blog posts