To create mailboxes in Microsoft 365 (Office 365), you can use the admin center or PowerShell. Both methods support individual and bulk creation methods. View step-by-step instructions for creating user mailboxes or shared mailboxes in your Microsoft 365 tenant.
Required Permissions
The permissions required to create mailboxes are Email Recipients and Email Recipient Creation. The two default groups with the required permissions are organizational management and recipient management.
Are you migrating to Microsoft 365?
The most common scenario when you need to create mailboxes in Microsoft 365 is to rebuild your on-premises Exchange environment. In this article, I only show how to create mailboxes. Note, however, that when you migrate, you must also move their content. Click on the links below to learn how to complete the migration process for different scenarios:
And if you want to make the process a lot easier, there’s a migration tool that will do the job. It allows you:
- create and assign licenses automatically,
- plan your migration and get automatic reports and notifications,
- easy migration of user mailboxes and public folders from any Exchange Server (2003+) and SBS,
- Make sure nothing is lost in the process with the post-migration rescan feature
- and more…
Create a user mailbox in the Microsoft 365 admin center
Currently the only place in the admin portal where you can create user mailboxes is the Active Users Tab in the Microsoft 365 admin center. Shared mailboxes can be created Teams & Groups > Shared mailboxes or in the Exchange admin center from recipient > mailboxes.
To create a new user with a mailbox, click Add a user in which Settings page for active users:
Next, enter basic information about the user. The only required fields are display name, username (UPN) and password. While you can skip all other fields, it’s usually best to fill out as much as possible now. It reduces the risk of having an incomplete AAD later.
In the next step, select the user’s location and allocate product licenses from the available pool. If you want the user to have an active mailbox, you must assign a plan that includes the Exchange Online service. Otherwise, create the user without a mailbox.
The last step is to fill out a more detailed profile description. Again, you can save it for later, but it’s not recommended.
After that, the mailbox will be created.
To create multiple users, you can use the Add multiple users button on the Settings page for active users.
Here you can download sample CSV files with the required headers. However, in most cases you already have your user information stored somewhere, so you can either copy the user information into the file with the correct headers, or use PowerShell to create a CSV file with the correct headers and your users’ data already filled in. Learn how to export users from Active Directory
Once you have the CSV file, use the search button to find it and start the mailbox creation process.
Next you can assign licenses, just like creating a single mailbox:
Create a shared mailbox in the Microsoft 365 admin center
To create a shared mailbox, go to Microsoft 365 admin center > Teams & groups > Shared mailboxes, or use this shortcut. Then click Add a shared mailbox.
On the right you should see a new area with 3 fields to fill in with relevant information.
After the mailbox is created, you can select it from the list and click To editand add members:
Create user mailboxes with PowerShell
Before you do anything with PowerShell in your Microsoft 365 tenant, you need to connect to Exchange Online. Learn how to connect to Exchange Online with PowerShell
Use of New mailbox Exchange Online module cmdlet allows you to create users and mailboxes in Microsoft 365 at the same time.
While you could just use the -MicrosoftOnlineServicesID and -Password parameters to successfully create a new user mailbox, it’s better to add parameters like -MailboxPlan (so you don’t have to use Set-MailboxPlan afterwards):
New-Mailbox -Name MeganB -FirstName Megan -LastName Bowen -DisplayName "Megan Bowen" -MicrosoftOnlineServicesID MeganB -Password (ConvertTo-SecureString -String 'YourPassword' -AsPlainText -Force) -ResetPasswordOnNextLogon $true -MailboxPlan 'MailboxPlan'
Remember that the password must meet the password complexity requirements, otherwise the mailbox creation will fail. Learn how to check and configure password complexity (Microsoft’s site)
To create multiple mailboxes, you first need a CSV file with the mailbox list. You can then import the content into an array and use the foreach loop to create multiple mailboxes. You can of course use a different file location and the specific variable values depend on your CSV headers. The script looks like this:
$mbxs = Import-Csv 'C:\users.csv' Foreach ($mbx in $mbxs) { New-Mailbox -Name $mbx.DisplayName -DisplayName $mbx.DisplayName -MicrosoftOnlineServicesID $mbx.UserPrincipalName} -Password (ConvertTo-SecureString -String 'YourPassword' -AsPlainText -Force) -ResetPasswordOnNextLogon $true -MailboxPlan 'MailboxPlan'}
Finally you can use Set-MsolUser to fill out the rest of your users’ profile details.
Create a shared mailbox using PowerShell
Creating a shared mailbox with PowerShell requires fewer parameters because it works differently. In most cases, shared mailboxes do not require licenses and do not have passwords. On the other hand, you must take care of setting permissions on these mailboxes so that licensed users of your choice can access them.
New-Mailbox -Shared -Name 'Marketing' -DisplayName 'Marketing' -Alias 'Marketing' Set-Mailbox Marketing -GrantSendOnBehalfTo 'Sales and Marketing' Add-MailboxPermission -Identity Sales -User 'Sales and Marketing' -AccessRights FullAccess -InheritanceType All This sample code creates a new Shared Mailbox named Marketing and grants Full Access and Send on Behalf permissions for the Sales and Marketing security group members.
Continue reading: