How to – Connect to Exchange Online to get mailbox details (PowerShell)


Recently we were trying to figure out a few details about the user’s mailbox.

To get the details –

Open Windows PowerShell with the “Run as Administrator” option.

  • Install the Exchange Online Module – Install-Module -Name ExchangeOnlineManagement
  • Import the Exchange Online Module cmdlets – Import-Module ExchangeOnlineManagement
  • Connect to Exchange Online using the administrator account – Connect-ExchangeOnline

  • To get a summary of the all mailboxes in the organization – Get-Mailbox -ResultSize unlimited

  • To get specific mailbox details – Get-Mailbox -Identity “user1@2022rw1.onmicrosoft.com”

  • To get the complete detail of a mailbox – Get-Mailbox -Identity user1@2022RW1.onmicrosoft.com | Format-List

Get all the details here – https://learn.microsoft.com/en-us/powershell/module/exchange/get-mailbox?view=exchange-ps

Hope it helps..

Advertisements
Advertisement
%d bloggers like this: