PowerShell: Disable MFA For All O365 Users

KB ID 0001655

Problem

If you have something boring/repetitive to do then Powershell is your friend! I needed to do this for a client that’s replacing their Office365/Azure AD MFA (Multi Factor Authentication) with Duo.

Solution

Connect to your Microsoft Services Online, i.e. Office365/Azure, using your administrative credentials with the following command;

Connect-MsolService

Then (Note: I’ve got more than 1000 users so I need to add the MaxResults switch).

Get-MsolUser -MaxResults 2000 | Set-MsolUser -StrongAuthenticationRequirements @()

Disable MFA for ALL users Office365

Office 365: Disable MFA For One User

Similar to above;

Get-MsolUser -UserPrincipleName {user-name} | Set-MsolUser -StrongAuthenticationRequirements @()

Related Articles, References, Credits, or External Links

NA

Author: PeteLong

Share This Post On

Submit a Comment

Your email address will not be published. Required fields are marked *