Articles

How to find users with overlapping Microsoft 365 licenses

Two licenses on one person can pay twice for the same services. The admin center lists each license on its own and never tells you that one of them is already inside the other.

What counts as an overlap?

A user holds two licenses, and every service plan of the smaller one is also in the larger one. The smaller license then gives the user nothing the larger one does not, and you pay for it anyway.

The clean example is Office 365 E3 assigned beside Microsoft 365 E3. Microsoft 365 E3 includes the service plans of Office 365 E3 (Exchange Online Plan 2, SharePoint, the Microsoft 365 Apps and the rest), so the Office 365 E3 license is a duplicate, provided both are the same Teams edition. This is strict containment, and it is the case you can usually act on.

Not every pair that looks like a duplicate is one. Microsoft 365 Business Premium beside Microsoft 365 E3 is the common trap. They cover much of the same ground, but their service plans differ: Business Premium carries Exchange Online Plan 1 and Microsoft 365 Apps for business, while E3 carries Exchange Online Plan 2 and Microsoft 365 Apps for enterprise, and each has plans the other lacks. That is a near-overlap. One license is probably enough, but you have to look at what the differing plans do before you remove either.

Overlap is one of several kinds of license waste; How to find unused Microsoft 365 licenses covers the others.

How do overlaps happen?

  • A move from Office 365 to Microsoft 365 plans. Users get Microsoft 365 E3 and the old Office 365 E3 stays on them until the subscription runs out, or longer.
  • Group-based licensing on top of direct assignment. A group starts handing out the new suite, and nobody removes the license that was assigned to each user by hand.
  • Trials that were converted. A trial of a larger suite becomes a paid subscription, and the smaller license it replaced is never taken back.
  • Add-ons that an upgrade made redundant. A standalone Microsoft Entra ID P1 or Exchange Online Plan 1 bought years ago stays on a user who now holds a suite that already includes it.

What do you need?

The Microsoft Graph PowerShell SDK v2: Microsoft.Graph.Users for Get-MgUser and Microsoft.Graph.Identity.DirectoryManagement for Get-MgSubscribedSku. Everything here only reads.

Two delegated scopes do it. User.Read.All reads the users with their assigned licenses; User.ReadBasic.All is not enough, because it does not return assignedLicenses. For the subscribed SKUs, Microsoft lists LicenseAssignment.Read.All as the least privileged permission; Organization.Read.All and Directory.Read.All also work if you already consent to one of them.

How do you find them with Graph PowerShell?

The script builds the service plan set of every SKU in the tenant, then compares each pair of licenses on each user who holds two or more. A pair is contained when every plan of the smaller license is in the larger one, and review when the smaller one has at least five plans and shares 80 percent or more of them.

# Written for the Microsoft Graph PowerShell SDK v2. Read-only. Run it first against a test tenant.
Connect-MgGraph -Scopes "User.Read.All","LicenseAssignment.Read.All" -NoWelcome

$ReviewShare = 0.8    # a pair is "review" when the smaller license shares this share of its plans
$MinPlans    = 5      # ...and has at least this many plans
$Exclude     = 'FLOW_FREE','POWER_BI_STANDARD','POWERAPPS_VIRAL'   # free SKUs; add any others your tenant shows

# Each SKU: its part number and the IDs of its user service plans
$sku = @{}
foreach ($s in Get-MgSubscribedSku) {
    if ($s.SkuPartNumber -in $Exclude) { continue }
    $sku[$s.SkuId] = [pscustomobject]@{
        Part  = $s.SkuPartNumber
        Plans = @($s.ServicePlans | Where-Object AppliesTo -eq 'User' | ForEach-Object ServicePlanId)
    }
}

$props = 'id','userPrincipalName','displayName','accountEnabled','assignedLicenses','licenseAssignmentStates'
$users = Get-MgUser -All -Property $props | Where-Object { $_.AssignedLicenses.Count -ge 2 }

$rows = foreach ($u in $users) {
    # The plans each license turns on for this user: the SKU's plans minus the plans disabled on the assignment
    $on = @{}
    foreach ($l in $u.AssignedLicenses) {
        if (-not $sku.ContainsKey($l.SkuId)) { continue }
        $plans = @($sku[$l.SkuId].Plans | Where-Object { $_ -notin $l.DisabledPlans })
        if ($plans.Count) { $on[$l.SkuId] = $plans }
    }
    $viaGroup = @($u.LicenseAssignmentStates | Where-Object AssignedByGroup | ForEach-Object SkuId)
    $ids = @($on.Keys)
    for ($i = 0; $i -lt $ids.Count; $i++) {
        for ($j = $i + 1; $j -lt $ids.Count; $j++) {
            $a = $ids[$i]; $b = $ids[$j]
            if ($on[$a].Count -le $on[$b].Count) { $small = $a; $large = $b } else { $small = $b; $large = $a }
            $shared = @($on[$small] | Where-Object { $_ -in $on[$large] }).Count
            $count  = $on[$small].Count
            $kind = if ($shared -eq $count) { 'contained' }
                    elseif ($count -ge $MinPlans -and $shared -ge $ReviewShare * $count) { 'review' }
            if (-not $kind) { continue }
            [pscustomobject]@{
                User              = $u.UserPrincipalName
                Enabled           = $u.AccountEnabled
                ContainedLicense  = $sku[$small].Part
                ContainingLicense = $sku[$large].Part
                Kind              = $kind
                SharedPlans       = $shared
                ContainedPlans    = $count
                ContainingPlans   = $on[$large].Count
                ContainedViaGroup = $small -in $viaGroup
            }
        }
    }
}

$rows | Sort-Object Kind, User | Format-Table User, ContainedLicense, ContainingLicense, Kind, SharedPlans -AutoSize
$rows | Export-Csv .\license-overlap.csv -NoTypeInformation -Encoding UTF8

Some notes on what it does:

  • Only user plans count. Plans whose AppliesTo is Company are tenant-wide features and say nothing about what one person gets, so they are left out of every set.
  • Disabled plans change the answer. Each assignment carries DisabledPlans, the plans an administrator turned off for that user. The script compares what each license actually turns on. If Exchange is disabled in the user's E3 and an Exchange Online Plan 1 license supplies the mailbox, the Plan 1 license is no longer contained, which is right: it is doing the work. The reverse also holds: a smaller license with most of its plans disabled is easier to contain.
  • Free SKUs are excluded by part number. Subscribed SKUs carry no price, so the script cannot tell free from paid. Add any other free or viral SKU you see in Get-MgSubscribedSku to $Exclude.
  • The 80 percent line is a choice. Business Premium beside Microsoft 365 E3 shares only part of its plans, well under 80 percent, and will not appear. Lower $ReviewShare to 0.5 to see pairs like that, and expect more rows to read.
  • Identical licenses show as contained with the same number in all three plan columns. Keep either; normally the cheaper one goes.

How do you read the result?

Contained rows can usually be removed. First look at ContainedViaGroup. If it is true, the license comes from a group, and removing it from the user directly does not work; take the user out of that group, or change which license the group assigns. If it is false, remove it from the user, in the admin center under Users, Active users, the user's Licenses and apps tab, or with Set-MgUserLicense and the LicenseAssignment.ReadWrite.All scope. Work one SKU at a time, then reduce that subscription's seat count at the next renewal. Billing > Licenses shows how many seats each product has and how many are assigned.

Review rows need a person to look at the plans that differ. Compare the two SKUs' ServicePlans and ask what the extra plans of the smaller license give this user that the larger one does not.

Check before you remove anything. Removing a license can take away a mailbox plan variant or a feature the remaining license lacks: a different Exchange plan means a different mailbox size and archive, and a Teams edition and a no-Teams edition of the same suite are not the same set of plans. On a contained row the test has already shown that no plan switched on today is lost, but a plan disabled on the larger license may be one you meant to turn on later. On a review row something is always lost; decide whether anyone uses it.

An overlap on a disabled account is a different problem: the account probably needs no license at all. How to find disabled users who still hold Microsoft 365 licenses covers that case, which is why the Enabled column is there.

Do add-ons overlap the same way?

Yes, and they are often the easiest wins. A standalone Microsoft Entra ID P1 or P2, Exchange Online Plan 1 or Plan 2, a Microsoft Defender plan or Microsoft Intune is a small SKU of one or a few service plans. When the user's suite includes the same plans, the add-on is contained and the script reports it as such; no separate test is needed.

Two cautions. A suite may include a lower tier than the add-on, such as Entra ID P1 in the suite and P2 bought on its own; those are different plans, so the P2 add-on is correctly not contained. And the test only sees service plan IDs: an add-on whose function is already part of a larger plan but which carries its own plan ID, such as Exchange Online Archiving beside Exchange Online Plan 2, which includes an archive, is not reported. Look for those by part number.

Where does GlacierPoint Ledger fit?

GlacierPoint Ledger runs this comparison as its overlapping-licenses check, one of its eleven checks. It works from the service plans of your own tenant's SKUs, user plans only, minus the plans disabled on each assignment. A license whose enabled plans are all inside another license on the same user is a finding, with the license to drop named. Two base licenses where the smaller has at least five enabled plans and shares more than half of them with the larger are listed for review, with the plans you would lose, and carry no cost. The report shows how many overlapping licenses there are and what they cost a month at list price or your own. How it works shows the check in the report.

Checked against

  • Microsoft.Graph.Users 2.x (Get-MgUser with -All and -Property; AssignedLicenses.SkuId, AssignedLicenses.DisabledPlans, LicenseAssignmentStates.AssignedByGroup, LicenseAssignmentStates.SkuId, AccountEnabled, UserPrincipalName)
  • Microsoft.Graph.Identity.DirectoryManagement 2.x (Get-MgSubscribedSku with SkuId, SkuPartNumber, ServicePlans.ServicePlanId, ServicePlans.AppliesTo)
  • Microsoft.Graph.Authentication 2.x (Connect-MgGraph -Scopes)
  • Permissions as Microsoft Learn states them on 2026-11-11: "List subscribedSkus" (least privileged LicenseAssignment.Read.All; higher Directory.Read.All, Organization.Read.All) and "List users" (User.Read.All for properties beyond the basic set)
  • Microsoft 365 admin center paths, checked by name: Users, Active users, Licenses and apps; Billing > Licenses
  • SKU contents as Microsoft lists them in "Product names and service plan identifiers for licensing"; service plans change over time, so the script reads them from your tenant instead of a list
  • The cmdlets and property names were checked by name against the Microsoft Graph PowerShell SDK v2 reference; the block was not run against a tenant by us: run it against a test tenant first