Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
M

mail-archiver

> DevOps
Open source

Mail-Archiver is a web application for archiving, searching, and exporting emails from multiple accounts. Featuring folder sync, attachment support, mailbox mig

2.0K stars0 likes2 views
WebsiteGitHub

About

Mail-Archiver is a web application for archiving, searching, and exporting emails from multiple accounts. Featuring folder sync, attachment support, mailbox mig

Mail-Archiver - Email Archiving System

A comprehensive solution for archiving, searching, and exporting emails

Website: mail-archiver.org Roadmap: Project Portal

✨ Key Features

Core Features

  • Automated archiving from multiple accounts with scheduled sync
  • Multilingual responsive UI with dark mode
  • OpenID Connect (OIDC) authentication (OIDC Guide)

Search & Access

  • Advanced search with filters
  • Email preview with attachments
  • Export accounts or selected emails as mbox / zipped EML

Programmatic & AI Agent Access

  • Read-only REST API (v1) for programmatic access to the archive via scoped per-user API keys — lets scripts read archived mail without ever exposing mailbox credentials (REST API Guide)
  • MCP Server (Model Context Protocol) — optional Streamable HTTP endpoint at /mcp that exposes the same read-only archive to AI agents as discoverable tools (search_emails, get_email, list_accounts, list_folders, get_attachment) (MCP Guide)

User Management

  • Multi-user support with account-specific permissions
  • Dashboard with statistics and storage monitoring
  • Detailed access logging (Access Logging Guide)

Email Provider Support

  • IMAP: Traditional IMAP accounts with full synchronization capabilities
  • M365: Microsoft 365 mail accounts via Microsoft Graph API (Setup Guide)
  • Microsoft Personal: Personal Microsoft accounts (Outlook.com, Hotmail, live.com, M365 Family) via OAuth2 Device Code Flow — ships with a pre-registered shared Client ID so no Azure App Registration is required (Setup Guide)
  • IMPORT: Import-only accounts for migrating existing email archives

M365 Tenant Import

  • Bulk-import all Microsoft 365 mailboxes of a tenant from one form
  • Import all mailboxes or select specific ones; skips existing and disabled accounts
  • See the M365 Tenant Import Guide for details

Import & Restore Functions

  • MBox and EML (ZIP) import with folder structure support
  • Restore emails or entire mailboxes
  • ** Mailbox Migrations**: Copy emails between mailboxes while preserving folder structure (Migration Guide)

️ Retention Policies

  • Automatic deletion from mailserver after a configurable period (Retention Policies)
  • Per-account retention (e.g., 30, 90, or 365 days)
  • Separate retention for the local archive

Deletion Lock (Compliance)

  • Disable manual deletion of archived emails via DeletionPolicy__DeletionAllowed=false
  • Local retention deletion remains exempt and still runs
  • See Setup Guide for details

Access Log

  • The application logs various types of user activities such as Login, Opening, Searches, Exports and many more. (Logging)

For detailed documentation on installation, configuration, and usage, please refer to the Documentation Index. Please note that the documentation is still fresh and is continuously being expanded.

Quick Start

Prerequisites

  • Docker
  • Docker Compose

️ Installation

  1. Install the prerequisites on your system

  2. Create a docker-compose.yml file

…
  1. Edit the database configuration in the docker-compose.yml and set a secure password in the POSTGRES_PASSWORD variable and the ConnectionString.

  2. Definie a Authentication__Username and Authentication__Password which is used for the admin user.

  3. Adjust the TimeZone__DisplayTimeZoneId environment variable to match your preferred timezone (default is "Etc/UCT"). You can use any IANA timezone identifier (e.g., "Europe/Berlin", "Asia/Tokyo").

  4. Configure a reverse proxy of your choice with https to secure access to the application.

⚠️ Attention The application itself does not provide encrypted access via https! It must be set up via a reverse proxy!

  1. Initial start of the containers:
bash
docker compose up -d
  1. Restart containers:
bash
docker compose restart
  1. Access the application in your prefered browser.

  2. Login with your defined credentials and add your first email account:

  • Navigate to "Email Accounts" section
  • Click "New Account"
  • Enter your server details and credentials
  • Save and start archiving!
  • If you want, create other users and assign accounts.

Security Notes

  • Use strong passwords and change default credentials
  • Set up HTTPS via a reverse proxy in production (the app itself does not provide HTTPS)
  • Regular backups of the PostgreSQL database recommended (see Backup & Restore Guide)

For all configuration options, see the Setup Guide.

Contributing

We welcome contributions from the community! Please read our Contributing Guide for detailed information about how to contribute to Mail Archiver.

For code changes by third parties, please coordinate with us via email at [email protected] before making any changes.

You can also:

  • Open an Issue for bug reports or feature requests
  • Submit a Pull Request for improvements
  • Help improve documentation

Support the Project

If you find this project useful and would like to support its continued development, you can buy me a coffee! Your support helps me dedicate more time and resources to improving the application and adding new features. While financial support is not required, it is greatly appreciated and helps ensure the project's ongoing maintenance and enhancement.

Project Sponsors

With the generous support of our sponsors, Mail Archiver continues to evolve. Thank you for making it possible!

Disclaimer: The services listed above are third-party offerings and are neither affiliated with, endorsed by, nor tested by the Mail Archiver project.

Individual Sponsors

A special thanks to all individual sponsors who support this project through GitHub Sponsors, Ko-fi, and Buy Me a Coffee. Your contributions make a real difference!


License: GNU GENERAL PUBLIC LICENSE Version 3 (see LICENSE file)

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

C#archivearchiverbackupdocker-compose

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
CategoryDevOps
PricingOpen source

> Related tools

D
Docker
容器化平台,标准化应用交付
G
GitHub Actions
GitHub 原生 CI/CD 工作流
N
Nginx
高性能 Web 服务器与反向代理