The mail connectors built into Claude and ChatGPT are made for big providers like Gmail. If your mail lives on your own domain, or at a host like OVH, IONOS, Gandi or Fastmail, there is no built-in option (as of November 2026). What you need is an IMAP MCP server: a Model Context Protocol server that talks IMAP and SMTP to your mailbox and exposes tools your assistant can call.
This post covers the two ways to run one, then the setup with a hosted server.
Local or hosted?
Local (open source). You install the server on your machine, put the mailbox password in a config file, and point a desktop client (Claude Desktop, Claude Code, Cursor) at it. It works, but only in apps that can launch local processes, not on claude.ai or ChatGPT on the web or your phone.
Hosted (remote). The server runs somewhere else and your assistant connects by URL. With a proper remote server you never paste a password into the assistant: the client signs in with OAuth and you approve it on a consent screen. It then works everywhere the client runs, web and mobile included.
I work on Fezola, a hosted one, so the rest uses it as the example. What it implements, for the curious:
- Transport: Streamable HTTP, stateless (each request carries its bearer token), at
https://api.fezola.com/mcp. - Auth: OAuth 2.1 authorization code with PKCE (S256), dynamic client registration, and discovery through
/.well-known/oauth-authorization-server(RFC 8414) and protected resource metadata (RFC 9728). Clients like Claude and ChatGPT register themselves, no client ID to copy. - Every tool declares
readOnlyHint/destructiveHint, so clients can ask for confirmation before anything that changes the mailbox. - Sending is off by default: the assistant writes drafts into the mailbox's Drafts folder and you send them yourself.
Which mailboxes work
- OVH (MX Plan), IONOS, Gandi: servers are prefilled, use the mailbox password.
- OVH Email Pro and other OVH offers: choose Other and enter the servers OVH gives you (for example
pro1.mail.ovh.net). - Fastmail: choose Other,
imap.fastmail.comandsmtp.fastmail.com, with an app password from Fastmail's settings. - Any other host or your own domain: Other, then the IMAP server (993 with TLS, or 143 with STARTTLS) and the SMTP server (465 or 587).
- Gmail, iCloud and Yahoo work too, each with its own sign-in.
Setup, step by step
- Gather the settings: the address, its password (or an app password if your provider requires one), and the IMAP/SMTP servers if your provider is not in the list.
- Create an account at app.fezola.com. The free plan includes 2 sources.
- Add the mailbox in Sources: pick the provider or Other, fill in the address and password, give it a short name your assistant will use (Work, Shop), then Test the connection. Both IMAP and SMTP are checked.
- Add the connector to your assistant:
- Claude: Customize → Connectors → + Add → Add custom connector, name it Fezola, URL
https://api.fezola.com/mcp. The free Claude plan allows one custom connector, which is enough since one connector carries all your mailboxes. - ChatGPT (paid plans): Settings → Apps & Connectors → Advanced settings, turn on Developer mode, then create a connector with the same URL and OAuth.
- Claude: Customize → Connectors → + Add → Add custom connector, name it Fezola, URL
- Approve access on the consent screen, which lists the sources the assistant will see.
- Ask: "Search all my mailboxes for the contract from Dupont", or "Draft a reply to my accountant's last email, from my work address". The draft lands in the mailbox that received the email, with that address as the sender.
What the assistant can do
Search and read messages and threads, read attachments (PDF, Word, text, images), list folders, create reply and forward drafts, and organize mail (mark read or unread, flag, move, archive, report spam). Results always carry the account they come from, so an answer across five mailboxes stays readable. Reading a message does not mark it as read.
FAQ
Is my mailbox password exposed to the AI? No. It is encrypted at rest on the server and never returned, not even to you. The assistant only receives the results of the tools it calls.
Does it send email? Not by default. It saves drafts; you send them from your usual mail app.
Which clients work? Claude (web, desktop, mobile), ChatGPT on paid plans with developer mode, Perplexity, and other MCP clients that support remote servers with OAuth.
The full guide, kept up to date, is here: IMAP MCP server for Claude and ChatGPT. Questions about the MCP side (OAuth, annotations, keeping it read-mostly) are welcome in the comments.
