Office 365 DNS Setup Guide

In this article we will outline how you can obtain and configure the DNS records used for connecting your cPanel account to your Office 365 service. As the DNS records used for this are account-specific they will need to be obtained from your Office 365 account.

Integrate Office 365 with your Shared Hosting account to take your business to the next level!

Below we will cover:

Locating your Office 365 DNS Records  

To locate your Office 365 DNS records, you need to first verify your domain in Office 365. This can be done via the following instructions:

  1. Log into your Office 365 account.
  2. Navigate to the Setup > Domains page.
  3. From there, select the domain you want to use, then select Start Setup, which will then display the value needed in the next step. 
  4. Go to the Verify Domain page.
  5. Select Add a TXT record instead and press Next
  6. Copy the TXT value that is displayed, which should look something like the following:
  7. Create the TXT Record using this value via the Zone Editor in cPanel.
  8. Go back to your Office 365 account and verify your domain. 
  9. Remove the TXT record in the cPanel Zone Editor once verified. 

Now that the domain is verified, you can locate the MX records in your Office 365 account via the following instructions:

  1. Log in to your Office 365 account and navigate to Setup > Domains.
  2. From the domains tab, select the domain you verified in the previous section.
  3. In the Required DNS Settings area, you will see the DNS records to add. These are the settings you will need to configure within your cPanel account. 

Adding the DNS records to your cPanel

Once you have the DNS settings required for your Office 365 account, you can then use the cPanel Zone Editor to add the necessary DNS entries: 

  1. Log into cPanel.
  2. Go to Zone Editor.
  3. Add an MX record using the settings found in the previous section. 
  4. Add 3 CNAME records:

    CNAME Record 1 (select CNAME from the drop-down menu)

    • Valid Zone Name: autodiscover
    • Fully Qualified Domain Name:
    • TTL: 1 hour or 3600 seconds (this value is entered in the blank space next to the Valid Zone Name)

    CNAME Record 2
    • Valid Zone Name: lyncdiscover
    • Fully Qualified Domain Name:
    • TTL: 1 hour or 3600 seconds

    CNAME Record 3
    • Valid Zone Name: sip
    • Fully Qualified Domain Name:
    • TTL: 1 hour or 3600 seconds
  5. Add TXT record for SPF for spam protection:

    • Host: @
    • TXT Value: v=spf1 -all
    • TTL: 1 hour or 3600 seconds
  6. Add two SRV records with the following values:

    SRV Record 1
    • Target:
    • Protocol: _tls
    • Service: _sip
    • Priority: 100
    • Weight: 1
    • Port: 443
    • TTL: 1 hour or 3600 seconds

    SRV Record 2
    • Target:
    • Protocol: _tcp
    • Service: _sipfederationtls
    • Priority: 100 
    • Weight: 1
    • Port: 5061
    • TTL: 1 hour or 3600 seconds

Once you have added all of the necessary records it may take 4-24 hours for the changes to propagate through the rest of the global internet. After this time you should begin to receive email via your Office 365 account.

Alyssa Kordek Content Writer I

Alyssa started working for InMotion Hosting in 2015 as a member of the Technical Support team. Before being promoted to Technical Writer, Alyssa developed a skillset that includes data migration and system administration. She now works to produce quality technical content such as how-to guides that help users get the most out of their hosting experience.

More Articles by Alyssa

Was this article helpful? Let us know!