How to check for (and remove) Global Admins in your O365 subscription

In this post I’m going to describe how you can easily identify your Office 365 administrators and how to remove them.

connect-msolservice
$role = Get-MsolRole -RoleName "Company Administrator"
Get-MsolRoleMember -roleobjectid $role.objectid

You now get a overview of your Global Admin users in your O365 subscription.

It’s easy to revoke the Admin rights from a specific user using the Remove-MsolRoleMember command 

Remove-MsolRoleMember -RoleName "Company Administrator"-RoleMemberType User -RoleMemberEmailAddress "emailaddress@ofuser.com"

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.