HTML Report of Total Emails Sent and Received Per Mailbox in Exchange

In this blog, I will review a simple PowerShell script, which generates an HTML report for the total emails sent and received per mailbox in Exchange On-Premises.

The report based on a list of mailboxes which should be created first in a simple CSV file, which later on imported by the script.
The time ranges for the total emails sent and received per mailbox at the report can be changed easily, while the default settings are the last 30 days.

The script process:

The first part of the script contains 4 parameters that can be changed inside the script to adjust it to your needs and settings:

The script searches the emails sent and received per mailbox based on the CSV file and using the Get-MessageTrackingLog cmd, it collects the information and rearrange it at the HTML report.

Running the script

The Script & a CSV Example

During the last 13 years, I'm working as a Senior Customer Succes Engineer (former PFE) at Microsoft. My areas of expertise are Exchange, Powershell & Azure.