# Mail-MCP [Health: Active]

**Category:** 💬 Communication  
**Repository:** https://github.com/Rixtayz/Mail-MCP  
**GitHub Stars:** 1  
**npm Downloads (last month):** 833  
**Views:** 0  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/mail-mcp-2

## Description
Personal Outlook.com / Hotmail inbox: read, search, file, delete, unsubscribe via Microsoft Graph.

## Tools
Capabilities this server exposes over MCP:

- **mail_list_folders** — List every folder of the Outlook.com mailbox with its path, total message count and unread count. Call it before filing messages to learn which folders exist. Other tools accept a folder by display name ("Invoices"), by path ("Archive/2024"), by well-known name (inbox, deleteditems, junkemail, archive) or by id.
- **mail_create_folder** — Create an Outlook folder (at the root or under a parent). Idempotent: if a folder with the same name already exists it is returned without error. Example: { name: "Newsletters" } or { name: "2025", parent: "Invoices" }.
- **mail_search** — List messages of a folder (Inbox by default), newest first, with filters: exact sender, date range, unread only. `query` runs a full-text search (subject, body, sender) and cannot be combined with the other filters. Returns a compact summary (id, sender, subject, date, preview); use mail_get_message for the full content. To page, pass `cursor` back verbatim. For a whole-mailbox view by sender, prefer mail_senders_summary.
- **mail_get_message** — Return the full content of one message (body converted to text, recipients, attachment flag, web link) plus the unsubscribe options found in its headers (https, mailto, one-click). The body is truncated at 25,000 characters.
- **mail_senders_summary** — KEY TOOL FOR TRIAGE. Scans a whole folder (Inbox by default) and aggregates messages by sender: count, unread, latest message, and for the `top` senders the available unsubscribe method (oneClick / https / mailto). Sorted by volume. The scan is cached for the session. Follow up with mail_unsubscribe(lastMessageId) and mail_bulk_by_sender(address).
- **mail_move** — Move one or more messages (up to 500 ids) to a folder (name, path or id). Used for filing. NOTE: Outlook assigns a new id to every moved message; the `moved` result maps old id → new id. To move every message from a sender, prefer mail_bulk_by_sender.
- **mail_delete** — Delete one or more messages (up to 500 ids). By default messages go to Deleted Items (recoverable with mail_search folder=deleteditems then mail_move; their id changes). `permanent: true` deletes irreversibly: only use it when the user explicitly asks for it.
- **mail_bulk_by_sender** — Move or delete EVERY message from a sender (exact address) in a folder (Inbox by default). Use `dryRun: true` first to learn how many messages match. Deletion goes to Deleted Items unless `permanent: true`.
- **mail_unsubscribe** — Try to unsubscribe from the mailing list of a message, in order: (1) RFC 8058 one-click HTTPS POST, (2) automatic email to the List-Unsubscribe mailto address, (3) otherwise returns `method: "browser"` with the URL to open in a browser to finish manually, (4) `method: "none"` when no header exists. Deletes nothing. Preferably pass the `lastMessageId` returned by mail_senders_summary.

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

```json
"mcpServers": {
  "mail-mcp": {
    "command": "npx",
    "args": ["-y","@rixtay/mail-mcp"]
  }
}
```

## Documentation

## What Mail-MCP does

Mail-MCP exposes Outlook.com mailbox operations as MCP tools for AI assistants. It supports personal Microsoft accounts using Outlook.com, Hotmail, Live, or MSN addresses. The available operations cover folder discovery and creation, message search, full message retrieval, sender aggregation, moving messages, deletion, bulk sender actions, and unsubscribe handling. Separate login and logout tools manage the Microsoft account connection, while a purge tool handles irreversible deletion.

The server is designed for inbox cleanup and organization. It can identify high-volume senders, show unread and recent-message counts, group messages by sender, and report available unsubscribe methods. It cannot send ordinary email and does not request Microsoft permission to send mail.

## How it works

The server runs on the user's computer and communicates with Microsoft Graph for mailbox operations. Authentication opens a Microsoft sign-in flow in the browser. The author-operated service does not receive mailbox data or tokens; the documented remote endpoints are Microsoft's login and Graph hosts, plus a sender's unsubscribe endpoint when an unsubscribe action requires it.

Messages can be addressed using folder display names, paths, well-known folders such as `inbox` or `archive`, or folder IDs. Search results are compact and paginated; `mail_get_message` retrieves the full text and message details when needed. Moving a message gives it a new Outlook ID, and the move result maps each previous ID to its replacement.

For triage, `mail_senders_summary` scans a folder and groups messages by sender. The scan can cover up to 50,000 messages per call, is cached for the session, and can be limited with a date boundary. A partial scan reports lower-bound counts when a folder contains more messages than the scan limit.

## Setup and configuration

Claude Desktop users can install the downloadable `.mcpb` package from the latest release, then ask the assistant to connect Outlook. For Claude Code, Node.js 22 or newer is required:

```bash
claude mcp add --scope user --transport stdio mail -- npx -y @rixtay/mail-mcp
```

The same package can be started for other MCP clients through a standard stdio configuration using `npx -y @rixtay/mail-mcp`. If a client cannot locate `npx`, configure absolute paths to Node.js and the built server entry point. A terminal login is also available with `npx -y @rixtay/mail-mcp login`.

No app registration or configuration file is required for the normal sign-in flow. A personal Microsoft account is required; work and school accounts are not supported.

## Tools and capabilities

- List folders with total and unread message counts.
- Create root or nested folders without duplicating an existing same-named folder.
- Search by sender, date range, unread state, or full text, with pagination.
- Retrieve message text, recipients, attachment presence, web link, and detected unsubscribe options.
- Summarize senders across a folder for volume-based triage.
- Move or delete up to 500 selected messages at once.
- Move or delete all messages from an exact sender, with a dry-run count before action.
- Unsubscribe using one-click HTTPS, a `mailto` address, or a browser link when available.

## Limitations and notes

Normal deletion moves messages to Deleted Items, where they can be found and moved back; permanent deletion is handled separately and cannot be undone. Bulk sender operations act on up to 5,000 messages per call and require a non-dry-run request to perform changes. Unsubscribe does not delete messages, and suspicious or unsupported links may be blocked.

Email bodies are treated as sender-controlled data rather than instructions. Message content is truncated at 25,000 characters when returned. The server is intended for personal Outlook mailboxes and does not support work or school accounts. Node.js 22 or newer is required for the command-line setup.

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

