Launch sale: 25% off all premium source code · ends October 15
Premium source code

Email Toolkit Pro

Search, back up, export and clean up any IMAP mailbox in Python, with Gmail-style queries and rules.

$11.25$15 -25%
Instant download Secure checkout by Stripe Free updates 14-day refund guarantee
11commands
1.9klines of code
13tests
anyIMAP server
Email Toolkit Pro in action

The complete version of our reading emails tutorial: a Gmail-style search language for any IMAP server, robust parsing of real-world emails, incremental backups to .eml files with a full-text search index, exports to a browsable HTML archive, mbox and CSV, attachment downloads, rules that always dry-run first, inbox insights and a newsletter unsubscribe finder.

Upgrades the free tutorial: How to Read Emails in Python

What makes it “Pro”

Everything the tutorial leaves as an exercise, done properly.

Gmail-style search

from:, has:attachment, is:unread, larger:5M, older:30d, OR, NOT... on any IMAP server.

Incremental backups

.eml files + a SQLite full-text index; only new mail is downloaded next time.

HTML archive

Export a searchable archive that opens in any browser, plus mbox and CSV.

Attachments

Download attachments by query, organised by year and sender, duplicates skipped.

Rules

Move, mark, flag and save attachments by query; always a dry run before --apply.

Insights

Top senders, volume per month, and the newsletters you never read.

Safe by default

Read-only browsing that never marks mail as read, TLS, no plain-text passwords.

Tested

13 pytest tests plus a --demo mailbox to try every command safely.

Screenshots

Real output of the tools. Sample data is used wherever a screenshot would show private information (networks, emails, processes).

Free tutorial vs. Email Toolkit Pro

The tutorial is great for learning the basics. This is the version you'd actually ship.

Free tutorialEmail Toolkit Pro
SearchFetch the latest NA full query language
ParsingBasicCharsets, HTML-only mail, RFC 2231 names
Backups—✓ incremental, full-text searchable
Exports—HTML archive, mbox, CSV
Rules—✓ with dry run
Insights + unsubscribe finder—✓
Tests—13 pytest tests

A peek at the code

Clean, commented, modular Python. Here's the start of mailkit/query.py:

email-toolkit-pro/mailkit/query.py 2100 lines of Python in this project
def to_imap(q: Query, today: Optional[date] = None) -> List[str]:
    """IMAP SEARCH criteria tokens (implicitly ANDed). OR takes exactly two
    search keys, and "NOT FROM x" or "OR a b" each count as one key."""
    if not q.groups:
        return ["ALL"]
    out: List[str] = []
    for g in q.groups:
        parts = [_imap_term(t, today) for t in g]
        crit = parts[-1]
        for p in reversed(parts[:-1]):
            crit = ["OR"] + p + crit
        out += crit
    return out

The rest of the source code is locked

Get every module of Email Toolkit Pro, plus tests, the README guide and free updates, for $11.25.

Unlock the full source · $11.25

What's inside

  • Full source code (≈1,900 lines, 12 modules)
  • A demo mailbox to try every command
  • README with an architecture guide
  • 13 unit tests (pytest)
  • Free updates + commercial-use license
Save 67%

Get all 5 tools for $21.75

The Python Tools Pro Pack includes Email Toolkit Pro plus our other premium tools, for $21.75 instead of $65 when bought one by one.

What's in the pack?
Python Tools Pro Pack

FAQ

What do I need to run it?

Python 3.8 or newer with rich (keyring optional). Any IMAP account: Gmail, Outlook, Yahoo and iCloud need an app password. Every command has a --demo mode with a sample mailbox.

How do I get the files after paying?

You're sent straight to your download page, and we email you the link too. The link keeps working, so you can re-download updated versions later. Lost it? Recover your downloads with your email.

Is this beginner-friendly?

If you've followed our free tutorial, yes. The code is split into small, commented modules, and the README walks through the architecture. It's the ideal next step after the tutorial.

Can I use it in my own projects?

Yes. You can modify it, learn from it, and ship your own tools and apps built on it, even commercially. The only thing you can't do is redistribute or resell the source code itself.

What if it's not for me?

Email us within 14 days and we'll refund you. No questions asked.

Get Email Toolkit Pro now

$11.25 one-time. Instant download, free updates.

More premium source code