Search your email archive with Claude – local and read-only
MCP (Model Context Protocol) is an open standard that lets AI programs use tools. Mail Archive includes an email MCP server that gives them search and read access to your archive. You bring the language model: Claude, ChatGPT or a local model. AI access is off by default.
Available on the Mac from version 1.3. The Windows version with these features is coming soon to the Microsoft Store.

What you can ask
“What did the contractor quote me for the garden shed in 2024?”
“Which phone bills did I get in 2025, and which was the highest?”
“Summarize my email thread with Ms. Miller.”
“When did I send the cancellation to my gym?”
“Who sends me the most emails?”
“Which e-invoices came in during Q1, and what is the total?”
What the AI can do and what it can't
| The AI can | The AI cannot |
|---|---|
| Search emails (full text, sender, date range, account, folder) | Delete, move or send emails |
| Read emails and threads | Change anything in the archive |
| List accounts and folders | Access accounts you haven't shared |
| Read text from text attachments (txt, csv, xml, html) | Read attachments if you turn that off |
| Find and analyze e-invoices | Connect from outside without your confirmation |
| Statistics (emails per year, account, sender) |
Where your emails go
Mail Archive itself sends nothing to us. But whatever the connected AI reads, it passes on to its language model. With cloud models such as Claude or ChatGPT, those emails therefore reach that provider. If you don't want that, use a local model, for example with LM Studio. Then nothing leaves your computer.
- AI access is off by default. You turn it on in Settings.
- You share accounts one by one. Email text and attachment text can be switched off separately.
- Every new connection over the internet has to be confirmed in the app.
- “Recent access” shows what was requested. You disconnect programs under “Connected clients” with “Remove”.
Turn it on in Mail Archive
Open Settings
In Mail Archive, open Settings and go to the AI access (MCP) card.
Enable the server
Switch on “Enable MCP server” and confirm the notice. The status then shows “Running”.
Choose what to share
Under “Advanced” › “Shared” you decide which accounts the AI may see and whether email text and attachment text are included.
Copy address and token
The card shows the Server URL (
http://127.0.0.1:8642/mcp) and the Access token. Copying the token gives you the complete header valueBearer …. Don't share the token. “Generate new token” invalidates the old one immediately.Remote access
For ChatGPT and Claude (options A and B), switch on “Remote access” under “Advanced”. Without it, Mail Archive rejects requests that come through a tunnel.
Start a tunnel with cloudflared
The ChatGPT and Claude desktop apps and Claude in the browser can't reach the local http address directly. A tunnel makes it available as an https address. Your archive stays on your computer.
Install cloudflared
Once: on a Mac
brew install cloudflared, on Windowswinget install --id Cloudflare.cloudflared.Start the tunnel
Run
cloudflared tunnel --url http://127.0.0.1:8642in Terminal.Note the address
cloudflared shows an address like
https://xyz-abc.trycloudflare.com. Your MCP address is that address with/mcpat the end.Keep the window open
The tunnel runs as long as Terminal does. The address changes on every start, so add the entry in ChatGPT or Claude again with the new address. For a fixed address, use Tailscale Funnel (option B).

ChatGPT (desktop app)
Prepare
Complete step 0 and step 1.
Add the MCP server
In the ChatGPT app, open the Plugins page, choose the MCPs tab and click Add › Add MCP server in the top right.
Fill in the form
Name
mailarchive, type Streamable HTTP, URL: your cloudflared address with/mcp. Leave the bearer token environment variable empty. Under headers, add the keyAuthorizationwith the valueBearer …from Mail Archive.Save and ask
mailarchive appears under servers with its switch on. Start a new chat and ask, for example, “How many emails are in my mail archive?”.
ChatGPT is a cloud model. Whatever it reads from your archive goes to OpenAI.
Claude in the browser, on desktop and on your phone
A connector in Claude works in all Claude apps. Your computer and Mail Archive have to be running. We don't run a server of our own in between.
Prepare
Complete step 0 and step 1. Instead of cloudflared you can use Tailscale Funnel with a fixed address: install Tailscale, sign in and run
tailscale funnel 8642(permanently:tailscale funnel --bg 8642). The address is thenhttps://<computer-name>.<tailnet>.ts.net/mcp.Add a connector
In Claude, go to Settings › Connectors and click “Add custom connector”. Name
mailarchive, URL: the tunnel address with/mcpat the end. Leave authentication on sign-in with an automatically registered OAuth client. Don't add a request header; the token isn't needed here.Compare the codes
A Mail Archive page with a 6-digit code opens in your browser. At the same time, Mail Archive on your computer asks “Allow access?”. If both codes match, click Allow.
Done
Claude reports that it is connected to mailarchive. The connector is then also available in the Claude desktop app and on your phone. You can disconnect it at any time under “Connected clients” with “Remove”.

Claude Code, Cursor, LM Studio: directly on your computer
Programs that talk to local MCP servers directly don't need a tunnel. They connect to http://127.0.0.1:8642/mcp with the header from step 0. “Remote access” isn't needed for this.
- Claude Code (Terminal):
claude mcp add --transport http mailarchive http://127.0.0.1:8642/mcp --header "Authorization: Bearer <token>". This applies to Claude Code only, not to the Claude desktop app. - Cursor, LM Studio: add the entry
"mailarchive": {"url": "http://127.0.0.1:8642/mcp", "headers": {"Authorization": "Bearer <token>"}}to theirmcp.json.
Maximum privacy: With LM Studio and a local model, everything stays on your computer, including the AI's answers.
If something doesn't work
“Remote access is disabled” or error 403
“Remote access” is off in Mail Archive. Turn it on under AI access › Advanced.
The connector stopped connecting
With cloudflared and no account, the tunnel address has changed. Add the connector again with the new address, or use Tailscale Funnel with a fixed address.
No answer or a timeout
The computer is asleep, Mail Archive is closed or the tunnel was stopped.
“Port 8642 is in use”
Enter a different port in the card. Then change it in the tunnel command and in your AI programs' settings as well.
The AI finds nothing
Check under “Shared” that the account is shared. Ask with simple keywords, for example a company name and a year.
Questions about AI access
Does Mail Archive need AI?
No. Mail Archive works without AI. If you like, you connect your own AI program; you bring the language model yourself.
Can the AI delete my emails?
No. Access is read-only. Deleting, moving, sending or changing anything isn't possible over MCP.
Do my emails go to Mail Archive?
No. We receive nothing. Whatever the AI reads goes to the language model you connect. With a local model, everything stays on your computer.
Does it work with ChatGPT?
Yes, tested with the ChatGPT desktop app through a tunnel. The guide is above under option A.
Does Mail Archive have to be running?
Yes. The MCP server runs inside the app, and the computer must not be asleep.
How much does AI access cost?
It is included in Pro Plus and Business, both one-time purchases with no subscription. The AI itself is subject to its provider's terms.
Mail Archive does more
Ask your own archive
Get Mail Archive for free. AI access is included in Pro Plus and Business.