Fix Outlook Connecting to Office 365 After Server Migration
Question details
Outlook keeps trying to connect to outlook.office365.com instead of the new private Exchange server, resulting in a mailbox-not-found error.

- Product
- Microsoft Outlook
- Device & OS
- Windows
- Scenario
- Migrating email accounts from Microsoft 365 to a private Exchange server.
- Observed behavior
- One administrator account continues connecting to Microsoft 365 and receives a mailbox-not-found error, while other user accounts connect to the new server properly.
Ensure you have administrator access to the local Windows machine and the Microsoft 365 admin center, and verify that the email migration for this account is fully completed.
Clear Saved Outlook Credentials and Browser Cache
Removing old authentication tokens from Windows prevents Outlook from automatically routing to the retired Microsoft 365 server.
Outlook often caches old login credentials and connection endpoints. By clearing the Credential Manager, you force Outlook to perform a fresh Autodiscover lookup for your private Exchange server.
Click the Windows Start button, type 'Credential Manager' into the search bar, and press Enter to open the utility.
Click on 'Windows Credentials' and scroll down to the 'Generic Credentials' section. Look for any saved entries containing 'Outlook', 'MicrosoftOffice', or 'Office365'.
Click the dropdown arrow next to the relevant credential and select 'Remove'. Confirm the deletion when prompted.
Open your default web browser, navigate to the settings menu, and clear your browsing history, cookies, and cached site data.
Close and reopen the Microsoft Outlook application. It should now prompt for new credentials and connect to your private Exchange server.
Remove the Custom Domain from the Microsoft 365 Tenant
If Microsoft 365 still hosts your domain, Autodiscover may mistakenly prioritize Office 365 over your private server.
Experience a Lighter, Faster Office Suite with WPS Office
While troubleshooting complex Microsoft Outlook and Exchange server connections can be time-consuming, managing your daily documents doesn't have to be. WPS Office offers a powerful, lightweight alternative to Microsoft Office, giving you all the tools you need without the complicated licensing or server configurations.
- 1. Visit the Website: Navigate to the official WPS Office website on your web browser.
- 2. Download the Installer: Click the 'Free Download' button to download the setup file for your operating system.
- 3. Install and Run: Open the downloaded file and follow the quick installation prompts to start using WPS Office.

Frequently Asked Questions
Why does Outlook ignore my new DNS records and connect to Office 365?
Outlook utilizes an internal Autodiscover process that often prioritizes Microsoft 365 endpoints over standard DNS queries. If your domain is still linked to an active Microsoft 365 tenant, Outlook will automatically route the connection to the cloud.
Will removing my domain from Microsoft 365 delete my old emails?
Removing the domain severs the routing connection but does not immediately delete the data inside the Microsoft 365 mailboxes. However, you should ensure all data is fully backed up and confirmed on your private server before initiating the removal.
Can I force Outlook to bypass Office 365 without removing the domain?
Yes. You can bypass the Office 365 lookup by adding a specific registry key named 'ExcludeExplicitO365Endpoint' in the Windows Registry Editor. Setting this key's value to 1 forces Outlook to skip the Microsoft 365 check and query your local private Exchange server instead.




