Match New Active Directory Users to Microsoft 365 with ImmutableID
Question details
Match users in a new on-premises Active Directory domain to their existing Microsoft 365 accounts.

- Product
- Microsoft 365 and Microsoft Entra Connect Sync
- Device & OS
- not provided
- Scenario
- After an Active Directory domain migration, new user objects have different identifiers and UPNs from those previously synchronized.
- Observed behavior
- The new on-premises users may not match the existing cloud accounts because their source anchors no longer correspond to the cloud ImmutableID values.
Confirm which source-anchor attribute Microsoft Entra Connect Sync uses, such as objectGUID or msDS-ConsistencyGuid, and identify the intended cloud account for each user. Coordinate synchronization scope and timing so the new objects are not provisioned before the matches are prepared.
Hard-match each new Active Directory user to its Microsoft 365 account
Use the new user's configured source anchor to update the existing cloud account, then run synchronization.
The source-anchor value must be converted to a Base64 string that matches the cloud account's onPremisesImmutableId. Do not assume objectGUID is the source anchor: deployments configured to use msDS-ConsistencyGuid may require a different value.
Changing the cloud ImmutableID generally requires the account to be cloud-only. If the account is still managed by directory synchronization, follow Microsoft's supported process for your situation before updating it; do not disable tenant-wide synchronization solely as a routine matching step.
On the Microsoft Entra Connect server, open the Microsoft Entra Connect configuration and check the configured source-anchor attribute. In Active Directory PowerShell, retrieve the new user with Get-ADUser -Identity 'username' -Properties ObjectGUID,msDS-ConsistencyGuid.
For an objectGUID source anchor, run $anchor = [Convert]::ToBase64String($user.ObjectGUID.ToByteArray()) after assigning the Get-ADUser result to $user. If msDS-ConsistencyGuid is the configured anchor and has a populated byte value, use $anchor = [Convert]::ToBase64String($user.'msDS-ConsistencyGuid') instead.
Connect to Microsoft Graph PowerShell with Connect-MgGraph -Scopes 'User.ReadWrite.All', then use Get-MgUser to identify the existing account and check its OnPremisesSyncEnabled and OnPremisesImmutableId properties. Once it is eligible for editing, run Update-MgUser -UserId '<cloud-user-id>' -OnPremisesImmutableId $anchor.
On the Microsoft Entra Connect server, run Start-ADSyncSyncCycle -PolicyType Delta. Check the synchronization results and the user in the Microsoft Entra admin center to confirm the existing cloud account is linked to the intended on-premises user.

Work with migration spreadsheets in WPS Office
WPS Office is a free, lightweight alternative for working with Office documents in a familiar interface. Open existing spreadsheets to review migration inventories and move between compatible formats; WPS does not perform Microsoft Entra directory matching.

Frequently Asked Questions
Why did the users stop matching after the domain migration?
New Active Directory objects can have different source-anchor values from the original objects. Microsoft Entra Connect uses the source anchor to match synchronized users, so a changed value may no longer correspond to the existing cloud ImmutableID.
Should I always convert the new user's ObjectGUID?
No. Check the source-anchor configuration in Microsoft Entra Connect first. If the deployment uses msDS-ConsistencyGuid, the correct anchor may differ from ObjectGUID.
Can I update ImmutableID on a synchronized account?
The value is generally not editable directly while the account is managed by directory synchronization. Check OnPremisesSyncEnabled with Microsoft Graph PowerShell and follow Microsoft's supported process for your account state before making the change.
Can SMTP matching replace a hard match?
SMTP matching has eligibility restrictions and may not reconnect an account that was previously linked through an immutable identity. Check Microsoft's SMTP matching guidance and the account's synchronization history before relying on it.
Will a hard match affect Microsoft 365 services?
A successful match normally reconnects the existing account without changing its identity in Microsoft 365, but outcomes depend on the migration and synchronization configuration. Verify the matched account and its services after the sync.




