Delete Old Exchange Online Mailbox Messages with a Retention Policy
Question details
Remove messages received before a specified date from an Exchange Online mailbox without using Search-Mailbox or an eDiscovery deletion that exceeds its result limit.

- Product
- Exchange Online and Microsoft Purview
- Device & OS
- not provided
- Scenario
- An administrator needs to delete a large volume of older mailbox messages.
- Observed behavior
- Search-Mailbox is unavailable, and the eDiscovery removal approach cannot handle more than 100,000 results.
Confirm that you have permission to manage Purview retention policies and Exchange Online mailboxes, and check for applicable holds and retention requirements. A retention policy uses an item's age rather than a fixed date, so verify that a rolling deletion rule is appropriate for the mailbox.
Apply a Delete-Only Retention Policy to the Mailbox
Use a targeted Microsoft Purview policy to delete mailbox content after it reaches a specified age, then request mailbox processing.
A retention policy is not an exact, one-time filter for messages received before a fixed date. The age threshold continues to advance while the policy is active, and the policy can affect other eligible mailbox content as well as received messages.
Existing holds or other retention policies can affect whether content is preserved or deleted. Review the policy scope and test the settings before applying them to a production mailbox.
In the Microsoft Purview portal, open Data lifecycle management > Microsoft 365 > Retention policies and select New retention policy.
Choose Exchange mailboxes as the location, include the specific mailbox, and exclude locations that should not be affected.
Choose the option to delete items after a retention period and enter an age that corresponds as closely as possible to the desired cutoff. Review the policy settings and submit the policy.
Open PowerShell, install or load the ExchangeOnlineManagement module if needed, and run Connect-ExchangeOnline to sign in with an authorized account.
After the policy is distributed, run Start-ManagedFolderAssistant -Identity <MailboxIdentity>, replacing the placeholder with the mailbox identity. Monitor policy distribution and mailbox processing; deletion is not immediate.

Work with Mailbox Attachments in WPS Office
WPS Office is a free, lightweight Office alternative for editing documents downloaded from mailbox attachments. Its familiar interface and Microsoft Office format compatibility make it easy to move existing files into your workflow. It does not manage Exchange retention policies.

Frequently Asked Questions
Can a retention policy delete only messages received before one fixed date?
Not exactly. A Purview retention policy uses an age threshold, so additional items become eligible as time passes. It can also affect eligible mailbox content other than received messages.
Where do I create a policy for a single Exchange mailbox?
In the Microsoft Purview portal, go to Data lifecycle management > Microsoft 365 > Retention policies. Create a policy, select Exchange mailboxes, and include the mailbox you want to target.
Does Start-ManagedFolderAssistant delete messages immediately?
No. The command requests mailbox processing; policy distribution and processing take time. Connect with Connect-ExchangeOnline, run Start-ManagedFolderAssistant -Identity <MailboxIdentity>, and monitor the policy and mailbox afterward.
Can a hold prevent old messages from being deleted?
A hold or another retention requirement can require content to be preserved even when a deletion policy applies. Review applicable holds and policies in Microsoft Purview before proceeding.




