The memberOf rule cant be configured like that currently:
Creating a Dynamic Group
I am trying to configure a entra group to include members of a specific group but exclude members of another group. I am running into problem creating the dynamic rules in order to pull the correct members. Any help here would be appreciated.
Microsoft Entra ID
2 answers
Sort by: Most helpful
-
Andy David - MVP 157.4K Reputation points MVP Volunteer Moderator
2025-05-15T14:21:12.8966667+00:00 -
Eric Nguyen 1,025 Reputation points Independent Advisor
2025-05-16T04:31:11.9933333+00:00 You can't automatically create a group in Entra that includes members of one group but removes those in another. This type of rule isn’t supported. To work around Entra’s limitations, use user attributes to define dynamic group membership. For example, filter by department or job title to include or exclude users:
(user.department -eq "Sales") -and (user.jobTitle -ne "Contractor")
If no useful attribute exists, manage exclusions manually by creating a separate group for users you want to exclude.
If this helped clarify the limitation and offered a useful workaround, please consider giving it a thumbs up or marking it as helpful—your feedback supports the community and helps others find clear answers faster!