Sunday, October 25, 2026 4,350 lists 78,100 records on file
List your app or device

  1. Home
  2. Email Cleanup Software
  3. mailtrim

mailtrim

What it is

mailtrim is a free Linux command-line tool for locating and removing inbox clutter. It ranks senders by storage impact, then supports bulk deletion from selected senders or an entire domain; one command can remove 300 or more messages from one sender. A dry-run preview shows the proposed purge before confirmation. Deleted mail goes to Trash and can be restored for up to 30 days. The tool works with Gmail and IMAP services, including Outlook, Fastmail, iCloud, and self-hosted IMAP servers. Gmail setup uses OAuth, while IMAP setup accepts server credentials without keeping the password in local storage. Optional AI features provide inbox triage, natural-language bulk operations, and weekly digests, and are disabled by default. When Anthropic handles those features, subjects, sender names or addresses, and snippets are sent, but not full bodies or attachments. The privacy policy says metadata, tokens, undo logs, rules, and unsubscribe history stay locally, with no analytics, crash reporting, or usage tracking. mailtrim is MIT-licensed and free to use, modify, and distribute.

For and against

For

  • Ranks senders by storage impact
  • Dry-run previews deletions before confirmation
  • Trash restoration lasts up to 30 days
  • Supports Gmail and multiple IMAP services
  • No analytics, crash reporting, or usage tracking

Against

  • Linux command-line tool only
  • AI sends subjects, sender details, and snippets
  • Multi-user or server deployment is out of scope

The verdict

mailtrim offers targeted, previewable cleanup with a recovery window and local-data controls. Its command-line format, Linux platform, and optional cloud-AI disclosure are important fit considerations.

Who it suits

It suits Linux users who prefer a command-line cleanup workflow for Gmail or IMAP accounts. Readers considering AI features should note the stated Anthropic data sharing.

Plans and prices

Free

Free

No subscription · no API key required for core commands

Every plan, in full

On the record

AI data
When cloud AI is used, email subjects, sender details, and snippets are sent to Anthropic; full message bodies and attachments are not sent.github.com · read 8 Oct 2026
AI features
Optional AI features include inbox triage, natural-language bulk operations, and weekly digests; AI is off by default.github.com · read 8 Oct 2026
Authentication
Gmail setup uses OAuth, while IMAP setup accepts server credentials and keeps the password out of local storage.github.com · read 8 Oct 2026
Bulk cleanup
The purge command can bulk-delete emails from selected senders or target a sender domain.github.com · read 8 Oct 2026
Cleanup
It ranks senders by storage impact and supports bulk cleanup, including deleting 300+ emails from one sender in a single command.github.com · read 8 Oct 2026
Cloud AI data
When AI features use Anthropic, the tool sends email subjects, sender names or addresses, and snippets, but not full email bodies or attachments.github.com · read 8 Oct 2026
Email providers
It works with Gmail and IMAP services, including Outlook, Fastmail, iCloud, and self-hosted IMAP servers.github.com · read 8 Oct 2026
License
The repository describes mailtrim as MIT-licensed and free to use, modify, and distribute.github.com · read 8 Oct 2026
Local data
The privacy policy says email metadata, undo logs, and related data are stored locally, and full email bodies are never stored locally or sent anywhere.github.com · read 8 Oct 2026
Local storage
The privacy policy says OAuth tokens, metadata cache, undo logs, rules, and unsubscribe history are stored locally under ~/.mailtrim/.github.com · read 8 Oct 2026
Purpose
mailtrim is a command-line tool for finding and cleaning up inbox clutter.github.com · read 8 Oct 2026
Safety preview
The purge command supports a dry-run preview of what would be deleted before confirmation.github.com · read 8 Oct 2026
Security limitation
The threat model describes mailtrim as a single-user local CLI and says multi-user or server deployment threats are out of scope.github.com · read 8 Oct 2026
Sender ranking
It ranks senders by storage impact, rather than only by message count.github.com · read 8 Oct 2026
Support
The README directs users to GitHub Issues for bug reports and feature requests.github.com · read 8 Oct 2026
Telemetry
The privacy policy says mailtrim has no analytics, crash reporting, or usage tracking.github.com · read 8 Oct 2026
Undo
Deleted messages go to Trash and can be restored for up to 30 days.github.com · read 8 Oct 2026

Alternatives to mailtrim

Every alternative, ranked