Mbox Mcp

io.github.arose26Published by GitHub account arose26v0.1.1Updated Oct 25, 2026

Search local email archives (.mbox/.eml) entirely on your machine. No OAuth, no cloud.

Overview

AI-generated overview

A local MCP server that indexes .mbox and .eml email archives on your machine so an assistant can search and read them offline.

What you can do
Open an .mbox file or a folder of .eml files and index it, returning message count, date range and top senders. Search messages by keyword, sender, subject or date range, with an optional bounded body-text search. Read a single message in full, including decoded body, headers and attachment names and sizes.
When to use it
Useful when you have an exported email archive, such as a Google Takeout .mbox or a folder of .eml files, and want an assistant to search, summarize or analyze it without connecting to a live mailbox.
Requirements
Runs as a local process via npx (Node.js required). Needs a path to an .mbox file or an .eml directory on the local machine. No accounts, API keys or network access are declared.
Before you install
The assistant can read the full text of your archived email, including personal or sensitive correspondence, so only point it at archives you are comfortable exposing in the conversation. Attachment contents are not returned. Plain mboxo archives with unquoted body lines may be split incorrectly.

Installation

In SourceWeft

  1. Open Mbox Mcp in the dashboard and add it to a workspace.
  2. Enable the server for the chats that should use its tools.

Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.

Other MCP clients

Follow the launch instructions in the repository.

README

mbox-mcp

An MCP server for local email archives. Point it at a Google Takeout .mbox export or a folder of .eml files and ask Claude things like:

  • "Who did I email most in this archive?"
  • "Find the message where the landlord mentioned the lease renewal."
  • "Summarize my correspondence with [email protected] from early 2026."

Everything stays on your machine. No OAuth, no app passwords, no IMAP connection, no cloud. Every other email MCP server connects to a live account — this one reads the archive files you already have, which is exactly what you want for the 15 years of Gmail sitting in a Takeout export.

Quick start

Claude Code

bash
claude mcp add mbox -- npx -y mbox-mcp

Claude Desktop — add to claude_desktop_config.json:

json
{  "mcpServers": {    "mbox": {      "command": "npx",      "args": ["-y", "mbox-mcp"]    }  }}

Then: "Open C:\Takeout\Mail\All mail Including Spam and Trash.mbox and tell me about it."

Tools

ToolWhat it does
open_archiveIndex an .mbox file or .eml directory: message count, date range, top senders
search_messagesSearch by keyword, sender, subject, date range — plus bounded body-text search
get_messageFully parse one message: decoded body, headers, attachment names/sizes

Built for large archives

A Takeout mbox is often multiple gigabytes with 100k+ messages. The design reads the minimum, lazily:

  • Streaming index — one pass in 8 MiB chunks, recording byte offsets; only the current message's first 16 KiB is ever held for envelope parsing (sender, subject, date, RFC 2047 decoding).
  • Full MIME on demand — reading a message parses just that message (postal-mime: nested multipart, charsets, quoted-printable/base64). Attachments are listed with names and sizes, never dumped into context.
  • Honest body search — body_query only full-parses messages that already match your envelope filters, stops at a scan cap, and reports how many it scanned, so the model knows to narrow by sender or date first.
  • Staleness-aware cache — archives are indexed once per process and re-indexed if the file changes.

Notes and limitations

  • mbox variants: Takeout and Thunderbird produce mboxrd (body From lines are quoted as >From ), which splits cleanly. Plain mboxo archives with unquoted body From lines can over-split.
  • Attachment contents are never returned or written anywhere.
  • PST/OST and Maildir are out of scope for now.

Development

bash
npm installnpm test                 # offline tests — synthetic archives built in-suitenpm run build            # tsc → dist/node scripts/smoke.mjs   # end-to-end: generates an archive, drives the server over stdio

Architecture: src/archive.ts (streaming indexer, header decoding, envelope filtering) and src/reader.ts (per-message MIME parsing) are pure logic; src/index.ts is the MCP wiring. The test suite includes a chunk-seam property test: indexing with pathological 17-byte chunks must produce an identical index to whole-file reads.

License

MIT

Source: README.md at commit 8cd0567

Tools

0
SourceWeft has not started this package in its sandbox yet, so its tools are not known.

Version history

1
  1. v0.1.1LatestSep 16, 2026

Score

50% of the applicable checks met

How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.

  • Reached in the last 30 days25 pts

    Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.

  • Auth declared10 pts

    Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.

  • Tools listed15 pts

    Answer tools/list without a credential, or ship a package that starts in a sandbox without one.

  • DescriptionRequired15 pts
  • Logo10 pts
  • Documentation15 pts
  • License10 pts