Proton MCP Server
Provides comprehensive email management capabilities for Proton services via Proton Mail Bridge, enabling folder navigation, searching, reading messages with attachments, and sending or replying to emails.
Enables full email management for Proton Mail through Proton Mail Bridge, allowing users to list folders, search and read emails, send new messages and replies, and manage mailbox organization.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Proton MCP Server find the latest email from GitHub and summarize its content"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Proton MCP Server
A complete TypeScript Model Context Protocol (MCP) server for Proton Mail integration via Proton Mail Bridge.
What This Does
This MCP server provides full email management capabilities through Claude Code by connecting to Proton Mail Bridge running locally. It allows you to:
List and browse mailbox folders
List, search, and read emails
Send new emails and replies
Move and delete emails
Access full message content with attachments
Related MCP server: ProtonMail MCP Server
Prerequisites
Proton Mail Bridge running and accessible on localhost:
IMAP server on port 1143 (STARTTLS)
SMTP server on port 1025 (STARTTLS)
Node.js 18 or higher
A valid Proton Mail account with Bridge credentials
Setup
1. Install Dependencies
npm install2. Configure Environment
Copy the environment template and add your Proton credentials:
cp .env.example .envEdit .env with your settings:
PROTON_IMAP_HOST=127.0.0.1
PROTON_IMAP_PORT=1143
PROTON_SMTP_HOST=127.0.0.1
PROTON_SMTP_PORT=1025
PROTON_USER=your-proton-email@protonmail.com
PROTON_PASS=your-bridge-password3. Build
npm run build4. Run Locally (Development)
npm run devOr run the compiled version:
npm startUsage with Claude Code
Add this MCP server to your Claude settings (~/.claude/settings.json):
{
"mcpServers": {
"proton": {
"command": "node",
"args": ["/path/to/proton-mcp-server/dist/index.js"],
"env": {
"PROTON_USER": "your-email@protonmail.com",
"PROTON_PASS": "your-bridge-password",
"PROTON_IMAP_HOST": "127.0.0.1",
"PROTON_IMAP_PORT": "1143",
"PROTON_SMTP_HOST": "127.0.0.1",
"PROTON_SMTP_PORT": "1025"
}
}
}
}Or with TypeScript/tsx:
{
"mcpServers": {
"proton": {
"command": "npx",
"args": ["tsx", "/path/to/proton-mcp-server/src/index.ts"]
}
}
}Available Tools
Reading Tools (Read-Only)
proton_list_folders — List all mailbox folders with message and unread counts
proton_list_emails — List emails in a folder with pagination (newest first)
proton_search_emails — Advanced search with filters (from, to, subject, date range, body content, unread status)
proton_read_email — Read the complete email content including headers, body, and attachment list
Writing Tools
proton_send_email — Send a new email (plain text or HTML)
proton_reply_email — Reply to an email with proper threading headers
proton_move_email — Move email to another folder
proton_delete_email — Delete email (move to Trash)
Project Structure
proton-mcp-server/
├── src/
│ ├── index.ts # Main entry point
│ ├── constants.ts # Configuration constants
│ ├── types.ts # TypeScript interfaces
│ ├── schemas/
│ │ └── index.ts # Zod input schemas
│ ├── services/
│ │ ├── imap.ts # IMAP client wrapper
│ │ └── smtp.ts # SMTP client wrapper
│ └── tools/
│ ├── folders.ts # proton_list_folders
│ ├── list.ts # proton_list_emails
│ ├── search.ts # proton_search_emails
│ ├── read.ts # proton_read_email
│ ├── send.ts # proton_send_email
│ ├── reply.ts # proton_reply_email
│ ├── move.ts # proton_move_email
│ └── delete.ts # proton_delete_email
├── package.json
├── tsconfig.json
├── .env.example
├── .gitignore
└── README.md (this file)Implementation Notes
IMAP Connection
Uses
imapflowlibrary with STARTTLS on port 1143Proton Bridge uses self-signed certificates, so
tls.rejectUnauthorized: falseAll connections are properly closed with
logout()in finally blocks
SMTP Connection
Uses
nodemailerwith STARTTLS on port 1025Supports plain text and HTML email bodies
Properly sets
In-Reply-ToandReferencesheaders for email threading
Message Parsing
Uses
mailparserto extract full message contentSupports text, HTML, and attachment handling
Returns attachment metadata (filename, content type, size)
Pagination
Email list pagination uses offset and limit parameters
Results are always newest first
Search results also support pagination
Troubleshooting
Connection Issues
Ensure Proton Mail Bridge is running:
protonmail-bridge --cliCheck localhost connectivity:
telnet 127.0.0.1 1143(IMAP) and1025(SMTP)Verify credentials in
.envfile
Email Issues
Some email clients may not recognize replies without proper Message-ID headers
HTML emails are parsed to text; use the raw HTML body for better formatting
Large attachments may take time to process
Build Issues
Ensure Node.js 18+ is installed:
node --versionClear node_modules and reinstall:
npm clean-installCheck TypeScript compilation:
npm run build
Dependencies
@modelcontextprotocol/sdk— MCP protocol implementationimapflow— IMAP client for email readingnodemailer— SMTP client for sending emailsmailparser— Email parsing and content extractionzod— Input validation schemasdotenv— Environment variable loading
License
MIT
Support
For issues with Proton Mail Bridge, see: https://proton.me/support/bridge
For MCP protocol documentation, see: https://modelcontextprotocol.io
Available Tools
8 toolsproton_delete_emailDelete EmailADestructiveIdempotent
Delete an email by moving it to the Trash folder. Use the folder name and email UID.
Inputs: uid (required), folder.
proton_list_emailsList Emails in FolderARead-onlyIdempotent
List emails in a specific folder with pagination. Shows sender, subject, date, and read status. Results are newest first.
Inputs: folder, limit, offset.
proton_list_foldersList Proton Mail FoldersARead-onlyIdempotent
List all mailbox folders (INBOX, Sent, Drafts, Trash, etc.) with message counts and unread counts
Inputs: response_format.
proton_move_emailMove EmailBIdempotent
Move an email from one folder to another. Specify source folder, email UID, and destination folder.
Inputs: folder (required), uid (required), destination (required).
proton_read_emailRead Full EmailARead-onlyIdempotent
Read the complete content of an email, including headers, body, and attachments. Specify folder and email UID.
Inputs: uid (required), folder.
proton_reply_emailReply to EmailA
Send a reply to an existing email. Properly sets In-Reply-To and References headers for threading. Can reply to all or just the sender.
Inputs: uid (required), body (required), folder, reply_all.
proton_search_emailsSearch EmailsARead-onlyIdempotent
Search emails by sender, recipient, subject, date range, body content, or unread status. Multiple criteria are combined with AND logic.
Inputs: folder, from, to, subject, +6 more.
proton_send_emailSend EmailB
Send a new email. Supports plain text and HTML formats. Recipients can be a single string or array of strings.
Inputs: to (required), subject (required), body (required), cc, +2 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 8 tools
Each tool has a clearly distinct purpose targeting specific email operations: listing, reading, sending, replying, searching, moving, deleting, and folder management. There is no overlap in functionality, making tool selection straightforward for an agent.
All tool names follow a consistent 'proton_verb_noun' pattern using snake_case, such as proton_list_emails and proton_send_email. This uniformity enhances readability and predictability across the toolset.
With 8 tools, the server is well-scoped for email management, covering essential operations like CRUD (create, read, update via move/reply, delete), search, and folder handling. Each tool serves a clear purpose without redundancy.
The toolset provides complete coverage for email workflows, including listing, reading, sending, replying, searching, moving, deleting, and folder management. There are no obvious gaps, enabling agents to handle full email lifecycle tasks effectively.
Maintenance
Related MCP Connectors
Email infrastructure for AI agents — send, receive, search, and reply to email over MCP.
Connect any IMAP/SMTP mailbox to Claude & ChatGPT: search, read, sort, draft. Sends only with OK.
Connect AI agents to Emitd email sending, message tracking, templates, and automations. Emitd hosts a Model Context Protocol server for integrating supported email operations into AI-agent workflows. Connect a compatible client to the hosted endpoint (https://mcp.emitd.com/mcp) and authenticate with an Emitd API key. Available tools depend on the key's permissions and enabled features. Emitd's capability areas include sending email, message activity, templates, contacts, audiences, segments, domains, analytics, inbound email, broadcasts, automations, webhooks, and suppressions. Use restricted keys, sending guardrails, and approval settings appropriate to each workflow. For more information check https://emitd.com
Your mailboxes in ChatGPT and Claude: Gmail, iCloud, Fastmail, any IMAP. Passwords stay yours.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI clients to interact with ProtonMail accounts through the Proton Bridge using SMTP and IMAP protocols. Provides email management capabilities via secure local bridge connections.8 npmMIT
- AlicenseAqualityBmaintenanceEnables AI agents to send, read, search, and organize emails via ProtonMail using Proton Bridge. Supports MCP-compatible clients like Claude and Cursor.1820 npm4MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI assistants to send, read, search, and organize Proton Mail email via SMTP and IMAP through the Model Context Protocol.MIT
- AlicenseAqualityBmaintenanceEnables AI assistants to read, organize, and send Proton Mail through the local Proton Bridge, with careful gating for sending and attachment access.252Apache 2.0