How to check the retention policy in Microsoft 365 mailboxes
Last updated on:In this page
- Why you need a Microsoft 365 email retention policy
- How to check mailboxes with a retention policy in Exchange Online
- How to view Microsoft 365 mailboxes with a retention policy using Exchange Online PowerShell
- How to view Microsoft 365 mailboxes with retention policies applied with M365 Manager Plus
- Important tips
- Frequently asked questions
Outdated or missing retention policies can quietly turn your Microsoft 365 mailboxes into compliance risks or worse—data loss traps. Whether you’re cleaning up inactive mailboxes, preserving emails for legal hold, or meeting audit requirements, knowing exactly what policy is in place is the first step. This quick guide shows admins how to check which retention policies are applied to your mailboxes using native Microsoft 365 tools such as the Exchange Admin Center and Exchange Online PowerShell.
- Exchange Online
- Graph PowerShell
- M365 Manager Plus
Why you need a Microsoft 365 email retention policy
Retention policies define how mailbox data is handled throughout its life cycle—whether it stays in the primary mailbox, moves to an archive, or is deleted after a set period. They help organizations preserve important information, meet compliance requirements, and manage their mailbox storage effectively.
When configured correctly, retention policies can:
- Preserve critical emails by keeping them in place or moving them to an archive mailbox before deletion dates are reached.
- Prevent premature deletion by placing items on hold until legal or regulatory timelines are met.
- Support audits and investigations by ensuring that relevant emails remain accessible and searchable for the required duration.
- Reduce clutter and costs by automatically removing data that is no longer needed after compliance periods end.
How to check mailboxes with a retention policy in Exchange Online
Prerequisite:
- You need the Reports Reader role on the account you use to sign in to the Exchange Admin Center.
- Log in to the Exchange Admin Center and navigate to Recipients > Mailboxes.
- Click the mailbox for which you want to check the retention policy.
- In the menu that pops up, click Mailbox and view the Retention policy section.
Note: You will have to repeat this set of steps for every mailbox you wish to check the retention policy for. If you wish to generate a complete list of Microsoft 365 mailboxes with retention policies applied, you will have to resort to complex PowerShell scripting or you can try out the user-friendly, one-click interface of M365 Manager Plus.
How to view Microsoft 365 mailboxes with a retention policy using Exchange Online PowerShell
Prerequisites
Before using Exchange Online PowerShell, please verify that:
- The ExchangeOnlineManagement PowerShell module is installed. If not, install it using this script:
Install-Module ExchangeOnlineManagement -Scope CurrentUser Update-Module ExchangeOnlineManagement
- Connect to the Exchange Online module using this script:
Connect-ExchangeOnline
Using Get-Mailbox to check retention policies in Microsoft 365 mailboxes
The Get-Mailbox cmdlet can be used in Exchange Online PowerShell to get a list of all mailboxes with a retention policy in Exchange Online. The syntax for it is given below:
Get-Mailbox -ResultSize Unlimited | Select-Object DisplayName, RetentionPolicy, RetainDeletedItemsFor, RetainDeletedItemsUntilBackup, UseDatabaseRetentionDefaults
Supported parameters
The following table contains some parameters that can be used along with the cmdlet Get-Mailbox to check retention policies on Microsoft 365 mailboxes efficiently.
| Parameter | Description |
|---|---|
| DisplayName | The reader-friendly name of the mailbox in the admin center and address book. |
| RetentionPolicy | The retention policy currently assigned to the mailbox. |
| RetainDeletedItemsFor | The number of days items remain in the Deleted Items folder or Recoverable Items folder before permanent deletion, if no hold is applied. |
| RetainDeletedItemsUntilBackup | If the value of this parameter is True, deleted items are retained until the database is backed up, ignoring the retention period specified by RetainDeletedItemsFor. |
| UseDatabaseRetentionDefaults | If the value of the parameter is True, the mailbox ignores its own RetainDeletedItemsFor setting and instead follows the database’s retention behavior, holding items until a backup occurs. |
Checking the retention policy in Microsoft 365 mailboxes with the Get-Mailbox cmdlet
Scenario
Your organization is preparing for an upcoming compliance audit or possible legal review.
The legal team needs to know:
- Which retention policies are currently applied to user mailboxes.
- How long deleted items are recoverable.
- Whether those settings match the company’s compliance requirements (e.g., 30-day recovery).
This is the cmdlet you will have to run to get a list of all Exchange Online mailboxes with retention policies applied.
Connect-ExchangeOnline
Get-Mailbox -ResultSize Unlimited | Select-Object DisplayName, RetentionPolicy, RetainDeletedItemsFor, RetainDeletedItemsUntilBackup, UseDatabaseRetentionDefaults | Export-Csv ".\MailboxRetentionAudit.csv" -NoTypeInformation
How to view Microsoft 365 mailboxes with retention policies applied with M365 Manager Plus
- Log in to M365 Manager Plus and navigate to Reports > Security Reports and select Mailbox Retention Policy.
- Select your desired Microsoft 365 Tenant and click Generate Now to view the list of retention policies applied to mailboxes.
Plan and track your Exchange Online retention policies with M365 Manager Plus
M365 Manager Plus’ retention policy capabilities help you view, manage, and audit retention settings for all mailboxes in your Microsoft 365 environment. It streamlines policy assignment, offers in-depth reporting, and provides real-time monitoring—all through an intuitive web console without the need for complex Microsoft Graph or PowerShell scripting.
Retention policy reporting
Generate detailed reports on the retention policies assigned to mailboxes, including policy names, retention duration, and deleted item recovery settings, to ensure compliance across your organization.
Bulk policy assignment
Assign or update retention policies for multiple mailboxes in one action using CSV imports or intuitive GUI options, eliminating the need for repetitive, one-by-one updates.
Archive and hold visibility
View archive mailbox statuses, litigation holds, and hold duration alongside retention policy data, giving you a complete picture of your mailbox retention posture.
Real-time alerts on retention changes
Set up instant alerts for changes to retention policies, archive status, or deleted item retention settings so you can act quickly to prevent accidental or unauthorized modifications.
Eliminate complex PowerShell scripting
Run reports in one click instead of dozens of manual checks per mailbox. Perform all retention-related tasks through a user-friendly web interface, reducing dependency on scripting and minimizing configuration errors.
Important tips
Ensure users are assigned the correct Microsoft 365 license that includes retention features (e.g., Microsoft 365 E3/E5, Office 365 E3/E5, or the Information Protection & Governance add-on) before applying retention settings.
Run regular scheduled reports to confirm all mailboxes have the correct retention policy, archive status, and hold settings in place.
For mailboxes that require extended storage, activate the archive mailbox and configure auto-expanding archiving if your license supports it. This ensures retention policies can offload items to the archive without hitting storage limits.
Frequently asked questions
To list retention policies for all mailboxes in Exchange Online, run:
- Get-Mailbox -ResultSize Unlimited | Select-Object DisplayName, RetentionPolicy
Best practices for creating and managing retention policies include:
- Testing changes in a pilot group before rolling them out to all users.
- Reviewing policy assignments quarterly to catch gaps.
- Using archive mailboxes for older content instead of extending primary mailbox limits.
- Combining Exchange Online retention policies with Microsoft Purview Data Lifecycle Management policies for unified governance.
When a mailbox is on litigation hold or an eDiscovery hold, retention policies won’t permanently delete items covered by the hold, even if the policy’s deletion period expires. This ensures data preservation for legal or compliance reasons.
Check your organization’s default Exchange Online retention policy settings in the Exchange Admin Center under Retention Policies. If a default is set, new mailboxes will inherit it automatically—otherwise, you’ll need to assign one manually.
By default, deleted items are kept in the Deleted Items folder until the user empties it. Once emptied, they move to the Recoverable Items folder, where they are retained for 14 days.
Admins can increase this period up to 30 days using the RetainDeletedItemsFor property in Exchange Online PowerShell:
Set-Mailbox -Identity <User> -RetainDeletedItemsFor 30
