skip to Main Content

Bulk convert user mailbox to shared mailbox with PowerShell

We have a project going on, and a lot of user mailboxes need to be a shared mailbox. We showed you how to convert user mailbox to shared mailbox with PowerShell in a previous post. In this article, you will learn how to bulk convert user mailbox to shared mailbox with PowerShell. What’s a better way than using PowerShell to get the job done?

Before you start

There are a couple of ways to bulk convert user mailbox to shared mailbox. One way is with a CSV file, and another way is with a text file. First, you are going to learn how to do it with a CSV file. After that, you will learn how to do it with a text file.

Prepare the user mailbox CSV file

Start Microsoft Excel and write in the left top cell (A1) Email. Write below the cell A1 all the user mailboxes that you like to convert to shared mailbox. Write the display name or the email address of the user mailbox. Both will work when converting the user mailbox. In my example, the display name is written.

Do you like to get all the mailboxes in the organization? Read the article Export a list of mailboxes to CSV in Exchange.

Bulk convert user mailbox to shared mailbox with PowerShell Excel

Save it as CSV file in the folder temp on the C: drive with the name bulk.csv.

Bulk convert user mailbox to shared mailbox with PowerShell Excel save as CSV file

Open the CSV file with your favorite text editor. For example, the text editor Notepad and have a look. Everything is looking great.

Bulk convert user mailbox to shared mailbox with PowerShell open CSV file with notepad

After preparing the CSV file, the next step is to read the CSV file content with PowerShell.

Check the content in CSV file

Run Exchange Management Shell as administrator. Run the following cmdlet to verify that the content is readable in PowerShell.

You can check the current mailbox type from the CSV file. In our example, different types of mailboxes are showing.

Filter only on the user mailbox because these are the mailboxes that we want to convert to shared mailbox.

Bulk convert user mailbox to shared mailbox with CSV file

Time to bulk convert the user mailbox to shared mailbox. Run the cmdlet to import the CSV and bulk set mailboxes as shared.

Verify the result

Verify that all the user mailbox is converted to type shared mailbox.

If you like to use a text file instead of a CSV file, read the next part.

Prepare the user mailbox text file

Converting the user mailbox to shared mailbox with a text file instead of a CSV file looks almost the same. The cmdlets are a bit different.

Place the display names or email addresses of the user mailbox in a text file. Save the text file in C:\temp as bulk.txt. This time Email is not showing at the top, that’s because we don’t need it this time.

Bulk convert user mailbox to shared mailbox with PowerShell open text file with notepad

Check the content in text file

Run the Get-Content cmdlet, including Get-Mailbox cmdlet to check the current mailbox type.

Bulk convert user mailbox to shared mailbox with text file

Run the cmdlet to bulk convert user mailbox to shared mailbox. After running the cmdlet and all went great, the output will show you nothing. If it does give you an output with errors, investigate it.

Verify the result

It’s good to have a final check and verify that it’s showing type shared mailbox.

Did you bulk convert user mailbox to shared mailbox with CSV file or text file?

Conclusion

In this article, you learned how to bulk convert user mailbox to shared mailbox with PowerShell. It’s faster to set the mailbox in bulk, instead of running the set mailbox one by one. It’s good to know that you can bulk convert user mailbox to shared mailbox with a CSV file or text file. Both will work great.

I hope you enjoyed this article. You may also like Find total number of mailboxes in Exchange. Don’t forget to follow us and share this article.

ALI TAJRAN

ALI TAJRAN

ALI TAJRAN is a passionate IT Architect, IT Consultant, and Microsoft Certified Trainer. He started Information Technology at a very young age, and his goal is to teach and inspire others. Read more »

This Post Has One Comment

Leave a Reply

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

Back To Top