by sweetrb
MCP server for Apple Mail - read, search, send, and manage emails via Claude and other AI assistants
# Add to your Claude Code skills
git clone https://github.com/sweetrb/apple-mail-mcpGuides for using ai agents skills like apple-mail-mcp.
apple-mail-mcp is an open-source ai agents skill for AI coding assistants such as Claude Code, Codex CLI, and ChatGPT, built by sweetrb. MCP server for Apple Mail - read, search, send, and manage emails via Claude and other AI assistants. It has 127 GitHub stars.
apple-mail-mcp's catalog security scan is still queued. You can run an instant dependency and prompt-injection check now with the "Scan for vulnerabilities" button above.
Clone the repository with "git clone https://github.com/sweetrb/apple-mail-mcp" and add it to your Claude Code skills directory (see the Installation section above).
apple-mail-mcp is primarily written in JavaScript. It is open-source under sweetrb on GitHub, so you can review or fork the full source.
Yes. AgentsLLM lists many other AI Agents skills you can browse and compare side by side. Open the AI Agents category from the badge at the top of this page, or use the Related Skills and comparison links further down to weigh apple-mail-mcp against similar tools.
No comments yet. Be the first to share your thoughts!
Unlocks once the catalog security scan passes (runs nightly).
The deep catalog scan for this skill is still queued. Run an instant dependency check now instead.
A Model Context Protocol (MCP) server that enables AI assistants like Claude to read, send, search, and manage emails in Apple Mail on macOS.
Note: This is the npm/Node.js package — install with
npxornpm. There is an unrelated Python project of the same name on PyPI (imdinu/apple-mail-mcp) installed viapipx/uvx. If you're usinguvxand seeing acycloptsdependency error, you're looking for that project, not this one.
This server acts as a bridge between AI assistants and Apple Mail. Once configured, you can ask Claude (or any MCP-compatible AI) to:
The AI assistant communicates with this server, which then uses AppleScript to interact with the Mail app on your Mac. All data stays local on your machine.
If you're using Claude Code (in Terminal or VS Code), just ask Claude to install it:
Install the sweetrb/apple-mail-mcp MCP server so you can help me manage my Apple Mail
Claude will handle the installation and configuration automatically.
Or register it deterministically in one command:
claude mcp add apple-mail -s user -- npx -y apple-mail-mcp
Install as a Claude Code plugin for automatic configuration and enhanced AI behavior:
/plugin marketplace add sweetrb/apple-mail-mcp
/plugin install apple-mail
This method also installs a skill that teaches Claude when and how to use Apple Mail effectively.
Configuring IMAP/SMTP for a plugin install: a plugin install has no editable
envblock, so supply settings via the config file at~/Library/Application Support/apple-mail-mcp/config.json— Method B in the IMAP / SMTP Setup Guide. Passwords stay in the macOS Keychain; run thedoctortool to verify.
See Apple Mail in Codex for setup and diagnostics, and the guided setup and OAuth proposal for proposed future authorization support.
Install the same public marketplace in Codex:
codex plugin marketplace add sweetrb/apple-mail-mcp
codex plugin add apple-mail@apple-mail-mcp
The Codex package includes a portable codex/plugin.json, typed stdio server
configuration in codex/mcp.json, the Apple Mail skill, and the existing assets.
It retains codex/.codex-plugin/plugin.json and codex/.mcp.json for compatible
older hosts. Both layouts register the same apple-mail MCP identity through
npx -y apple-mail-mcp@<plugin version>. Release synchronization updates both
runtime pins and manifest metadata; tests and CI reject drift. An unreleased
candidate can be discovered locally, but its exact npm version must be
published before that pinned launcher can be installed from the registry.
For ongoing upstream updates, keep the Git marketplace configured. After a new release is published, refresh its catalog:
codex plugin marketplace upgrade apple-mail-mcp
Install the published plugin version from the refreshed marketplace, then start
a new Codex session. The refresh does not replace the runtime pin with @latest;
the plugin and its pinned npm runtime must refer to the same available release.
The standalone plugin archive bundles the server and requires only Node.js 20+ on the Mac; it does not fetch a runtime from npm. Download it from the release assets, or use the candidate artifact attached to a successful CI run. See Standalone plugin archive for the distribution format and local build command.
An imported archive or separately uploaded private account plugin is a snapshot, not a subscription to this repository's releases. Updating that copy requires a replacement package. When switching to the maintained marketplace distribution, preserve settings and approvals, verify Mail access and reply behavior, then remove the redundant installation. See Updates and migration.
For a personal build, you may explicitly supply a local PNG:
node scripts/package-codex-plugin.mjs /path/apple-mail.tar.gz --icon /path/icon.png.
The optional image must be square, noninterlaced, 48–2,048 pixels per side, and
at most 4 MiB. It is bundled inside the skill's assets directory and used for
the generated portable and compatibility manifests' light/dark logo and composer
icons. Source manifests, the runtime, and default artwork remain unchanged;
omitting --icon preserves the standard archive. No image is fetched automatically.
Supply only artwork you have permission to use and distribute; this option does
not grant rights to Apple or other third-party artwork, or guarantee that a host
will refresh an existing listing's cached presentation.
The compose tools accept composition: "native-editor" to insert new prose
through Mail's visible editor, leaving its signature and reply history intact.
This opt-in path uses existing macOS Accessibility and Automation permissions;
it does not require a separate computer-control plugin. It verifies the composer
and sender, preserves the clipboard, and stops without sending if insertion
cannot be verified. See native composition for
setup, examples, and verification limits. Existing SMTP and AppleScript behavior
is unchanged when the option is omitted.
Two more hosts can run the same apple-mail MCP server (npx -y apple-mail-mcp):
Hermes Agent (NousResearch) — Hermes has no plugin/marketplace drop-in, so there is nothing in this repo to install from. Register the server with the CLI:
hermes mcp add apple-mail --command npx --args -y apple-mail-mcp
Or add it to ~/.hermes/config.yaml by hand:
mcp_servers:
apple-mail:
command: npx
args: ["-y", "apple-mail-mcp"]
Restart your Hermes session afterward so the tools load.
Antigravity (Google) — add the server entry from .antigravity-plugin/mcp_config.json to ~/.gemini/config/mcp_config.json (or via Antigravity's MCP settings).
1. Install the server:
npm install -g apple-mail-mcp
2. Add to Claude Desktop (~/Library/Application Support/Claude/claude_desktop_config.json):
{
"mcpServers": {
"apple-mail": {
"command": "npx",
"args": ["apple-mail-mcp"]
}
}
}
3. Restart Claude Desktop and start using natural language:
"Show me my unread emails"
On first use, macOS will ask for permission to automate Mail.app. Click "OK" to allow.
The server works out of the box over AppleScript with no configuration. Two opt-in power features take a one-time setup:
send-email submits clean MIME directly, avoiding the
macOS 15+ Mail.app <blockquote> wrapping that otherwise makes sent mail look
quoted/indented like a reply.Both are driven by non-secret APPLE_MAIL_MCP_* settings — supplied via an env
block or a config.json file (for hosts like Claude Desktop that strip env)
— with passwords kept in the macOS Keychain, never in config.
👉 IMAP / SMTP Setup Guide — step-by-step: app passwords,
Keychain, both config methods, multi-account, SMTP, verification with the doctor
tool, and troubleshooting. Verify any time by running the doctor tool.
search-contacts only. It reads the Contacts database directly through Node's built-in node:sqlite, which does not exist before 22.5. On an older runtime, or without Full Disk Access for the Node binary, it logs one line to stderr and returns