Skip to content

Entra 150 Groups Per User Limitation

Issue

Azure AD sends up to 150 groups in the groups claim. When using Azure AD with SAML Group Sync, if a user in your organization is a member of more than 150 groups, Azure AD sends a groups claim attribute in the SAML response for group overages, and the user may be automatically removed from groups.

Solutions

  1. Keep users below 150 groups
  2. Use Entra specific integration in your applications like Gitlab’s Microsoft Azure Active Directory integration
    1. I think this fundamentally excludes “SAML” as a solution, you are now seeking “Entra” authentication rather than the universal “SAML” connector
  3. Use filtering on the Enterprise application, this makes the SAML assertion only contain groups that match the filter. If the filter results in a group list less than 150 the assertion will be made as expected with no overage response.
    1. Navigate to Entra > Enterprise applications and open your SAML application
    2. Select “Single sign-on” in the left sidebar
    3. Select “Edit” on “Attributes & Claims”
    4. Under “Additional claims” click on the “user.groups” value to expand the right sidebar
    5. Expand “Advanced options” and tick “Filter groups”
      1. Attribute to match: “SAMAccountName”
      2. Match with: Appropriate selection for your goal
      3. String: plaintext string to match, this field is not regex best I can tell