IMAP mailbox logo

IMAP mailbox

Read, search, organize, and draft mail in any IMAP mailbox through MCP, with read-only access enabled by default.

Install IMAP mailbox

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "imap-mailbox": {
      "command": "npx",
      "args": [
        "-y",
        "@ni-c/imap-mcp"
      ],
      "env": {
        "IMAP_HOST": "YOUR_VALUE_HERE",
        "IMAP_USER": "YOUR_VALUE_HERE",
        "IMAP_PASSWORD": "YOUR_VALUE_HERE"
      }
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Values are written into the snippet above so you can paste it as is. They never leave your browser.

Automated check passed— started and listed 6 tools correctly (Today).

Overview

The IMAP mailbox MCP server connects MCP clients to any IMAP account over IMAP and provides tools for reading, searching, organizing, and drafting mail. It supports mailbox and message discovery, attachment handling, folder operations, and configurable new-message tracking. Read-only access is enabled by default, while destructive actions require explicit approval or a confirmation token. Reach for it when an agent needs mailbox access without the ability to send email.

Use cases

  • Search an IMAP inbox by sender, subject, body, or date
  • Review new messages without changing the human Seen state
  • Extract or save email attachments
  • Organize messages into folders with approval controls
  • Prepare replies as drafts without sending mail

Key features

  • IMAP mailbox access over MCP
  • Read-only mode enabled by default
  • Message search and security assessment
  • Attachment retrieval and saving
  • Folder and message organization
  • Draft creation without sending

Tools6

What IMAP mailbox lets your agent do. Expand a tool for its parameters.

Verified live~1.6k tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked 3d ago

Recent health check succeeded.

7/7 checks healthy over the last 45d

What it can do

From the 6 tools this server returned when we ran it; 6 declare their own safety hints.

Makes network requests · 1Read-only tools · 6
Network at startup3 connections
Files written at startupNone
Install scriptsNone
npm provenanceSigned build
Package age58 days
Maintainers1

Observed 2026-10-28 in an isolated sandbox. A description of reach, not a security audit.

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 11h ago via OSV.dev · @ni-c/imap-mcp (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars3Stargazers on the source repository.
npm downloads1.3kPackage downloads in the last 30 days.
Last commit6d agoMost recent push to the default branch.
Availability100%Our rolling endpoint + install checks that succeeded.
Install checkPassedOur sandbox started it and listed its tools.
Tools exposed6Callable tools this server registers over MCP.

How IMAP mailbox works

What the IMAP mailbox MCP server does

The IMAP mailbox MCP server gives an MCP client access to an IMAP account without depending on a provider-specific API. It can inspect folders, search messages, read headers and bodies, retrieve attachments, update reversible flags, move or copy messages, manage folders, and save drafts. It cannot send mail; a saved draft remains in the mailbox for a person to review and send through a normal mail client.

Message content is handled as untrusted input. Bodies are fenced with per-call markers, and the server adds a security assessment covering authentication-result claims, possible prompt-injection patterns, and mixed-script text. It also removes some hidden or potentially tracking-oriented content before returning data. Folder names receive similar handling, with the original path retained for tool operations and a cleaned display form provided for reading.

How it works

The server communicates with the mailbox using IMAP over a TLS-capable connection and exposes a compact set of grouped tools. get_server_info reports available capabilities and server flags. Listing tools cover folders, message searches, and messages not previously handed over. The new-message workflow uses an IMAP keyword, AiSeen by default, rather than changing the human-readable \\Seen state.

Write-related operations are disabled unless configuration enables them. The default configuration registers read tools only, so unavailable operations are not exposed to the client. Moving, deleting messages, and deleting folders use MCP elicitation where the client supports it. Otherwise, the server uses a two-call confirmation token; disabling elicitation does not remove that guard.

Setup and configuration

The IMAP mailbox MCP server requires Node.js 22 or newer and an IMAP account. Set IMAP_HOST, IMAP_USER, and IMAP_PASSWORD; accounts protected by two-factor authentication may require an app-specific password. The default port is selected from the TLS mode, which defaults to implicit TLS. IMAP_MAILBOX sets the default folder for message tools.

Keep IMAP_READ_ONLY at its default value of true for read-only operation. Setting it exactly to false enables the mailbox write group. IMAP_ALLOW_TOOLS can restrict registration to named tools, list_* groups, or the essential set, while IMAP_DENY_TOOLS removes entries from the allowed set. IMAP_SEEN_KEYWORD controls new-message tracking, and IMAP_TRUSTED_AUTHSERV_ID identifies the provider-authenticated source for SPF, DKIM, and DMARC results.

Tools and capabilities

The available tools cover:

  • Server capability and flag inspection
  • Folder listing with counts and special-use roles
  • Message listing and filtering by participants, subject, body, dates, and flags
  • One-time new-message retrieval with preview support
  • Message reading with optional thread information
  • Attachment listing, reading, extraction, and saving
  • Reversible flag updates without allowing \\Deleted
  • Message moving and copying
  • Protected message and mailbox deletion
  • Mailbox creation and protected renaming
  • Draft creation without sending

Limitations and notes

The IMAP mailbox MCP server does not send messages, and save_draft does not leave the mailbox. Provider behavior can affect supported flags, keyword storage, authentication headers, and folder operations. Authentication results are treated as forgeable unless a trusted authserv ID is configured. Client support for interactive elicitation also varies, so destructive operations may use token confirmation instead of a dialog.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about IMAP mailbox

IMAP mailbox is an MCP server that connects MCP clients to any IMAP account over IMAP. Its main tools list folders and messages, search and read mail, retrieve attachments, organize messages, and save drafts. It cannot send email, and mailbox write tools are disabled by default until explicitly enabled.

Install and run it in an environment with Node.js 22 or newer, then provide an IMAP account. The supplied configuration requires IMAP_HOST, IMAP_USER, and IMAP_PASSWORD; providers using two-factor authentication may require an app-specific password.

Set IMAP_READ_ONLY=false to register the mailbox write tools. The default is true, so only read tools are registered initially. You can further limit or remove registered tools with IMAP_ALLOW_TOOLS and IMAP_DENY_TOOLS.

No, it cannot send email. Its save_draft tool writes a draft into the mailbox, and a person must use a separate mail client to review and send it.

Yes. The README names Claude Desktop as a supported MCP client. It also names Claude Code and Codex, and the server communicates with clients over MCP.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewIMAP mailbox AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/imap-mailbox?style=directory)](https://allmcps.com/mcp/imap-mailbox)
HTML Embed
<a href="https://allmcps.com/mcp/imap-mailbox"><img src="https://allmcps.com/api/badge/imap-mailbox?style=directory" alt="IMAP mailbox on AllMCPs" /></a>