Microsoft 365 Service

Last updated

Table of Contents


Microsoft 365 (formerly Office 365) provides email with Outlook, plus Office apps and collaboration tools. The Microsoft 365 one-click service adds four records:

  • A TXT record at the domain apex with your verification value, such as MS=ms12345678
  • An MX record at the domain apex, priority 0, pointing to <your prefix>.mail.protection.outlook.com
  • A CNAME record for autodiscover pointing to autodiscover.outlook.com
  • An SPF record at the domain apex: v=spf1 include:spf.protection.outlook.com -all

Before you start

  • You need a Microsoft 365 subscription with the domain added.
  • Add your users and mailboxes in Microsoft 365 before you change the MX record, so their mail has somewhere to go.

Warning

If the domain uses DNSimple email forwarding, turn it off before you set up Microsoft 365. Email forwarding and email hosting both rely on MX records, so you can use only one of them.

Get the values from Microsoft

In the Microsoft 365 admin center, open your domain’s DNS records, and note the TXT verification value and the MX record’s value. See Microsoft’s guide to connecting your domain by adding DNS records.

The service only works when the MX value ends in .mail.protection.outlook.com. Microsoft also gives MX values that end in mx.microsoft, such as example-com.o-v1.mx.microsoft. If yours ends in mx.microsoft, add the records yourself instead.

Add the Microsoft 365 service

To add the Microsoft 365 service
  1. From the domain list, click the domain name.
  2. Click the tab on the left side.
  3. In the card, click , or if the domain already has a service.

    One-click services card on the DNS page with an arrow pointing to Add

  4. Click the tab, and click next to Microsoft 365.

    Productivity tab with an arrow pointing to Add for Microsoft 365

  5. In , enter the TXT value from Microsoft, such as MS=ms12345678.
  6. In , enter the part of the MX value before .mail.protection.outlook.com. For example-com.mail.protection.outlook.com, enter example-com. DNSimple adds .mail.protection.outlook.com.
  7. Click .

A domain can have only one SPF record. If the domain already had one, the service adds a second, so combine them into one record in the record editor. Also delete any MX records for other mail providers. To remove the service later, see Remove a one-click service.

Add the records yourself

In the record editor, add each record Microsoft shows for your domain:

  • MX: leave blank, enter the MX value from Microsoft, and set the priority to 0.
  • TXT (verification): leave blank and enter the MS= value.
  • CNAME: autodiscover, pointing to the value Microsoft shows.
  • TXT (SPF): leave blank and enter v=spf1 include:spf.protection.outlook.com -all, or add include:spf.protection.outlook.com to your existing SPF record.

Remove MX records for any other mail provider.

Verify your domain with Microsoft

After the records are in place, go back to the Microsoft 365 admin center and continue the domain setup. Microsoft checks the records and tells you when the setup is complete.

Set up email authentication

The service adds the SPF record. For better deliverability, also set up DKIM and DMARC.

DKIM: Microsoft gives two CNAME records, selector1._domainkey and selector2._domainkey, with your domain’s other DNS records. Add both in the record editor. See Set Up DKIM.

DMARC: See Set Up DMARC.

Troubleshooting

Mail is not arriving: Look up the MX record with dig +short example.com MX. The answer should be only the Microsoft MX value. Remove MX records for any other provider, and make sure email forwarding is off. After a change, allow time for DNS caching to clear.

Domain verification fails: Check that the TXT record matches the MS= value Microsoft shows, character for character. New records can take a few hours to be seen everywhere.

Outlook does not set up the account automatically: Check that the autodiscover CNAME record points to autodiscover.outlook.com.

Messages fail SPF or DKIM: Check that there is only one SPF record and that it includes include:spf.protection.outlook.com, and that both DKIM CNAME records are in place. See SPF records, Set Up DKIM, and Set Up DMARC.

Have more questions?

If you have additional questions or need any assistance setting up Microsoft 365 with DNSimple, contact support, and we’ll be happy to help. You can also read more about DNSimple integrations.