Retrieving Email Data from Mailbox for the Past 6 Years

Mohana Reddy 165 Reputation points
2025-01-19T06:19:26.46+00:00

Is it possible to retrieve all emails sent from a mailbox over the past 6 years in CSV or Excel format from the admin center? Are there any PowerShell commands available to check and extract this data?

Exchange Online
Exchange Online
A cloud-based service included in Microsoft 365, delivering scalable messaging and collaboration features with simplified management and automatic updates.
Outlook | Windows | Classic Outlook for Windows | For business
Exchange | Exchange Server | Management
Exchange | Exchange Server | Management
The administration and maintenance of Microsoft Exchange Server to ensure secure, reliable, and efficient email and collaboration services across an organization.
Exchange | Other
Exchange | Other
A powerful email and collaboration platform developed by Microsoft, designed to support enterprise-level communication and productivity. Miscellaneous topics that do not fit into specific categories.
{count} votes

3 answers

Sort by: Most helpful
  1. Amit Singh 5,306 Reputation points
    2025-01-19T13:22:11.6733333+00:00

    You can use PowerShell to get all emails sent from a mailbox over the past 6 years in CSV or Excel format. It require some admin-level access.

    Search-Mailbox -Identity "UserMailbox" -SearchQuery "sent:01/01/2018..01/01/2024" -TargetMailbox "AdminMailbox" -TargetFolder "SentItemsSearch" -LogLevel Full
    

     After running the above command, you can then export the results from SentItemsSearch folder into a CSV file using another command or manually download them.

    Through EAC Message trace is limited to 90 days. For older data (up to 90 days), you might need to run multiple traces or use the Security & Compliance Center.

    Let me know if you have any query.

    0 comments No comments

  2. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.


    Comments have been turned off. Learn more

  3. Anonymous
    2025-01-20T09:40:20.9133333+00:00

    Hi,@Mohana Reddy

    Thanks for posting your question in the Microsoft Q&A forum.

    You can search for content in Microsoft Purview's eDiscovery.

    User's image

    User's image

    Finally, just export the results.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.