Simplify user tasks like bulk creation, updates, password resets, deletions, license checks & more — all from one place.
🚀 Launch ToolkitThe Get-MailFlowStatusReport cmdlet in Exchange Online PowerShell is used to retrieve mail flow statistics across your Microsoft 365 organization. It provides a summary view of the status of email delivery over a specified reporting period, showing details like: i)The number of messages sent and received, ii)Delivery status (success, deferred, failed), iii) Trends in mail flow volume, iv)Overall health of your mail transport service.
This cmdlet is especially useful for monitoring organizational email traffic and troubleshooting potential issues with mail delivery.
Notes: There’s no Microsoft Graph PowerShell equivalent for this report as of now. So you should use Exchange Online PowerShell.
Note: It’s a reporting cmdlet available only in Exchange Online (part of the reporting web service) and not in on-premises Exchange.
Get-MailFlowStatusReport [-Direction <Inbound|Outbound|Internal>] [-StartDate <DateTime>] [-EndDate <DateTime>] [-EventType <GoodMail|Spam|Malware|Phish|Bulk|Other>]
What it returns (summary counts may vary by tenant/reporting pipeline):
Common filters:
Get-MailFlowStatusReport
Get-MailFlowStatusReport -Direction Outbound
Get-MailFlowStatusReport -Direction Inbound
Tip: Add a date window to speed queries:
Get-MailFlowStatusReport -Direction Inbound -StartDate (Get-Date).AddDays(-7) -EndDate (Get-Date)
Get-MailFlowStatusReport -StartDate (Get-Date).AddDays(-7) -EndDate (Get-Date) |
Export-Csv .\mailflow-week.csv -NoTypeInformation
| Error | Cause | Solution |
|---|---|---|
| The term 'Get-MailFlowStatusReport' is not recognized | Not connected / old module | Install/Update EXO V3 module; run Connect-ExchangeOnline. |
| Empty/partial results | Window too broad or too old | Use a tighter window; remember the 90-day limit. |
| Access denied | Insufficient RBAC | Use an account with View-Only Organization Management or Organization Management. |
| Slow query | Large unbounded time range | Add -StartDate/-EndDate and, if needed, filter -Direction/-EventType. |
| Unexpected counts | Time zone confusion | Normalize to the same time zone when comparing dashboards/reports. |
Get-MailFlowStatusReport gives you a quick, high-level snapshot of mail health—deliveries, spam/malware blocks, delays, and failures—filtered by direction, event type, and date range (up to 90 days). Use it to confirm the service is healthy, detect spikes early, and guide deeper investigations with message trace when needed. And remember: for this visibility, Exchange Online PowerShell is the place to be—there’s no Graph PowerShell equivalent yet.
© m365corner.com. All Rights Reserved. Design by HTML Codex