How to Fix WordPress Not Sending Email Issue
Articles,  Blog

How to Fix WordPress Not Sending Email Issue


Hey there, welcome to WPBbeginner and thanks
for tuning in. In this video I’m gonna show you how you can fix the WordPress
not sending emails issue. If you use a form on your site, say like gravity
forms or WPForms then you need to rely on your website for sending emails and a
lot of times if your site isn’t sending emails it’s because you’re hosting
provider they don’t have the PHP mail function turned on on the server and
that’s ok we actually recommend that you use SMTP for sending email that is the
Simple Mail Transfer Protocol and its the industry standard for sending emails. To
get that going on your site I’m gonna walk you through in this video how
to set up a mail gun account and how to connect that to your website so that you
know that your emails are getting sent on your website. So the first thing we want to do is we wanna go ahead and go to mailgun and we want to sign up. The service is quite
affordable the first 10,000 emails a month are free. So I’m going to go ahead and create an account real quick and then we’ll move on. Once you create an account you’re gonna see this area and you want to just
scroll down because we’re gonna add your domain here. I’m gonna click add domain from here we need to add a subdomain. We’ll create the subdomain on our website host platform
so I’m gonna keep this open. We’re going to create the subdomain and that’s going to be on
our own hosting site so what we need to do is go ahead and keep this page open
but we need to go to our hosting account. Log-in to the cPanel and we’re going to
scroll down and we’re looking for the subdomains area. From here I’m gonna click on
the subdomains because I want to create one. You can see this is the one I want to
use if you have multiple domains you wanna pick the one that you want to use this for and I’m gonna type mail1 so it’s basically going to be mail1.mydomain. Alright, now that we
created that I’m gonna copy that information, go back to mailgun, I want to add that subdomain here and then click add domain. Okay, now we need to go through and do some
verification. What it’s saying here’s you need to go the DNS provider so again
you need to go back to your hosting account go to the home area and this time we want to go on to
advanced DNS zone area to set this up. There are two records that we want to enter. This
text one and this text one so we want to enter this value and this information on
our advanced DNS area. Okay, so first thing I’m gonna do is copy this info, add it into the name
area the time to live we’re gonna put the default 14400 this is a text type, and the
address I’m gonna come over back over here copy that value add it here and add
record. Alright, successfully added we can see it down here need to do the same thing for the other
one. Can copy this information, add that to the
name area. I’m gonna grab this whole piece add it to the
address time to live here is the default, the type is text based and then I’ll paste that data there and I want to add that record as well. Alright that one was added
successfully as well right now that I’ve entered that I need to go back
to my cpanel homepage and I need to make an entry. I’m looking for the MX record
entry because I need to make an MX entry. From here and choose the root domain
and I want to add what I see here so it’s a ten priority and this value
so do ten, destination will be that, add the new record. Alright now we’ve added everything
that we need to to the hosting side so now we need to go to our actual
WordPress website go ahead and log-in. Under plugins we want to add new
and we’re searching for the plugin called mailgun for WordPress. I’ll hit enter, and this is the one we want from mailgun so we’ll install now and we want to activate it alright once it’s activated you need to go into settings
and we want to go ahead and set all of this up. Yeah we want to use the HTTP API setting
that’s the default and that’s perfect for what we’re doing. The mailgun domain name you want to go
over to your mailgun site and copy this domain up here. put that there, and then you also wanna grab your API key from your mailgun site put that here here you can decide if you want to choose to track your clicks and the
open rates of the emails can also add a tag for further tracking and analytics
and then here’s a short code for later. But we want to just save these settings
and then we want to test configuration make sure everything looks ok you and now that we have a
success and with that we fix the issue of not being able to send emails from our
WordPress website. if you like this video click on the like button and go ahead and leave us a comment there we’d love to hear from you and subscribe to our
YouTube channel to get the latest videos

44 Comments

  • Dandelion Web Marketing

    I love that you've given a thorough walkthrough for a complicated set up. Thank you! I do wish you had said more about the situations that arise that signals the need to do this. Should I do it for any WP site that has a form? Is it only necessary with certain form builders? (I've been using Visual Form Builder Pro and Formidible.) What kind of problems will I experience that signals I should go through these steps? Thanks again!

  • Jaime Carrión

    Yesterday I tested everything I could possible image to get my emails notifications on time and in a reliable way. This worked immediately! Thank you! Thank you! Thank you!

  • Carmia Jordaan

    Thank you so much for making this video! I have a problem with Woocommerce emails not sending and have been using Mandrill for that. Now that Mandrill is forcing us to have a paid Mailchimp account I had to look for alternatives. Thank you for showing how to setup Mailgun – it's much appreciated!

  • George Meidhof

    Ok, somewhere I missed something. I installed mailgun and it was verified. Now I want to send all my users an email, and I don't see where you do that. What am I missing?

  • Etiros

    Tried setting this up, and now I'm getting a 403 error on my site, and I can't even login to the backend after updating the DNS records. I'm lost.

  • Terry Murphy

    Well I was also seduced into trying to follow your instructions, however, after configuring MailGun and having my domain mgr add the txt records, it worked for 24 hours, and then failed. Since then, neither Mailgun nor my host seem to be able to work out what is wrong, but they are both blaming each other. I think I will have to uninstall Mailgun…

  • girlzeyeview

    Totally worked! Thank you so much! This is something that has driven me nuts on many occasions. I used Contact Form 7 for my form. I was using another plugin at first and it wasn't working. But Contact Form 7 is super easy and sets up all the fields for you automatically.

  • Acme Dream Company

    Once again – you guys saved my butt! I installed GMAIL SMTP server 8 days ago. Working perfect until this morning. I had been troubleshooting all day long. I would say after about 11 hours of terror, I did a simple Google search – brought me here. I watched the video, did the work…and come tomorrow I will not have egg on my face. I can't thank you enough. This is the 7th time you guys have helped me! What can I do? Can I guy you a pizza?

  • Shree Mahesh Heritage

    Namaste, Can someone help me for Contact form 7 Not sending meail and – Giving Red Alert – Failed to send your message. Please try later or contact the administrator by another method.

  • Saydu Naydan

    I have mailgun installed, test configurated successfully … but I still can't receive emails yet. I'm using Zerif lite template… Not sure what's wrong.. Any idea plz ?

  • Muhammad Ali

    When I click the forgotten password link it redirects me to the homepage. Any ideas how to fix this. Thanks and great video.

  • Sezro

    This still doesn't work for me. Am I supposed to delete the old DNS settings? I see the original settings and the new ones I made for mail gun in my cPanel.

  • Venky P

    Warning: Setting the wrong option here can break receiving mail on your server. If you are at all unsure about which option to select, contact your system administrator.
    way this is showing?

  • Yarob Al-Taay

    Your key shows up at 5:36 ! I would disable this key if you have not done so already. Thanks for the video
    https://youtu.be/GhKSg5-FskM?t=336

  • BleepinJeep

    I did it and the emails came back! But now all the links in the emails start with emaildotmail1 and the links don't work, even when I try and modify them without that part. Please Help!

  • unTamed

    Hi! Option 4 does not show up for me on Mailgun, I can't see the "Add DNS Records for Recieving", only "For Sending". Please help!

  • Jeffrey Thomas

    Hi, I have a issue with not receiving contact from the forms on my website. I have a contact form and a free lesson form both use mailgun. WordPress says they are sending. The site developer used their API key and I have set up my own mailgun account. Do I just enter my API key?

  • Daddy SmokesYams

    Followed these instructions and still am not receiving emails. At this point I'm a little irritated simply because I'm not having the same complications using other forms. Catch 22 is WP Forms has the easiest and best set up imo. Question remains what's the point if they don't even work?????

  • Susan Maas

    Why are the MX records put under the root domain instead of under the subdomain? I have my professional email ([email protected]) set up through a third party service — Zoho — so I already have MX records for Zoho in my root domain. Can I still put the MX records for Mailgun in my root domain, or will this create a conflict? How should this be handled?

  • Lex Lush

    Hi! Thank you for this amazing video! I'm getting this error after following your instructions when I test the wordpress plugin settings (note that I have added my email address to authorized recipients as well):

    “Mailgun HTTP API Test Failure; status “Free accounts are for test purposes only. Please upgrade or add the address to authorized recipients in Account Settings.”

    Do you happen to know how to resolve this matter?

  • Sarah

    When a user signs up to my website with a username etc.., they don't get an email to activate their profile. My wordpress website is using a dating software plugin, will this work for this issue?

  • Alper Gedik

    You know what I'm doing for 5 days? I'm "listening" this video over and over again because your voice is so soft and your pronunciation is so clean and soothing. Very musical, very liquid.

    Keep up the good work!

  • Disgusting Lil' Pup

    Nevermind my previous comment, got the MX records added.. It still says unverified and in the plug in when I test configuration it states Failure…

    Any reason why? I followed the guide, is it because there is a 24 to 48hr wait time?

  • Mitch Billsen

    Thanks so much for this, I was able to set up my mail successfully. I had to dig around a bit on the godaddy cpanel to find the right settings, but it worked like a charm once I worked it out.

  • Richard F

    A mailgun account is completely unnecessary. Geez!
    Just use one of the many free SMTP plugins for WordPress. Better, fast, free, less messy
    Don't shoot yourself in the foot with Mailgun!

  • Tolulope Dahunsi

    this is actually not the solution, simply use the free SMTP plugins in wordpress, copy your mail settings from your Cpanel and thats it. why pay MailGun when you can do it free from your cpanel.

  • Beyon Electrónicos

    I saw the MX records are optional, my account is already active but it can only send emails to 1 recipient… why? can you please help me out with this?

  • Benoit Labbé

    I am trying to use Event calendar, so that visitor can register for event and receiv Email confirmation, the emails are not being sent event though I have setup Mailgun. any idea please ?

  • Alex Mwailu

    "The email could not be sent. Possible reason: your host may have disabled the mail() function." Someone help me solve this problem

Leave a Reply

Your email address will not be published. Required fields are marked *