How to delete a mailbox in Office 365 without deleting the user? Removing the user…
Find total number of mailboxes in Exchange
How to find total number of mailboxes in Exchange 2013/2016/2019? It is always good to count mailboxes in Exchange. For example, find total number of mailboxes if you are planning a migration or if there is a new Exchange project going on. It’s also possible that the customer or an external team wants to know how many mailboxes are active in the organization. In this article, you will learn how to find the total number in Exchange with PowerShell.
Table of contents
Naming convention
Before we start, let’s understand the naming convention. In Exchange Admin Center (EAC) it will show as:
- Mailboxes
- Resources
- Shared
In PowerShell (Exchange Management Shell) it will show as:
- UserMailbox
- RoomMailbox and EquipmentMailbox
- SharedMailbox
Find total number user mailboxes
Run Exchange Management Shell as administrator. Run the cmdlet to get the total user mailbox count.
[PS] C:\>(Get-Mailbox -RecipientTypeDetails UserMailbox -ResultSize Unlimited).count
33
In the Exchange Admin Center, navigate to recipients and follow with mailboxes in the tab. Down below, under the list view, we can see the total count user mailboxes.
Find total number resources mailboxes
Get total resources mailbox count, run the cmdlet. The resources mailbox is the room and equipment mailbox.
[PS] C:\>(Get-Mailbox -RecipientTypeDetails RoomMailbox, EquipmentMailbox -ResultSize Unlimited).count
3
If you only want to get total count room mailboxes.
[PS] C:\>(Get-Mailbox -RecipientTypeDetails RoomMailbox -ResultSize Unlimited).count
3
List only total count equipment mailboxes.
[PS] C:\>(Get-Mailbox -RecipientTypeDetails EquipmentMailbox -ResultSize Unlimited).count
0
In the Exchange Admin Center, navigate to recipients and follow with resources in the tab. Down below, under the list view, we can see the total count resources mailboxes.
Find total number shared mailboxes
As of last, get total shared mailbox count.
[PS] C:\>(Get-Mailbox -RecipientTypeDetails SharedMailbox -ResultSize Unlimited).count
3
In the Exchange Admin Center, navigate to recipients and follow with shared in the tab. Down below, under the list view, we can see the total count shared mailboxes.
Now that we know how to check the mailboxes count, how do you count mailboxes in Exchange Server? Do you use Exchange Admin Center or Exchange Management Shell?
Keep reading: Count mailboxes per database in Exchange with PowerShell »
Conclusion
You learned how to find total number of mailboxes in Exchange. We can get the total count of mailboxes in Exchange in two ways. One way is with Exchange Admin Center and the other way is with PowerShell. Both will work.
If you liked this article, you may also like to read Check mailbox creation date in Exchange Server. Follow us on Twitter and LinkedIn to stay up to date with the latest articles.
Thank you for the great resource. Managed to get exactly what I was looking for.
I would like to suggest you add the -IgnoreDefaultScope switch to each of your examples which will allow them to show child domain mailboxes. In my environment without the switch I get 391, with the switch I get 776 which is correct.
(Get-Mailbox -RecipientTypeDetails UserMailbox -ResultSize Unlimited -IgnoreDefaultScope).count
That’s correct, and thanks for the suggestion.
Another way that will work is to add Set-ADServerSettings -ViewEntireForest $True before running the commands.