thunderbird-cli — Claude Code MCP server: email and setup
Connect an AI agent to email in Mozilla Thunderbird to search messages, read them, and prepare drafts. Mail credentials stay inside Thunderbird.
claude mcp add --env TB_BRIDGE_HOST=<TB_BRIDGE_HOST> --env TB_BRIDGE_PORT=<TB_BRIDGE_PORT> --transport stdio thunderbird-cli -- npx -y thunderbird-cli-mcpWhat thunderbird-cli does
thunderbird-cli gives an AI agent MCP access to accounts managed by Mozilla Thunderbird. Its 12 tools support email search and reading, draft replies, and attachment tasks. A bridge connects the MCP server to Thunderbird; the separate CLI also provides commands for folders and bulk operations.
You need Node.js 20 or later, Thunderbird 128+, and the bridge extension. Keep the tb-bridge daemon running: the agent cannot reach mail without it. IMAP and SMTP credentials remain in Thunderbird, and the CLI does not store email data. Replies and forwards are saved as drafts; permanent deletion requires --confirm.
What it helps with
- search messages by sender and subject
- count unread mail across accounts
- prepare a reply as a draft
- download an attachment from a message
- move older messages to another folder
Example prompts for the agent
- Find invoice emails from AWS from last month.
- Count unread messages across all accounts.
- Draft a reply to message 118 and leave it unsent.
How to install thunderbird-cli
Platform CLI
claude mcp add --env TB_BRIDGE_HOST=<TB_BRIDGE_HOST> --env TB_BRIDGE_PORT=<TB_BRIDGE_PORT> --transport stdio thunderbird-cli -- npx -y thunderbird-cli-mcpReplace <…> with your own values
Platform CLI
codex mcp add thunderbird-cli --env TB_BRIDGE_HOST=<TB_BRIDGE_HOST> --env TB_BRIDGE_PORT=<TB_BRIDGE_PORT> -- npx -y thunderbird-cli-mcpReplace <…> with your own values
Config file
{
"mcpServers": {
"thunderbird-cli": {
"command": "npx",
"args": [
"-y",
"thunderbird-cli-mcp"
],
"env": {
"TB_BRIDGE_HOST": "<TB_BRIDGE_HOST>",
"TB_BRIDGE_PORT": "<TB_BRIDGE_PORT>"
}
}
}
}Replace <…> with your own values
Config file
{
"servers": {
"thunderbird-cli": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"thunderbird-cli-mcp"
],
"env": {
"TB_BRIDGE_HOST": "<TB_BRIDGE_HOST>",
"TB_BRIDGE_PORT": "<TB_BRIDGE_PORT>"
}
}
}
}Replace <…> with your own values
Platform CLI
gemini mcp add -e TB_BRIDGE_HOST=<TB_BRIDGE_HOST> -e TB_BRIDGE_PORT=<TB_BRIDGE_PORT> thunderbird-cli npx -y thunderbird-cli-mcpReplace <…> with your own values
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about thunderbird-cli
How do I install thunderbird-cli in Claude Code?
Run claude mcp add thunderbird-cli -- npx -y thunderbird-cli-mcp. You also need Thunderbird 128+, the bridge extension, and the tb-bridge daemon running.
What does thunderbird-cli do?
It connects an AI agent to Thunderbird email through MCP. The agent can search and read messages, prepare replies, and handle attachments.
Does thunderbird-cli need my email passwords?
No. IMAP and SMTP credentials stay in Thunderbird, which manages the accounts. The CLI does not store email data.