Skip to content

Assign Exchange Online Admin Role Permission using PowerShell

Assign Exchange Online Permissions using PowerShell

You can quickly and easily assign roles to user accounts using Office 365 PowerShell by identifying the user account’s Display Name and the role’s Name.

To start, you first need to establish a session to Office 365 PowerShell, this can be done by a script a created which is published on Microsoft TechNet. Download:

Once the connection to Office 365 PowerShell made, you can move along and determine the current Roles assigned to the user which you want to assign additional permissions.

For the purpose of this post, my user is called Farren and I will first verify which Role groups she is current part of.

First, I will start by running the following cmdlet to connect to Office 365

Once connected I will, run the following cmdlet to get my test user Farren.

Now that I can view my test user in my tenant, let’s move on and list the available Admin Roles which can be assigned to the user.

To get the list of Admin Roles, you can run the following cmdlet.

As you can see there is a few different types of Admin Roles which can be assigned, but for the purpose of the post we are only focusing on Exchange Online Roles.

To continue, I will be assigning the following two Admin Roles to my test user.

  • Exchange Service Administrator
  • Mailbox Administrator

These roles can be assigned by running the following cmdlet.

Before I wrap it up let’s verify if the user Farren is now part of the Exchange Service Administrator Role group. This can be done by running the following cmdlet.

And finally, to assign multiple roles to multiple user, the following csv example can be used with the following cmdlets.

The csv should look like the below.

Now that the cv has been created, let’s look at the script which needs to be run.

Script file and CSV file can be downloaded here.

CSV: O365RoleUpdates

Script: O365RoleUpdateScript



Sharing is caring!

Published inExchange Online

Be First to Comment

Leave a Reply

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