MultiSMTP
MultiSMTP is a plugin for WordPress to connect the site to an SMTP for email delivery. It supports 3 configurations, so you can easily switch between different SMTPs or automatically rotate between them.
What's inside
First installation
Get the plugin package from the link below, go to Plugins/Add New/Upload in your site and upload the package.
Once installed, it will update automatically when new releases are available.
Settings
You can configure more than one SMTP and then set the one you want to be active. It’s useful when you need to quickly change to another SMTP for tests, limits and the like. For example, I have a second SMTP Mailtrap that I activate when I need to make tests and get all the emails captured.
Of course, do not forget to switch back to the main SMTP once done. I say it because I know… :-)
When the SMTP is set to “Disabled”, the plugin does not change the mailing behaviour of your site.
The sender’s email
If you set it, all emails are changed to use that “From” address. By default, WordPress sends email as wordpress@domain.tld. I never understood why they never added the option to set the from address.
The delay
This is a special option to add some delay between every email. It makes the delivery process slower, but you may be constrained by the provider to not send more than N emails per second.
The value is in milliseconds, so you can set it to 2000 if the provider requires a delay of 2 seconds.
If you have high site activity, many emails could be sent at the same time due to distinct users interacting. In this case, the delay could not be effective; it acts correctly when more than one email is sent in a row during the same “session”.
SMTP rotation
There are options to automatically rotate the SMTP used to deliver emails:
- Rotate once per email. It means every email is sent by changing the SMTP (selecting the next one). If the site needs to send three emails in a row, for example, while sending a newsletter or a scheduled notification to many users, the SMTP is changed on every sent email.
- Rotate once per session. It means an SMTP is selected and used for the whole session (process). For example, if a user is buying from your site and the checkout process sends three emails (the welcome email for the first purchase, the order confirmation, and a promotional email with a discount code for the next purchase), all those emails are sent with a single SMTP. The next “session” (for example, another checkout) will use another SMTP.
Increase the SMTPs
You can increase the number of configurable SMTPs by defining a constant in your wp-config.php file. Add:
define('MULTISMTP_MAX', 5);
That line of code sets the number of SMTPs to 5.
FAQ
I see a new version, but the plugin does not update.
Please let me know about this problem; it could be due to incorrect repository management on this site or within the plugin code. Anyway, to update, you can download the zip again and follow the instructions for the first installation.
Emails are not delivered.
Please, install the plugin WP Mail Logging to see if the emails are actually sent, and if they don’t show up in the recipient’s mailbox, contact the SMTP provider.
Is there any queuing mechanism?
No, there is no queuing mechanism. As far as I know, there are SMTP plugins that provide such a feature.
Emails take a very long time to be delivered.
The plugin, as done even by WP, sends the emails immediately. The delay is to be attributed to the SMTP service; try to contact the SMTP provider.
I want connect the site with Gmail.
It’s not possible with this plugin. Gmail does not expose a classic SMTP service and requires special authentication steps. There are SMTP plugins compatible with Gmail.
