Safely Remove Azure AD Connect After an Office 365 Migration
Question details
Disable directory synchronization and remove Azure AD Connect while preserving Office 365 users and their access.

- Product
- Microsoft Entra Connect Sync (formerly Azure AD Connect) and Microsoft 365
- Device & OS
- not provided
- Scenario
- An organization has completed an Office 365 migration and wants to stop synchronizing its on-premises directory.
- Observed behavior
- The goal is for synchronized users to become cloud-managed without deleting their Office 365 accounts or unnecessarily resetting passwords.
Confirm that you have an accessible cloud-only administrator account and identify whether users sign in through password hash synchronization, pass-through authentication, or federation. If sign-in depends on on-premises services, plan and test a supported transition to cloud authentication before removing them.
Disable directory synchronization before uninstalling Azure AD Connect
Use this approach when the tenant is ready to manage formerly synchronized accounts in the cloud.
Disabling synchronization converts synchronized users to cloud-managed accounts; uninstalling the server software alone does not turn off synchronization for the tenant. Existing accounts are not normally deleted or passwords automatically reset by this change, but continued sign-in depends on the authentication method and whether usable password hashes are present in the cloud.
In the Microsoft Entra admin center, review the tenant's sign-in method and test cloud access with an appropriate account. If users rely on federation or pass-through authentication, follow Microsoft's documented transition procedure before retiring those services.
Open PowerShell and install the Microsoft Graph PowerShell SDK with Install-Module Microsoft.Graph if needed. Run Connect-MgGraph -Scopes "OnPremDirectorySynchronization.ReadWrite.All" and sign in with an administrator authorized to change directory synchronization settings.
In PowerShell, run $sync = Get-MgDirectoryOnPremiseSynchronization, then run Update-MgDirectoryOnPremiseSynchronization -OnPremisesDirectorySynchronizationId $sync.Id -OnPremisesSyncEnabled:$false.
Allow the tenant change to finish; it can take up to 72 hours. In the Microsoft Entra admin center, check representative users under Identity > Users and confirm they are cloud-managed, then test their Microsoft 365 sign-in.
On the Azure AD Connect server, open Windows Settings > Apps > Installed apps, select Microsoft Entra Connect or Microsoft Azure AD Connect, and choose Uninstall. Keep any other on-premises services needed for authentication or hybrid workloads until their retirement has been planned separately.

Work with Office files in WPS Office after migration
WPS Office is a free, lightweight alternative for working with documents, spreadsheets, and presentations. Its familiar interface and Microsoft Office format compatibility can make file migration easier, although it does not disable Microsoft Entra directory synchronization.

Frequently Asked Questions
Will disabling directory synchronization delete my Office 365 users?
Disabling tenant synchronization normally changes synchronized users to cloud-managed accounts rather than deleting them. Check representative accounts under Identity > Users in the Microsoft Entra admin center after the change completes.
Will users keep their existing passwords?
Disabling synchronization does not automatically reset passwords, but users can only continue signing in with their existing passwords if the cloud has usable password credentials. If sign-in uses federation or pass-through authentication, plan a supported transition to cloud authentication and test it before retiring on-premises services.
Can I just uninstall Azure AD Connect from the server?
No. Uninstalling the software stops that server from syncing but does not disable directory synchronization for the tenant. Turn off tenant synchronization through Microsoft Graph first, wait for it to complete, and then uninstall the software.
Why can't I delete the directory synchronization service account?
The tenant may still consider the account necessary while synchronization is active or the disablement is processing. Verify that synchronization has finished turning off and avoid forcing deletion; contact Microsoft support if removal is still blocked.
How long does it take for users to become cloud-managed?
The tenant-wide change can take up to 72 hours. Afterward, check users in the Microsoft Entra admin center and test sign-in before removing remaining infrastructure.




