I got a job to set up a new business website for a client. The job involved setting up a brand new Wordpress website on a new host and not on the old host they were currently with. Their domain names and email were also registered at the old host too but would not be moved.
So, the new Wordpress website went up without a hitch but I ran into a problem where a form on the contact page that was using the Contact Form 7 plugin wouldn't send emails to any 'whoever@companydomainname.com' email address, it would however send emails to any other address (eg. whoever@yahoo.co.uk, whoever@hotmail.com etc) as long as it didn't use the @companydomainname.com.
To resolve this I contacted my hosting support and they instructed me to go into cPanel, go to Email and select MX Entry.
Then select the 'companydomainname.com' and make sure Email Routing was set to 'Remote Mail Exchanger'.
Unfortunately this alone did not fully solve my problem.
It wasn't until further investigation on the DNS Zone settings for the domain name at the old host that I discovered they were using Office 365 for their email and not the built in host email service I had assumed.
I discovered this because of three DNS Zone records that looked like this:
v=spf1 include:spf.protection.outlook.com -all
autodiscover.outlook.com
clientconfig.microsoftonline-p.net
I then went into the cPanel on the old host and checked the Email MX Entry for the domain, which looked like this:
companydomainname-com.mail.protection.outlook.com
So I copied this and went back to the Email MX Entry on the new host. I selected the 'companydomainname' and then removed the 'companydomainname.com' under the MX Records section.
I then inserted companydomainname-com.mail.protection.outlook.com into the destination box under the 'Add New Record' heading and clicked 'Add New Record'
The companydomainname-com.mail.protection.outlook.com then appears in the MX Records section
After this the form on my website would correctly send emails to any whoever@companydomainname.com email address.
Hope this helps someone out.
This link was also useful
So, the new Wordpress website went up without a hitch but I ran into a problem where a form on the contact page that was using the Contact Form 7 plugin wouldn't send emails to any 'whoever@companydomainname.com' email address, it would however send emails to any other address (eg. whoever@yahoo.co.uk, whoever@hotmail.com etc) as long as it didn't use the @companydomainname.com.
To resolve this I contacted my hosting support and they instructed me to go into cPanel, go to Email and select MX Entry.
Then select the 'companydomainname.com' and make sure Email Routing was set to 'Remote Mail Exchanger'.
Unfortunately this alone did not fully solve my problem.
It wasn't until further investigation on the DNS Zone settings for the domain name at the old host that I discovered they were using Office 365 for their email and not the built in host email service I had assumed.
I discovered this because of three DNS Zone records that looked like this:
v=spf1 include:spf.protection.outlook.com -all
autodiscover.outlook.com
clientconfig.microsoftonline-p.net
I then went into the cPanel on the old host and checked the Email MX Entry for the domain, which looked like this:
companydomainname-com.mail.protection.outlook.com
So I copied this and went back to the Email MX Entry on the new host. I selected the 'companydomainname' and then removed the 'companydomainname.com' under the MX Records section.
I then inserted companydomainname-com.mail.protection.outlook.com into the destination box under the 'Add New Record' heading and clicked 'Add New Record'
The companydomainname-com.mail.protection.outlook.com then appears in the MX Records section
After this the form on my website would correctly send emails to any whoever@companydomainname.com email address.
Hope this helps someone out.
This link was also useful
It works for me! Thanks
ReplyDeleteGreat glad it helped
DeleteHow long did it take your DNS to repopulate?
ReplyDeleteNot long, under an hour from memory
Deleteworked a treat, thanks
ReplyDeleteHi, Did you have to do both changes? Set 'Remote Mail Exchanger' and add the MX record companydomainname-com.mail.protection.outlook.com
ReplyDeleteI have the same issue on a company website so don't want to break their incoming mail
Yep, exactly as I have it written above, it shouldn't break their incoming mail as you are not configuring any settings on their actual incoming mail server.
DeleteThanks
DeleteI have the exact same situation as described here. however my contact 7 form won't send emails even if they are going to a different address. I'm using hostgator and the client is using office 365. I made the changes you suggested but nothing...even an hour later. I'm at a loss at this point.
ReplyDeleteNever could get this to work. I had to install an SMTP plugin.
ReplyDeleteThanks
ReplyDeleteNo problem, glad to be of help
DeleteThank you! You helped me so much... I have been searching for a fix for 3 days now!!! This worked... My website host had installed a plugin "WP Mail SMTP" which I had to disable... No one could fix our issue... until I came across your post xxx
ReplyDeleteYep took me a while too, glad it helped you out
Delete10+ hours of troubleshooting Contact Form 7 (myself),
ReplyDelete2 Upwork freelancers who were supposed to make the form work,
3 hours on the phone with Godaddy....
and it turns out that all I needed was this
1 article.
Thank you for sharing. You are a godsend. Seriously. THANK YOU for this!!!
No problem, glad it saved you some hair loss
DeleteThank you so much! Glad I stumbled across this article in the early stages of also discovering this problem. Sounds like you saved me a lot of time.
ReplyDeleteNo problem, hope it helps
DeleteThanks so much for sharing this! I had the exact same issue, and this fixed it in minutes.
ReplyDeleteGreat, thanks for the comment
Deleteworked for me, thank you!
ReplyDeleteNo worries
Deleteworked for me, thank you!
ReplyDeleteGreat, glad it helped
DeleteHello, I have made the settings like you did but It didn't work still.
ReplyDeleteHere is a screenshot of my SMTP settings
https://prnt.sc/t5nqpq
and here are the settings of cPanel https://prnt.sc/t5nrvx
I want to get the Form Responses to my Office 365 mail not to GoDaddy's mail, can you help please?
Have you tested to see if you can make the form responses go to a yahoo/gmail/hotmail address?
DeleteThis worked for me on bluehost.com as well although the steps were slightly different. I was able to use this post to figure it out. Thanks!
ReplyDeleteWorked perfectly! Thanks!!
ReplyDeleteNot all heros wear capes
ReplyDeleteThanks very much
Delete