Update Office 365 Autodiscover and MX Records for Email Migration
Question details
The user needs to know which DNS records to update when migrating custom domain email to Microsoft 365.

- Product
- Microsoft 365 and Outlook
- Device & OS
- not provided
- Scenario
- A custom domain's email service is being migrated to Microsoft 365.
- Observed behavior
- Incoming email should route to Microsoft 365, and Outlook should discover the domain's Microsoft 365 email settings.
Add and verify your custom domain in the Microsoft 365 admin center, and make sure you can edit DNS records at your domain's DNS provider. Prepare Microsoft 365 mailboxes and plan the email cutover before changing the MX record.
Update the Autodiscover and MX records for Microsoft 365
Use the records supplied in the Microsoft 365 admin center to configure Outlook discovery and route incoming mail to Microsoft 365.
In the Microsoft 365 admin center, go to Settings > Domains, select your verified domain, and open its DNS records or domain setup instructions. Keep the record values shown there available.
Sign in to the provider that hosts your domain's DNS and open its DNS management page. Locate the existing MX and Autodiscover records.
Add or update a CNAME record with host name autodiscover and target autodiscover.outlook.com, as directed by Microsoft 365. Remove or replace any conflicting record for the same host.
When your mailboxes are ready for cutover, replace the existing mail-routing MX record with the exact destination and priority shown for your domain in the Microsoft 365 admin center. Your DNS provider may use @ or a blank host field for the root domain.
Add any other records requested in the domain setup instructions, including the SPF TXT record if applicable. Return to Settings > Domains in the Microsoft 365 admin center and run the DNS check, then send a test message and set up Outlook.

Use WPS Office for documents during your email migration
WPS Office is a free, lightweight, easy-to-use Microsoft Office alternative with a familiar interface. It can help you continue working with documents during a migration, although it does not configure Microsoft 365 email or DNS records.

Frequently Asked Questions
What does the Autodiscover record do?
The Autodiscover CNAME helps Outlook find the settings for a Microsoft 365 mailbox. In your DNS provider's management page, the host is typically autodiscover and the target is autodiscover.outlook.com.
Where can I find the correct MX record for my domain?
In the Microsoft 365 admin center, go to Settings > Domains, select your domain, and review its DNS records or setup instructions. Use the exact MX destination and priority shown for your domain.
When should I change the MX record?
Change it at your planned cutover, after the domain is verified and Microsoft 365 mailboxes are ready. The MX record directs new incoming email, so changing it too early can disrupt delivery.
Can I add a second SPF record for Microsoft 365?
A domain should have only one SPF TXT record. If one already exists, update it to include the authorized services you still use rather than adding a separate SPF record; check the Microsoft 365 domain setup instructions for the required value.
Why does Microsoft 365 still report a DNS error after I update the records?
DNS changes may not have propagated yet, or a record may have an incorrect host or destination. Compare the entries in your DNS provider's management page with Settings > Domains in the Microsoft 365 admin center, then run the DNS check again.




