# iCloud Mail [Health: Active]

**Category:** 💬 Communication  
**Repository:** https://github.com/JulienRabault/icloud-mcp  
**GitHub Stars:** 1  
**Views:** 0  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/icloud-mail

## Description
Read, search, draft, send and file iCloud Mail over IMAP and SMTP. No tool destroys mail.

## Tools
Capabilities this server exposes over MCP:

- **list_folders** — List folders, optionally with message and unread counts
- **folder_status** — Counts for one folder without listing messages
- **search_emails** — Search one folder: text, sender, recipient, subject, dates, flags, size
- **search_all_folders** — The same search across every folder at once
- **read_email** — Full message: decoded body, optional HTML, attachment metadata
- **get_thread** — Rebuild a conversation, optionally with each message body
- **save_attachments** — Write attachments to disk and return their paths
- **save_draft** — Put a message in Drafts. Nothing is sent
- **set_flag** — Read/unread, flagged, answered. Reversible
- **create_mailbox** — Create a folder, accented names included
- **rename_mailbox** — Rename a folder, messages follow
- **delete_mailbox** — Delete an **empty** folder. Refuses while it holds mail
- **auto_organize** — File messages by rules. Simulates unless `dry_run=false
- **move_emails** — Move between folders. Simulates unless `dry_run=false
- **send_email** — Actually sends. No draft step, no undo

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `uvx` (confidence: high):

```json
"mcpServers": {
  "icloud-mail": {
    "command": "uvx",
    "args": ["icloud-mail-mcp"]
  }
}
```

## Documentation

## What iCloud Mail MCP server does

The iCloud Mail MCP server exposes an iCloud mailbox to an MCP-compatible client. It can inspect folders, report message and unread counts, search by content and metadata, read decoded messages, reconstruct conversations, and save attachments to local disk. Searches can target one folder or all folders, which is useful when replies or archived messages are outside the inbox.

Mailbox changes are separated from read operations. The server can create, rename, and delete empty folders; set read, unread, flagged, and answered states; move messages; and apply filing rules. It can also save a message to Drafts or send it directly. There is no message-deletion tool, and deleting a mailbox is refused while it contains mail.

## How it works

The iCloud Mail MCP server uses IMAP for mailbox access and SMTP for outgoing messages. It runs on the local machine, so credentials and mail are not sent to a separate service. MIME handling covers decoded text, optional HTML, attachment metadata, and attachment extraction. Saved attachment files are returned as paths, and incoming filenames are sanitized before writing.

Read tools use read-only mailbox selection and non-marking message fetches. Move operations account for iCloud’s lack of native MOVE and UIDPLUS support by using copy-and-expunge behavior, with a guard against purging unrelated messages already marked for deletion. Searches support accented text and include a client-side fallback when the server cannot perform the requested search.

The package also provides the `icloud://folders` and `icloud://unread` resources, plus prompts for inbox triage, drafting replies, and identifying unanswered follow-ups. Standalone example scripts can produce daily digests, watch for mail from a sender, find waiting replies, or apply filing rules without an MCP client.

## Setup and configuration

Run the setup wizard with Python 3.11 or newer and `uv`. It requests the iCloud address and an app-specific password, tests the connection, writes a `.env` file, and prints client configuration. Apple requires two-factor authentication and an app-specific password for IMAP access; the normal iCloud account password is rejected.

The server can be installed from PyPI with `uvx`, or run from a cloned source checkout after `uv sync`. A standard stdio configuration starts it with `uv run`, the project directory, and the `icloud_mcp` module. Restart the MCP client after changing its configuration. Credentials may be stored in the environment or a gitignored `.env` file, and password values are omitted from settings representations.

## Tools and capabilities

Read capabilities include:

- Listing folders and checking folder counts
- Searching one folder or every folder by text, addresses, subject, dates, flags, and size
- Reading message bodies, HTML, and attachment metadata
- Rebuilding threads and exporting attachments

Write capabilities include:

- Saving drafts without sending them
- Sending messages directly, without an undo step
- Setting reversible flags
- Creating, renaming, and deleting empty mailboxes
- Simulating or applying moves and rule-based organization

## Limitations and notes

Sending is immediate and does not pass through Drafts, so clients should obtain approval for the exact content first. Move and organization tools can simulate their changes unless `dry_run=false`; applying them changes the mailbox. The server intentionally has no tool for deleting individual messages.

Attachment contents are written to disk rather than passed through the model. Email content is treated as data, not as instructions for the client. iCloud folder names use modified UTF-7, and malformed or misleading character sets receive fallback handling during message decoding.

_Full upstream README: https://allmcps.com/mcp/icloud-mail/readme_

