InboxPie — Visualize and clean your inbox. Private, local, open source
Project description
InboxPie CLI - Visualize and clean your inbox. Private, local, open source.
The CLI version of InboxPie is a local-first Python command-line tool for macOS that scans Apple Mail metadata and generates audit analytics compatible with the Thunderbird extension.
Thunderbird users can use the InboxPie Thunderbird extension to visualize and clean their inbox.
We are currently in progress to bring InboxPie to other mailboxes like O365 and other Clients in the near future. If you are interested in helping us with this, please contribute to the project
Install from PyPI
pip install inboxpie
Install from Github repo
cd CLI
python -m venv .venv
source .venv/bin/activate
pip install -e .
Commands
inboxpie version
inboxpie privacy-settings # macOS: open Full Disk Access in System Settings
inboxpie scan --source apple-mail [--mode auto|index|emlx] [--mail-root PATH] [--folders "INBOX,Sent"] [--output terminal|csv|json|html|all] [--report-dir DIR] [--privacy]
Full Disk Access (required on macOS)
Reading ~/Library/Mail/ requires Full Disk Access for the app where you run the command — Terminal, iTerm, Cursor, VS Code, etc. — not inboxpie and not Python.
First-time setup:
- Run
inboxpie privacy-settingsto open System Settings → Privacy & Security → Full Disk Access. - Enable the app InboxPie detects (e.g. Cursor if you use Cursor’s terminal). If detection fails, match the app in your menu bar / window title.
- Quit that app completely (Cmd+Q), reopen it, then scan again.
If a scan fails for permissions, inboxpie scan prints which app to enable and reminds you to run inboxpie privacy-settings.
auto/index: need FDA for the Envelope Index.emlx: also needs FDA to walk~/Library/Mail/on recent macOS versions.
Security: FDA applies to the whole host app, not only inboxpie. Any command run in that same terminal can read protected folders until you revoke access. Use a terminal you trust, toggle FDA off when finished
Scan strategy
Apple Mail stores messages in two places that InboxPie can read locally:
| Layer | What it is | InboxPie mode |
|---|---|---|
| Envelope Index | SQLite catalog Mail.app uses for search, folders, and flags | --mode index |
.emlx files |
One file per message under ~/Library/Mail/V*/ |
--mode emlx |
Default: --mode auto
- Read the Envelope Index first — fast, and aligned with what Mail.app shows.
- If the index is unavailable (permissions, missing file, schema mismatch), fall back to
.emlxautomatically.
Scan modes
auto(default): Envelope Index first,.emlxfallback.index: Envelope Index only. Fails with a clear error if Full Disk Access is missing or the schema is not recognized.emlx: Walk.emlxfiles only. Slower, but useful when you want filesystem-level scanning or the index is unavailable.
Both engines read metadata only — headers, plist flags, dates, folder paths, and size. Message bodies are never parsed or stored.
Outputs
- Terminal summary (
richtables) - CSV report:
mail-audit-report.csv - JSON report:
mail-audit-report.json - Static HTML report:
--report-dir/inboxpie-report.html
The HTML report mirrors the Thunderbird extension dashboard: PieView, sender/domain drill-down, timeline insights, and selection + review. Use checkboxes or Select buttons to build a set, then open Review Selected to search and inspect subject, sender, folder, date, and size. Export the selection as CSV. There are no move actions in the CLI report (read-only).
Examples
# macOS first-time: open Full Disk Access, enable your terminal app, quit & reopen it
inboxpie privacy-settings
# Default scan (index with emlx fallback) and terminal summary
inboxpie scan --source apple-mail
# Scan only Inbox and Sent folders, emit all report formats
inboxpie scan --folders "INBOX,Sent" --output all --report-dir ./reports
# Force Envelope Index only (faster when FDA is granted)
inboxpie scan --mode index --output json
# Force filesystem scan
inboxpie scan --mode emlx --output all
# Privacy mode (mask emails in terminal/HTML)
inboxpie scan --privacy --output all --report-dir ./reports
Privacy
InboxPie CLI reads only message metadata (sender, subject, date, folder, read status, size). It never reads or stores email body content. See PRIVACY.md for details.
Development
pip install -e ".[dev]"
pytest
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file inboxpie-1.0.3.tar.gz.
File metadata
- Download URL: inboxpie-1.0.3.tar.gz
- Upload date:
- Size: 251.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
10bf31a3303d2da43a4d1b0df1d9aa68e9a1f11f41efa59ac3d6643c8b25632a
|
|
| MD5 |
903498e09faefe924efcb8a5983408d9
|
|
| BLAKE2b-256 |
b4f393185e1356da0918d26285a5ff6755fe8fb8f508e5795ca418b796077d98
|
File details
Details for the file inboxpie-1.0.3-py3-none-any.whl.
File metadata
- Download URL: inboxpie-1.0.3-py3-none-any.whl
- Upload date:
- Size: 250.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bfa5357836e6ee14944198a6bc9f665bcb99183d86731b05b35f53a243aecf4a
|
|
| MD5 |
df8a50b770fb1924af200d270234f7d3
|
|
| BLAKE2b-256 |
ed5ed41b417c7f6e1f04033b90fb65788372045374ad5d1c6a58e98c42a968b6
|