Remove Teams licensing for all users in my Tenant

%3CLINGO-SUB%20id%3D%22lingo-sub-33481%22%20slang%3D%22en-US%22%3ERemove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-33481%22%20slang%3D%22en-US%22%3E%3CP%3EIs%20there%20a%20way%20to%20turn%20off%20the%20teams%20licensing%20for%20everyone%20in%20my%20tenant%20so%20we%20can%20do%20a%20slow%20rollout%20and%20turn%20it%20on%20as%20necessary%3F%20Currently%20everyone%20has%20it%20turned%20on%20and%20it's%20becoming%20a%20bit%20of%20a%20management%20headache.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-33481%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EAdministrator%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EBest%20Practices%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EHow-to%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EMicrosoft%20Teams%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESettings%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-37382%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-37382%22%20slang%3D%22en-US%22%3E%3CP%3EOne%20of%20our%20admins%20will%20be%20trying%20the%20steps%20previously%20noted.%20Unfortunatey%20we%20do%20not%20want%20to%20disable%20the%20service%2C%20we%20want%20to%20turn%20off%20the%20licenses%20so%20we%20can%20add%20it%20back%20to%20users%20as%20necessary.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-37328%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-37328%22%20slang%3D%22en-US%22%3EJon%3A%20Perhaps%20you've%20already%20solved%26nbsp%3Bthis%20issue%2C%20but%20you%20can%20just%20disable%20the%20service%20from%20the%20Admin%20portal.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-34034%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-34034%22%20slang%3D%22en-US%22%3EEy%20Vasil...Never%20swear%20when%20you%20talk%20about%20new%20stuff%20appearing%20or%20disappearing%20in%20Office%20365%20%3B)%3C%2Fimg%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-34028%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-34028%22%20slang%3D%22en-US%22%3E%3CP%3EHm%2C%20I%20swear%20it%20wasnt%20there%20yesterday%20%3A)%3C%2Fimg%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAnyway%2C%20you%20can%20do%20it%20like%20this.%20First%2C%20prepare%20the%20customized%20SKU%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%24license%20%3D%20New-MsolLicenseOptions%20-AccountSkuId%20tenant%3AENTERPRISEPACK%20-DisabledPlans%20TEAMS1%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThen%2C%20assign%20it%20to%20the%20user%3A%3C%2FP%3E%3CP%3E%3CBR%20%2F%3ESet-MsolUserLicense%20-UserPrincipalName%20user%40domain.com%20-LicenseOptions%20%24license%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThat's%20assuming%20the%20user%20already%20has%20the%20E3%20SKU%2C%20in%20which%20case%20you%20dont%20need%20to%20provide%20the%20-AddLicenses%20parameter.%20To%20do%20it%20for%20all%20users%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EGet-MsolUser%20-All%20%7C%20%25%20%7BSet-MsolUserLicense%20-UserPrincipalName%26nbsp%3B%24_.UserPrincipalName%20-LicenseOptions%20%24license%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EDo%20test%20with%20fewer%20users%20first%2C%20might%20save%20you%20some%20trouble%20%3A)%3C%2Fimg%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-33926%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-33926%22%20slang%3D%22en-US%22%3E%3CP%3EActually%20it%20is%20listed%20as%20part%20of%20the%20E3%20service%20currently%20(I%20believe%20this%20change%20occured%20last%20week).%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIf%20I%20go%20into%20an%20account%20I%20can%20turn%20it%20on%20or%20off%20per%20user%20but%20I%20would%20like%20to%20be%20able%20to%20flip%20that%20switch%20off%20for%20everyone%20so%20I%20can%20turn%20it%20back%20on%20as%20needed%20per%20user.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-33924%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-33924%22%20slang%3D%22en-US%22%3E%3CP%3EOnce%20we%20have%20the%20Team%20service%20listed%20as%20part%20of%20the%20E1%2FE3%2Fetc%20SKUs%2C%20you%20will%20be%20able%20to%20do%20so.%20Just%20not%20yet%20%3A)%3C%2Fimg%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-33904%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-33904%22%20slang%3D%22en-US%22%3E%3CP%3EThanks%20for%20the%20details.%20I%20am%20wondering%20if%20I%20could%20use%20the%20Bulk%20change%20license%20in%20the%20O365%20Admin%20portal%20to%20do%20some%20of%20this.%20Has%20anyone%20tried%20this%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-33483%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-33483%22%20slang%3D%22en-US%22%3ENo%20currently%20%3A-(.%20Review%20the%20current%20Teams%20FAQs%3A%20%3CA%20href%3D%22https%3A%2F%2Fsupport.office.com%2Fen-us%2Farticle%2FFrequently-asked-questions-about-Microsoft-Teams-%25E2%2580%2593-Admin-Help-05cbe533-2181-4e95-a4b0-52cd7695fafc%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fsupport.office.com%2Fen-us%2Farticle%2FFrequently-asked-questions-about-Microsoft-Teams-%25E2%2580%2593-Admin-Help-05cbe533-2181-4e95-a4b0-52cd7695fafc%3C%2FA%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2185015%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2185015%22%20slang%3D%22en-US%22%3EHere%20is%20the%20script%20if%20somebody%20still%20looking%20for%20solution%3A%3CBR%20%2F%3EFollowing%20script%20is%20for%20Office%20365%20A1%20Plus%20for%20students%3CBR%20%2F%3E%3CBR%20%2F%3E%24acctSKU%3D%22tenant%3ASTANDARDWOFFPACK_STUDENT%22%3CBR%20%2F%3E%24x%20%3D%20New-MsolLicenseOptions%20-AccountSkuId%20%24acctSKU%20-DisabledPlans%20%22TEAMS1%22%3CBR%20%2F%3EGet-MsolUser%20-All%20%7C%20Where-Object%20%7B%24_.licenses%5B0%5D.AccountSku.SkuPartNumber%20-eq%20(%24acctSKU).Substring(%24acctSKU.IndexOf(%22%3A%22)%2B1%2C%20%24acctSKU.Length-%24acctSKU.IndexOf(%22%3A%22)-1)%20-and%20%24_.IsLicensed%20-eq%20%24True%7D%20%7C%20Set-MsolUserLicense%20-LicenseOptions%20%24x%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2191620%22%20slang%3D%22en-US%22%3ERe%3A%20Remove%20Teams%20licensing%20for%20all%20users%20in%20my%20Tenant%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2191620%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F986793%22%20target%3D%22_blank%22%3E%40Harry_Saran%3C%2FA%3E%2C%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20there%20any%20way%20to%20reverse%20your%20script%20to%20enable%20back%20the%20Teams%20service%3F%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
Contributor

Is there a way to turn off the teams licensing for everyone in my tenant so we can do a slow rollout and turn it on as necessary? Currently everyone has it turned on and it's becoming a bit of a management headache.

10 Replies

Thanks for the details. I am wondering if I could use the Bulk change license in the O365 Admin portal to do some of this. Has anyone tried this?

Once we have the Team service listed as part of the E1/E3/etc SKUs, you will be able to do so. Just not yet :)

Actually it is listed as part of the E3 service currently (I believe this change occured last week).

 

If I go into an account I can turn it on or off per user but I would like to be able to flip that switch off for everyone so I can turn it back on as needed per user.

Hm, I swear it wasnt there yesterday :)

 

Anyway, you can do it like this. First, prepare the customized SKU:

 

$license = New-MsolLicenseOptions -AccountSkuId tenant:ENTERPRISEPACK -DisabledPlans TEAMS1

 

Then, assign it to the user:


Set-MsolUserLicense -UserPrincipalName user@domain.com -LicenseOptions $license

 

That's assuming the user already has the E3 SKU, in which case you dont need to provide the -AddLicenses parameter. To do it for all users:

 

Get-MsolUser -All | % {Set-MsolUserLicense -UserPrincipalName $_.UserPrincipalName -LicenseOptions $license

 

Do test with fewer users first, might save you some trouble :)

Ey Vasil...Never swear when you talk about new stuff appearing or disappearing in Office 365 ;)
Jon: Perhaps you've already solved this issue, but you can just disable the service from the Admin portal.

One of our admins will be trying the steps previously noted. Unfortunatey we do not want to disable the service, we want to turn off the licenses so we can add it back to users as necessary.

Here is the script if somebody is still looking for a solution:
Following script is for Office 365 A1 Plus for students

$acctSKU="tenant:STANDARDWOFFPACK_STUDENT"
$x = New-MsolLicenseOptions -AccountSkuId $acctSKU -DisabledPlans "TEAMS1"
Get-MsolUser -All | Where-Object {$_.licenses[0].AccountSku.SkuPartNumber -eq ($acctSKU).Substring($acctSKU.IndexOf(":")+1, $acctSKU.Length-$acctSKU.IndexOf(":")-1) -and $_.IsLicensed -eq $True} | Set-MsolUserLicense -LicenseOptions $x

Hi @Harry_Saran

 

Is there any way to reverse your script to enable back the Teams service?