skip to Main Content

Remove Exchange Hybrid Configuration

When all the mailboxes are in Exchange Online, and all the SMTP relay goes directly from the devices and applications to Office 365, we can remove the Exchange Hybrid Configuration. After that, keep only one Exchange Server for management purposes. In this article, you will learn how to delete Exchange Hybrid Configuration step by step.

Point MX records to Office 365

The MX record needs to point to Office 365, which is domain-com.mail.protection.outlook.com. Go through the article: Update MX records to Office 365.

Point Autodiscover record to Office 365

The Autodiscover record needs to point to Office 365, which is autodiscover.outlook.com. Go through the article: Autodiscover URL in Exchange Hybrid.

Remove Service Connection Point (SCP)

Remove the Service Connection Point (SCP) value on the Exchange Servers. This ensures that it will not return an SCP. Go through the article: Autodiscover URL in Exchange Hybrid.

Remove Hybrid Configuration

Remove the Hybrid Configuration object from Active Directory to prevent the Hybrid Configuration from being recreated in the future.

Run Exchange Management Shell as administrator. Next, run the Remove-HybridConfiguration cmdlet.

[PS] C:\>Remove-HybridConfiguration -Confirm:$false

Verify that the Hybrid Configuration is successfully removed. Run the Get-HybridConfiguration cmdlet, and the output will be empty.

[PS] C:\>Get-HybridConfiguration

Keep one Exchange Server

You should keep one Exchange Server on-premises for management purposes. Remove all other Exchange Servers to free up resources for other machines. Think about disk space, memory, and CPU. You don’t need to add a lot of disk space, memory, and CPU on the last Exchange Server. That’s because it will only be there for management purposes. There is no need to have a Database Availability Group or other high availability options.

Note: Keep the Exchange Server with management purposes up to date with the latest Exchange Cumulative Update and Exchange Security Update.

Disable OAuth configuration

You have to disable OAuth from both on-premises and Microsoft 365.

Run Exchange Management Shell as administrator and run the below command to disable OAuth configuration from on-premises.

[PS] C:\>Get-IntraOrganizationConnector | Set-IntraOrganizationConnector -Enabled $false

Verify that OAuth is disabled from on-premises with the Get-IntraOrganizationConnector cmdlet. The Enabled column will show as False.

[PS] C:\>Get-IntraOrganizationConnector | Format-Table Name,Enabled,TargetAddressDomains

Name                                             Enabled TargetAddressDomains
----                                             ------- --------------------
HybridIOC - 5635832e-d272-46fa-8161-7bfcdfc9aaa2   False {exoip365.mail.onmicrosoft.com}

Run Windows PowerShell as administrator and connect to Exchange Online PowerShell.

PS C:\> Connect-ExchangeOnline

Run the below command to disable OAuth configuration from Microsoft 365.

PS C:\> Get-IntraOrganizationConnector | Set-IntraOrganizationConnector -Enabled $false

Verify that OAuth is disabled from Microsoft 365 with the Get-IntraOrganizationConnector cmdlet. The Enabled column will show as False.

PS C:\> Get-IntraOrganizationConnector | Format-Table Name,Enabled,TargetAddressDomains

Name                                             Enabled TargetAddressDomains
----                                             ------- --------------------
HybridIOC - 25ed1cea-670f-45c3-854e-e3a1d0a4651c   False {exoip.com}

Remove connectors in Exchange Online

The Hybrid Configuration Wizard created inbound and outbound connectors in Exchange Online. Follow the below steps to delete the connectors in Exchange Online:

  • Sign in to Microsoft 365 Exchange admin center
  • Expand Mail flow and click on Connectors
  • Delete the connectors named Inbound from <unique identifier> and Outbound to <unique identifier>
Remove Exchange Hybrid Configuration remove connectors

Remove organization relationship in Exchange Online

The Hybrid Configuration Wizard created an organization relationship. Follow the below steps to delete the organization relationship in Exchange Online:

Remove Exchange Hybrid Configuration remove organization relationship

Remove send connector in Exchange on-premises

The Hybrid Configuration Wizard created an outbound connector in Exchange on-premises. Follow the below steps to delete the send connector in Exchange on-premises:

  • Sign in to Exchange admin center
  • Expand mail flow and click on send connectors
  • Delete the outbound connector named Outbound to Office 365 – <unique identifier>
Remove Exchange Hybrid Configuration remove send connector

You can remove all the Exchange on-premises send connectors. That’s because the Exchange Server will not send emails anymore. Instead, the SMTP relay goes through Office 365 directly from the devices and applications.

Keep Exchange Hybrid deployment

Leave the Exchange Hybrid Deployment feature enabled in Azure AD Connect.

Remove Exchange Hybrid Configuration Exchange Hybrid Deployment

You successfully did remove Exchange Hybrid Configuration.

Read more: Install Exchange Security Update step by step »

Conclusion

You learned how to remove Exchange Hybrid Configuration step by step. When all mailboxes are in Office 365 and the SMTP relay goes through Office 365, it’s an excellent time to delete the Hybrid Configuration. Every step is essential, and you have to go through them all and ensure that the Hybrid Configuration is successfully removed. Don’t forget to keep one last Exchange Server for management purposes.

Did you enjoy this article? You may also like the course Exchange Hybrid. Don’t forget to follow us and share this article.

ALI TAJRAN

ALI TAJRAN

ALI TAJRAN is a passionate IT Architect, IT Consultant, and Microsoft Certified Trainer. He started Information Technology at a very young age, and his goal is to teach and inspire others. Read more »

This Post Has 8 Comments

  1. Hi Ali,
    Thank you for this write-up, great knowledge share. Much appreciate you taking the time to write this up.

  2. Dear,
    The hybrid setup is configured in my environment with a stand-alone ex2019 server now I decided to remove the hybrid setup and keep only the on-premise setup. Please suggest if the above method is suitable for this purpose or if any additional configuration is required.

  3. Ali,

    Excellent article my friend. Thanks for taking the time to share your wonderful knowledge. I would like to get your feedback if you don’t mind.

    In my organization, there is a division of it that was acquired by another company and one of the requirements was to migrate the email of that division to O365. In order to do that we set up Hybrid on our Exchange 2016 to easily migrate the mailboxes of the employees going away with this other company to O365. That part went well but now we have to remove the hybrid configuration.

    On the other hand, we are also planning to migrate to O365 the other part of our company…of course this will be to another/different O365 Tenant.

    The point now is that we are trying to figure out a way to break/remove the current hybrid configuration we had to do recently for the division acquired by this other company I mentioned above but being careful of breaking/removing the current hybrid configuration so that we can then setup again Hybrid to be able to migrate to O365 the remaining mailboxes that in this case belong to employees of the part of the company that stays on this end.

    Any particular recommendations? We do not want to brake/remove anything that we might need for our next hybrid configuration.

    Please advise when you have a moment. Thanks in advance for your feedback!

    Ray

    1. Glad to hear that, Ray.

      I had done this before and migrated mailboxes from Exchange on-premises to different Microsoft 365 tenants.

      You can follow the steps in the article to remove the Hybrid Configuration and the configurations that HCW configures in Exchange Online and Exchange on-premises.

      The next time you want to migrate the mailboxes to another Microsoft 365 tenant, run the Hybrid Configuration Wizard. It will create all the configurations in Exchange Online and Exchange on-premises.

Leave a Reply

Your email address will not be published.