Modified on: Thu, 30 May, 2019 at 8:56 AM

Copied from: https://support.1-grid.com 

This guide will take you through the steps of setting up DNS records for Office 365 within cPanel. Please note that you should replace “example.co.za” with your own domain name when setting up your own records. 

 

1. Log in to cPanel. 

 

2. Click on “Zone Editor”. 

 

 

 

3. Click on “Manage” next to the domain you wish to add these records to. 

 

 

 

4. Click on “Add Record”. 

 

 

 

5. Enter your Office 365 verification record. 

 

 

 

NameYour domain name. 

TTL: Can remain the default setting. 

Type: TXT. 

Record: MS=ms12345678 (Microsoft should provide the exact record). 

 

Wait a few minutes so that the record you just created can update across the Internet. Now you'll have to go back to Office 365 and request them to look for the record. 

 

6. Log in to your Office 365 Admin centre. 

 

7. Click on “Setup” then “Domains”. 

 

8. Choose your domain. 

 

9. Click on “Start setup”. 

 

10. Click on “Verify”. 

 

 

 

Microsoft should provide you with more DNS records to add now. 

 

11. Go back to the “Zone editor” in cPanel. 

 

12. Click on “MX” in the filter and delete any existing MX records. 

 

 

 

13. Click on “Add record” and select MX as the type. Enter the MX record given to you. 

 

 

 

14. There are about six CNAME records to add. This will be added one at a time. Click on “Add record” again. The type will be “CNAME”. 

 

 

 

This is what the record will look like before adding it: 

 

 

 

15. To add the TXT record, click on “Add record” and select “TXT” as the type. 

 

 

 

This is what the record will look like before adding it: 

 

 

 

16. There are two SRV records. To add the SRV record, click on “Add record” and select “SRV” as the type. 

 

 

 

Name:  _sip._tls.example.co.za. 

Name:  _sipfederationtls._tcp.example.co.za. 

All other required information will be provided by Microsoft. 

 

17. Lastly, we have to change the “email routing”. Click on the home button. 

 

 

 

18. Click on “Email Routing”. 

 

 

 

19. Select your domain in the drop-down section, ensure that your routing is set to “Remote Mail Exchange” and click on “Change”. 

 

 

 

That’s it! You’ve successfully added Office 365 records. Typically, it takes about 15 minutes for these changes to take effect. Since it needs to update across the Internet's DNS system, it can take up to a few hours. 

 

 

Example of DNS records for the domain(s) in question:

# Record Type TXT

example.com.au.   3600   TXT   MS=ms000000

example.com.au.   3600   TXT   "v=spf1 include:spf.protection.outlook.com -all"

 

# Record Type MX

example.com.au.   300    MX    0 example-com-au.mail.protection.outlook.com.

 

# Record Type CNAME

autodiscover             3600  CNAME autodiscover.outlook.com.

sip                      3600  CNAME sipdir.online.lync.com.

lyncdiscover             3600  CNAME webdir.online.lync.com.

msoid                    3600  CNAME clientconfig.microsoftonline-p.net.

enterpriseregistration   3600   CNAME enterpriseregistration.windows.net.

enterpriseenrollment     3600   CNAME enterpriseenrollment.manage.microsoft.com.

 

# Record type SRV

_sip._tls                3600  SRV    100 1 443    sipdir.online.lync.com.

_sipfederationtls._tcp   3600   SRV   100 1 5061  sipfed.online.lync.com.

 

Notes:

  • The MS record shown in red is a number supplied by Microsoft as part of the verification rocess.
  • The MX record contains the domain name as a prefix, with periods replaced by hyphens.
  • SPF, Once it has been approved and active with Office 365 you will need to add in your webserver IP to the SPF record. "v=spf1 +a include:spf.protection.outlook.com -all"

Then, change the Email Routing setting down the bottom to "Remote Mail Exchanger".