mail-mcp
Provides tools for searching, reading mail, and creating/updating/deleting drafts with HTML and attachments for Thunderbird email workflows.
Click on "Install 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., "@mail-mcpsearch my inbox for recent emails from Alice"
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.
mail-mcp
Built on davidvornholt/standards.
A draft-only IMAP helper for Thunderbird workflows, exposed to Codex, Claude, and other compatible clients as an MCP server and to you as a mail CLI over one shared Effect core. Through the MCP server it can search and read mail and received attachments, and create, update, or delete drafts with HTML and attachments; the mail CLI covers login, status, folder/search/read, and plain-text draft creation. It cannot send emails: drafts sync into Thunderbird for review and sending.
Layout
apps/mail the application (MCP server + CLI)
src/app entrypoints: server.ts (MCP, stdio), cli.ts (the `mail` bin)
src/features/mail schemas, tagged errors, and Effect services (config, secrets, status, IMAP, draft, login)
src/shared app-local infrastructure (arg parsing, hidden-input terminal prompt)
packages/* canonical shared config synced from the standards templateSee apps/mail/README.md for the tool list, configuration, and secret handling.
Related MCP server: imap-mcp
Setup
bun install
# put the `mail` command on your PATH (one-time; links the app's bin into
# ~/.bun/bin). After this, run `mail …` from anywhere.
bun link --cwd apps/mail
# configure your accounts (non-secret: addresses, IMAP hosts, and ports). The real
# file is git-ignored so your addresses never land in git.
cp apps/mail/accounts.example.toml apps/mail/accounts.toml
# …edit apps/mail/accounts.toml…
# verify each account's password against IMAP, then store it in the OS keyring
# (hidden prompt — nothing is echoed or written to disk). Run this yourself;
# the secret never leaves your machine.
mail login you@example.com
# confirm each account authenticates cleanly (or shows what still needs a login)
mail statusRegister the MCP server with Codex:
codex mcp add mail -- bun run <repo>/apps/mail/src/app/server.ts
codex mcp get mailCodex defers MCP tool definitions until they are relevant, so registering the
server does not eagerly add every mail tool schema to the model context. Restart
Codex after adding it, then use /mcp to inspect the connected server.
For explicit write approvals and more headroom for IMAP operations, edit the
generated entry in ~/.codex/config.toml:
[mcp_servers.mail]
command = "bun"
args = ["run", "<repo>/apps/mail/src/app/server.ts"]
startup_timeout_sec = 15
tool_timeout_sec = 120
default_tools_approval_mode = "writes"
[mcp_servers.mail.tools.delete_draft]
approval_mode = "prompt"For Claude Code (user scope), use:
claude mcp add --scope user mail -- bun run <repo>/apps/mail/src/app/server.tsOnce a password is stored, ask your MCP client to search your mail or compose a draft. You can also drive the review-first CLI yourself:
mail search invoice
mail search --account you@example.com invoiceOmitting --account searches every configured account, merges and deduplicates the results, and applies the limit globally. Pass --account <email> to search only that account. Each result includes its account handle, and failures from individual accounts are reported alongside partial results. If every account fails, the command fails with all account errors.
Folder searches are account-specific: use mail search --account you@example.com --scope folder --folder INBOX ... for one exact folder or --scope subtree --folder Projects for a folder and its descendants.
Not ready to link a global command? Every example also works as bun run apps/mail/src/app/cli.ts <args>.
Requirements
Bun (see
packageManagerinpackage.json).A running, unlocked Secret Service provider (gnome-keyring) for the OS keyring.
Quality gate
bun run check runs the standards drift check, then lint, type-check, tests, build, and a11y across every workspace. It must pass before a change is done.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- FlicenseAqualityBmaintenanceA lightweight MCP server for interacting with IMAP email accounts to read messages, manage folders, and compose draft replies. It supports standard providers and local bridges, providing tools for searching, fetching attachments, and organizing mailboxes without the ability to send or delete emails.Last updated196
- Flicense-qualityDmaintenanceAn IMAP client MCP server for reading mail from Dovecot or Synology MailPlus mailboxes, with optional webhook triggers for new messages. It provides tools for managing emails and automates workflows by firing webhooks when matching messages arrive.Last updated
- Flicense-qualityBmaintenanceA read-only MCP server that lets Claude read and search emails from Thunderbird accounts and access contacts, working directly with profile files.Last updated1
- AlicenseBqualityBmaintenanceUniversal IMAP/SMTP MCP server that works with any email provider, providing tools to read, search, send, and manage emails.Last updated101101MIT
Related MCP Connectors
Read, search, send, organize, draft and schedule email across your inboxes from any MCP client.
Manage Gmail end-to-end: search, read, send, draft, label, and organize threads. Automate workflow…
Manage Gmail messages, threads, labels, drafts, and settings from your workflows. Send and organiz…
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/davidvornholt/mail-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server