# Outlook Mailbox Tidier [Health: Active]

**Category:** 💬 Communication  
**Repository:** https://github.com/ma2no4413/outlook-mcp  
**GitHub Stars:** 0  
**Views:** 0  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/outlook-mailbox-tidier

## Description
Tidy a large Outlook / Hotmail mailbox. Folder subtree moves, bulk ops with dry run, never sends.

## Tools
Capabilities this server exposes over MCP:

- **check_config** — diagnose configuration, auth and connectivity
- **list_folders** — folder tree with item and unread counts
- **search_messages** — search by keyword, sender, date range, unread, folder
- **get_message** — one message body and recipients
- **list_rules** — existing inbox rules
- **create_draft** — compose a draft — **never sent
- **draft_reply** — draft a reply or reply-all — **never sent
- **create_folder** — create a folder
- **rename_folder** — rename a folder, contents untouched
- **move_folder** — move a folder under a new parent, subtree included
- **move_messages** — move up to 25 messages
- **move_by_search** — move everything matching a query, up to 2,000
- **mark_messages_read** — toggle read/unread, up to 25
- **mark_read_by_search** — mark everything matching a query, up to 25,000 — **not reversible
- **archive_messages** — move to Archive
- **create_rule** — create a server-side inbox rule
- **move_to_trash** — move to Deleted Items (recoverable)
- **delete_folder** — delete a folder (`force` required if not empty)
- **delete_rule** — delete an inbox rule (messages untouched)

## Claude Desktop Quick Installation
No generated config for this server: it installs through its own setup steps.

The project's own setup steps (from https://github.com/ma2no4413/outlook-mcp), copied verbatim. Follow them in order; they are not an mcpServers config.

1. Install:

```sh
docker build -t outlook-mcp .
```

2. Sign in:

```sh
docker run -it --rm -e OUTLOOK_CLIENT_ID=<your-id> \
  -v outlook-mcp-token:/app/data -e OUTLOOK_TOKEN_CACHE=/app/data/token_cache.json \
  outlook-mcp python login.py
```

3. Start the server:

```sh
docker run -i --rm -e OUTLOOK_CLIENT_ID=<your-id> \
  -v outlook-mcp-token:/app/data -e OUTLOOK_TOKEN_CACHE=/app/data/token_cache.json \
  outlook-mcp
```

## Documentation

## What Outlook Mailbox Tidier MCP server does

Outlook Mailbox Tidier MCP server gives an MCP client tools for organizing a Microsoft Outlook or Hotmail mailbox. It works with personal Outlook.com accounts as well as work and school accounts through the Microsoft Graph API. The toolset covers mailbox inspection, message search, folder management, inbox rules, bulk cleanup, and draft composition.

The server does not provide a send operation and does not request the Microsoft Graph `Mail.Send` permission. Drafted messages and replies remain in Drafts for a person to review and send. Deletion is also limited: messages can be moved to Deleted Items, where they remain recoverable, but permanent deletion is not implemented. Attachments are not supported; their presence is shown when applicable.

## How it works

Read tools can diagnose configuration and connectivity, show the folder hierarchy with item and unread counts, search messages, retrieve an individual message, and inspect existing inbox rules. Search criteria include keywords, sender, date range, unread status, and folder.

Write tools can create, rename, move, and delete folders; move messages; archive mail; change read status; manage inbox rules; and place messages in Deleted Items. Moving a folder moves its complete subtree rather than requiring each message to be handled separately. Server-side rules continue to operate in Outlook even when the MCP server is not running.

Bulk operations have bounded scopes. Moving by search handles up to 2,000 messages, while marking messages read by search handles up to 25,000. Individual message moves and read-status changes accept up to 25 messages. The search-based move and read-status operations default to a dry run that reports the matching count before changes are made. Marking messages read is not reversible through the tool.

## Setup and configuration

The project requires Python 3.10 or later, a Microsoft account, and an MCP client. Setup begins with registering an application in Azure and supplying its application (client) ID. The account owner must complete browser sign-in and consent because device-code authentication requires a person to use a browser.

After the Azure application is registered, the repository instructions describe creating a virtual environment, installing dependencies, writing the environment configuration, registering the MCP server, and checking the connection. Authentication is completed by running `login.py`. The server can also run in Docker, with the token cache stored in a named volume rather than inside the image.

The `OUTLOOK_CLIENT_ID` environment variable identifies the registered Azure application. `OUTLOOK_TOKEN_CACHE` can select the token-cache path when running in Docker. `OUTLOOK_READONLY=true` disables all write tools, allowing an agent to inspect the mailbox without changing it.

## Tools and capabilities

The Outlook Mailbox Tidier MCP server exposes these groups of tools:

- Diagnostics and inspection: `check_config`, `list_folders`, `search_messages`, `get_message`, and `list_rules`.
- Drafting: `create_draft` and `draft_reply`, including reply-all drafts; neither sends mail.
- Folder organization: `create_folder`, `rename_folder`, `move_folder`, and `delete_folder`.
- Message organization: `move_messages`, `move_by_search`, `archive_messages`, `mark_messages_read`, and `mark_read_by_search`.
- Rule and discard management: `create_rule`, `delete_rule`, and `move_to_trash`.

Folder deletion requires `force` when the folder is not empty. Deleting an inbox rule does not alter the messages it previously affected. The delegated permissions requested are `Mail.ReadWrite` and `MailboxSettings.ReadWrite`, with the latter used for inbox rules.

## Limitations and notes

This server is focused on mailbox cleanup rather than the broader Microsoft 365 product surface. It does not expose calendar, contacts, Teams, attachment handling, message sending, or permanent deletion tools. Keep the token cache protected because it grants access to the mailbox. Review dry-run counts and destructive operations carefully, especially bulk read-status changes and folder deletion.

_Full upstream README: https://allmcps.com/mcp/outlook-mailbox-tidier/readme_

