A guide to understanding and fixing email issues in LifterLMS
Email, the first universal online communication method, is an essential part of our identities. So much so that it’s a lucrative target for wrongdoers, leading to really stringent security measures. These measures can trap your transactional business emails, often without any warning. That’s why it can seem incredibly difficult to resolve email issues and ensure delivery.
We think it makes sense for you to get a deeper understanding of emails than an average netizen – to make the most of it and to avoid common pitfalls. Even if you do end up getting into trouble, you should know of a couple of strategies for troubleshooting. So we put together this guide to save your valuable time and effort on endless back and forth where everyone involved seems to blame everyone else when all you want is a solution!
What this guide will do
- Help you understand how emails work with LifterLMS (and WordPress).
- Describe the role of your hosting provider in sending emails.
- Explain how and why email sending can fail or get delayed.
- Explain why emails can land up in the spam folder and how to check for and prevent it.
- Introduce you to dedicated SMTP providers and the problems they can solve.
- Help you get the most out of LifterLMS support when you need help with email issues.
What this guide won’t do
- Give you a lot of details or exact step by step instructions for. We will provide pointers and the general idea but the exact instructions would differ from host to host.
- Make you an expert of some kind who can handle all email related issues on their own. You may still need to hire a developer for some of the things described in this guide. Emails are critical and sensitive, and we won’t recommend messing with things on your own.
SMTP
Emails are sent and received using the Simple Mail Transfer Protocol (SMTP). SMTP is similar to the File Transfer Protocol (FTP) for transferring files and the Hypertext Transfer Protocol (HTTP) for transferring web pages in the sense that they are concerned with transferring something between clients and servers. (A more detailed explanation can be found here: How Emails Work.)
The SMTP server is separate and different from your HTTP server (that handles web pages). The key thing to understand here is: whether the email is created in an email client (like Outlook or GMail), or via code on your WordPress site (like LifterLMS does), it is the SMTP server which handles the actual transfer.
Usually, a web hosting plan will include all three kinds of servers within the same setup. This means that:
- Your website’s performance and speed is distinct from that of your emails.
- It is possible to have a separate SMTP server outside your hosting plan that can be used to send out emails in case you have difficulties with the bundled SMTP service.
Outgoing Queue
Once an email is created and sent, it isn’t actually sent immediately. All outgoing emails land up in a queue which is then processed gradually depending on the available resources and settings.
An SMTP server is just a piece of software consuming memory, processing and storage. If there were no queue and a large number of emails were sent at the same time, the SMTP server could get overwhelmed and fail to send most of them. In theory, a queue ensures that emails get sent out, even if they get delayed.
Incoming Emails
Emails are sent to the recipient SMTP server. From this server, they are downloaded onto the receiver’s email client using other protocols (IMAP or POP).
The recipient SMTP server (or the email client) has mechanisms in place that can identify an email as useless and dump them in the spam folder of the user. Additionally, it can straight away reject an incoming email because it violates policies or seems dangerous. Such emails don’t reach the user at all (not even as spam)!
As described in the earlier section, emails can be sent by code. Technically speaking, LifterLMS doesn’t send any emails, PHP does (since LifterLMS is built on top of WordPress and both of them are pieces of PHP code). Under the hood, LifterLMS uses WordPress’s wp_mail() function which in turn uses PHP’s mail() function.
It is really important to note that LifterLMS, WordPress and PHP don’t actually send the email out, they just add the email to the outgoing queue. It is the SMTP server that actually sends the email.
Since LifterLMS doesn’t (and can’t) send the email, it can’t really detect whether the actual sending failed or succeeded. We just assume that once the email has been added to the queue, it will be sent successfully. That’s why, even with a success message from LifterLMS, an email could still fail because of issues with the SMTP service.
Depending on your hosting plan, the resources available to your site (and hence your SMTP service) can be limited and affect the processing of the outgoing queue. In addition, many webhosts will place a rate-limit or a cap on the number of emails that will be processed per hour, per month or something like that.
At best, it means that some emails will get delayed until their turn arrives. The delay can be of a few minutes, hours, days or longer. In the worst case scenario, your provider may simply drop any emails beyond the allowed capacity.
The problem with this is that neither LifterLMS nor any other WordPress plugin/tool will be able to identify or fix this issue. Only your hosting provider (or one of their tools) can help. Which is why we often recommend switching to a dedicated third party SMTP provider if emails fail. Especially when nothing seems wrong in WordPress and your webhost isn’t really helpful.
A note on shared hosting
On a shared hosting plan, the performance of your SMTP service can be affected by the other sites on the same shared environment. You might be roomies with a site that sends out a lot of emails consuming an unfair share of resources.
Sharing of resources also means sharing of what is understood as the origin of an email by the recipient. If you share resources with a spammy site, your emails could be considered spam by association.
For an email from your LifterLMS site to reach your users’ inbox, a lot of steps and factors are involved. Any of them could go wrong in many ways:
- LifterLMS needs to compose and use the WordPress’s email API correctly.
- WordPress’s email function needs to work correctly.
- PHP’s mail functionality needs to work correctly.
- Your SMTP server needs to work correctly and process the queue properly.
- The recipient’s SMTP server should accept the incoming email (because it can simply refuse to do so).
- The recipient’s email client (that connects to the recipient SMTP server to fetch the email) should recognise the email as legitimate and place it in their inbox. It could identify your email as spam and that’s not good!
That’s why it can be difficult (but not impossible) to pinpoint the exact reason why an email would fail to send or why your recipients won’t get them.
With a simple process of elimination though, you can at least figure out who to contact – the LifterLMS team, your webhost or a WordPress developer for hire. That could really save you a lot of time, even if it doesn’t solve your problem instantly.
Locating the Culprit
Working backwards through the steps of email transfer above, we could locate the source of the problem, at least partially:
1. Do some users receive the email and others don’t or is no one getting your emails?
The ones who didn’t receive your email could probably find it in their spam folder. Email clients will often dump emails from any unknown address into the spam folder. To prevent this, users can simply add your email address to their Address Book. At other times, it could be more complicated and you may have to get into more complex troubleshooting.
If your emails don’t show up even in spam, it could mean two things. First, it could be that the outgoing queue is currently overwhelmed and those emails have been really delayed or dropped by your SMTP server. In such a case, contact your webhost for more information.
What’s equally possible is that the recipient server rejected your email. In such a case, it would usually send a message back to the address notifying you that this was the case. If the sender email address has an inbox, you should ideally check it for any rejection messages.
In any case, neither LifterLMS nor WordPress can do anything to help. If your emails are rejected or marked as spam, use the troubleshooting techniques described in a later section.
2. Do some emails just arrive late?
If your emails are getting delayed, obviously your SMTP server is unable to keep up. Again switching to a third party SMTP service is recommended.
3. Do email issues only crop up sometimes, intermittently?
This means that when your email load increases, your SMTP server doesn’t manage to keep up. Again switching to a third party service is the way to go.
4. Are all emails from your site affected or only LifterLMS ones?
There could be a lot of emails outside LifterLMS that are sent by your site (new account registration, reset password, for example). You may also have other plugins that send emails as part of their functionality. If those emails work just fine and only LifterLMS ones are affected, it could be a problem with LifterLMS. You should definitely reach out to us for help with this.
It is important to note that this may not be an issue within LifterLMS. Since LifterLMS uses WordPress’s email mechanisms, another plugin could interfere with and prevent LifterLMS emails from working properly. This would only happen in case of a poorly built plugin that tries to take over and control WordPress’s default email mechanisms. Always choose well coded plugins from reputed teams over obscure ones.
Another thing to note is that sometimes webhosts prioritise user management emails over the ones sent out by plugins like LifterLMS. In such a case, all such emails would get delivered promptly without any issues but all other emails (including LifterLMS ones) will get delayed or simply dropped. In this case, you would face issues with other plugins’ emails as well. If you don’t have such a plugin, you can use tools to test your outgoing email.
Emails are marked as spam to protect the receiver. SMTP allows using any “From” address on the outgoing email. Without this flexibility, WordPress or LifterLMS wouldn’t be able to send emails on your behalf. However, this means that anyone can send an email claiming to be from any address in the world. This spoofing is what has evolved into dangerous scams including phishing.
So, the receiver (SMTP/Client) needs to ensure a couple of things:
1. Is the sender trustworthy?
Well, this depends on many factors. Organisations co-operate with each other and maintain and share blacklists of known offenders.
When you buy hosting or a domain name, it could so happen that the last owner was a scumbag and hence ended up on one or more blacklists. If you’re on a shared host, any of the current or former sites that share your resources could land all the sites on the same environment on such a blacklist.
If your site is on one of these blacklists, there’s practically nothing you can do to get off of it. The only way out is to move your site to a different server. If you’re on a shared hosting plan, your webhost can move you to a different box.
2. Is the email a forgery?
A recipient SMTP service (or client) can verify that an email is from the real sender only if the source of the email can be authenticated. Such authentication comes in two common forms: Sender Policy Framework (SPF) and DomainKeys Identified Mail (DKIM). You may need the help of your webhost or a competent developer to set them up correctly.
SPF
An SPF policy is simply a TXT record in your domain’s DNS settings. Recipients can check your domain registry where you’ve authorized your SMTP service to deliver emails on your behalf. You can find instructions on how to set that up for almost all webhosts here.
DKIM
DKIM adds a digital encrypted signature to outgoing messages. Setting up DKIM is a bit like SPF. You start by adding a new TXT record to your DNS. Then you add a unique public key for each source of email for your domain.
Most webhosts (and third-party SMTPs) will provide you the public key and other instructions. This can be used by recipients to verify that the email isn’t spoofed and to make sure that messages haven’t been altered on the way.
You can check your SPF & DKIM records here:Â https://www.mail-tester.com/spf-dkim-check. If they aren’t set up or you don’t know what to do, contact your hosting/SMTP provider.
3. Does the email contain stuff that looks suspicious?
Most email clients will also use algorithms to check the content for spam in ways similar to the tools that identify spam comments on your blog. If the email reads like spam, it will most likely end up in spam.
One of the ways email clients recognise spam is by comparing and contrasting with what the particular recipient (and all the recipients on their system) usually marks as spam. That’s how they train their algorithms.
Obviously, this can be fixed by using original, good quality content instead of generic spins and rip-offs. If you send poor and spammy content, there are good chances that a user or algorithm will start marking your emails as spam setting off a chain reaction that ultimately lands you in a blacklist!
Outgoing Email
You can test if your site is able to send outgoing emails at all using the nifty Check Email plugin.
After installing it, go to Tools > Check Email to see a screen that allows you to enter a recipient address and send a test email:
If the email arrives in the recipient’s inbox (even if in spam), your outgoing SMTP service is working just fine!
Spam Check
We recommend using MailTester.com along with the Check Email plugin above for checking the spamminess of your emails.
To run the test,
- Visit mail-tester.com and copy the automatically generated email address.
- Go back to Check Email (under Tools > Check Email) and paste this address in the field labeled “Send test email to:” and hit “Send test email“.
- Go back to the tab where you have mail-tester open and click the button that says “Then Check your Score“.
- The test may finish quickly or it may take some time (indicating issues with your SMTP service), but eventually you will get a score and a list of issues with a unique url for the spam test report.
Share the copy of the generated report with your hosting provider/ developer to fix any issues and improve your score. (Read more about this test here:Â https://www.mail-tester.com/faq.)
The easiest way to fix this is to just switch to an SMTP service listed in the next section.
The following three SMTP providers will work very well for your LifterLMS powered WordPress site. They all have a free WordPress plugin as well as support to help you get started.
- SendWP | WordPress Plugin – Send unlimited emails for $9 per month with your first month free. A 1-click installer is included in LifterLMS.
- MailHawk | WordPress Plugin – A WordPress plugin dedicated to sending WordPress emails. A 1-click installer is included in LifterLMS.
- Mailgun | WordPress Plugin – Send 10,000 emails free per month.
- SendGrid | WordPress Plugin – Send 12,000 emails free per month.
- Mandrill | WordPress Plugin – From MailChimp as a paid add-on. It costs $10/month for up to 25,000 emails. Emails are tracked and tagged for stats in the Mandrill Dashboard, and it can be used with MailChimp.
The LifterLMS Support Team is always ready to help with your site. However, it can get extremely frustrating and time consuming if after a series of back and forth, all we tell you is to contact your hosting provider or to hire a developer. To ensure prompt and speedy resolution of your email related issues:
1. Check if you should contact LifterLMS support team, at all.
Use the questionnaire listed earlier to find out if the issue is with LifterLMS. In 99.99% of all email issues reported to us, it would have saved our users a lot of time and effort if they had contacted their hosting provider or simply switched to a third party SMTP provider.
2. Make sure Engagement Log is turned on and attached to your request.
Ensure you’ve enabled engagement debug logging. Once you’ve done that, ensure that your log is recording data by triggering a few emails to send. When you open your support ticket please attach the engagement log.
As must be absolutely clear by now, a lot of factors outside LifterLMS control whether your email will be sent or received successfully. There is a questionnaire and a couple of tools that can help you locate the issue or at least, the right people to reach out to. This can save you (and us) a lot of time, effort and frustration.
Most often than not, the issue is related to the settings and capabilities of your SMTP service and switching to a third party SMTP service will solve most of your problems.
If you have any questions or feedback about this guide or anything else LifterLMS related, feel free to get in touch with our support team by logging into your account at https://lifterlms.com/my-account/ and submit a support ticket or post the issue in our WordPress support forum at https://wordpress.org/support/plugin/lifterlms.