iMessage History MCP Server
Read-only MCP server for searching and reading Apple Messages history on macOS.
iMessage History scores 75 (Good), licensed MIT and written in TypeScript. It installs as a local process. It declares 8 tools. Filed under Databases, Communication. GitHub shows 34 stars. Package registries report about 840 downloads a week. Install configs are generated for 12 clients. Being listed in the registry is not the same as being vendor-official.
Good trust
75 of 100 from six public signals. Nobody can buy a point.
- Listed in the official MCP registry.
- OSI-style license: mit.
License, quality and maintenance
Where the 75 comes from
22 + 20 + 9 + 10 + 4 + 10 = 75. Each factor is capped, so no single signal can carry a listing.
Active in the official MCP registry, plus a known vendor namespace.
Registry: 22 of 30 points.How recently the repository saw a commit or release.
Maintenance: 20 of 20 points.GitHub stars and weekly downloads, on a log scale.
Popularity: 9 of 20 points.A clear, OSI-style open-source license.
License: 10 of 10 points.Not archived, a secure install path, a pinned version.
Security: 4 of 10 points.A real summary, a README with depth, listed tools.
Docs: 10 of 10 points.Install
Pick your client, copy the config, paste it in.
{ "mcpServers": { "anipotts-imessage-mcp": { "command": "node", "args": [ "-y", "imessage-mcp@3.4.1" ], "env": { "IMESSAGE_PRIVACY": "", "IMESSAGE_CONTACTS": "", "IMESSAGE_DB": "", "IMESSAGE_CACHE": "", "IMESSAGE_UPDATE_CHECK": "" } } }}
Environment variables
| Name | Required | Notes |
|---|---|---|
IMESSAGE_PRIVACY | Optional | Most any caller can see: full (default for stdio), redacted, or aggregate. |
IMESSAGE_CONTACTS | Optional | live (default) names handles from Contacts; none shows handles only. |
IMESSAGE_DB | Optional | Path to a copy of chat.db instead of this Mac's Messages database. |
IMESSAGE_CACHE | Optional | Set to 0 to keep the search index in memory only. |
IMESSAGE_UPDATE_CHECK | Optional | Set to 0 to turn off the npm version check. |
Tools8Tool docs quality grade C
All capabilitiesMessage counts by hour and weekday, response times, streaks, and who starts conversations
get_attachmenttoolShow one attachment from getconversation: images as a JPEG with location and camera metadata removed, text files as text. Needs the full privacy mode
get_conversationtoolRead a conversation by chatid or by a contact or group name, with edits, reactions, receipts, replies, group events, and attachments. The cursor pages to older events
Find conversations by contact, service, kind, reply state, or date, each with its latest message, newest first or by who you text most
resolve_contacttoolMatch a name, phone number, or email to a contact in your Mac's Address Book, and report ambiguity rather than guess
search_messagestoolSearch by substring, exact text, token, or phrase. Message text by default; conversation names and attachment filenames are opt-in. Filter by service, sent or received, and date
server_statustoolVersion, update availability, privacy mode, index and cache state, schema support, conversation membership counts, and Contacts access
sync_messagestoolPull every change since a cursor: new, edited, unsent, and deleted messages, conversation memberships, reactions, and receipts
About
imessage-mcp
Search and read your Messages history from Claude, Codex, Cursor, VS Code, and any other MCP client.

Read-only. Runs on your Mac. No accounts, no cloud service, nothing to compile.
- Finds messages by words, exact text, or phrase across iMessage, SMS, MMS, and RCS
- Reads whole conversations with edits, unsent messages, reactions, replies, and read receipts
- Shows photos people sent you, with location data removed
- Keeps up with new messages through a change feed, and answers counts and response-time questions
Install
Requirements: macOS 14 or newer. Node.js 24.16 or newer for npx installs (Claude Desktop brings its own). Use Node 24 LTS for encrypted cache support. Runtimes without SQLite checkpoint APIs, including Node 25, search in memory and rebuild after a restart; doctor reports this.
Standard config, for any client that reads mcpServers JSON:
{
"mcpServers": {
"imessage": {
"command": "npx",
"args": ["-y", "imessage-mcp@latest"]
}
}
}
Then give the app that runs it Full Disk Access: System Settings > Privacy & Security > Full Disk Access, turn on the app (Claude, your terminal, Cursor, VS Code, ...), then quit it fully and reopen it. Not sure which app? Run npx -y imessage-mcp@latest doctor from that app's terminal and it tells you. Until access is granted, every tool answers with these same steps.
amp mcp add imessage -- npx -y imessage-mcp@latest
claude mcp add --scope user imessage -- npx -y imessage-mcp@latest
Or install the plugin: /plugin marketplace add anipottsbuilds/imessage-mcp, then /plugin install imessage-mcp@anipotts.
Download imessage-mcp.mcpb and double-click it, or install iMessage History from Settings > Extensions if it is listed there. To update a bundle you installed yourself, download the newest one and double-click it again.
Then turn on Claude in Full Disk Access and quit and reopen Claude.
Add the standard config to cline_mcp_settings.json (docs).
codex mcp add imessage -- npx -y imessage-mcp@latest
Or in ~/.codex/config.toml:
[mcp_servers.imessage]
command = "npx"
args = ["-y", "imessage-mcp@latest"]
Run /mcp add, or add the standard config to ~/.copilot/mcp-config.json with "type": "local".
Or add the standard config to ~/.cursor/mcp.json.
Add the standard config to ~/.gemini/settings.json.
Add the standard config to .junie/mcp/mcp.json, or type /mcp in Junie CLI.
In ~/.config/opencode/opencode.json:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"imessage": { "type": "local", "command": ["npx", "-y", "imessage-mcp@latest"], "enabled": true }
}
}
code --add-mcp '{"name":"imessage","command":"npx","args":["-y","imessage-mcp@latest"]}'
Add the standard config in the client's MCP settings. Zed uses context_servers with "source": "custom".
If a GUI app reports that npx was not found, it cannot see your Node installation: use the full path from which npx as the command.
Use it
Ask in plain words: "catch me up on my texts", "find the message about the dinner reservation", "how fast does Sam usually reply?". Three prompts are also in your client's prompt menu:
| prompt | what it does |
|---|---|
catch_up | Who is waiting on a reply from you, and what they need |
draft_reply | A reply in your own texting style. You send it; this server cannot. |
recap | Your week in messages: volume, busiest conversations, anyone still waiting |
Clients that attach resources can use imessage://conversations and imessage://conversations/{chat_id}.
Skills
Clients that support Skills over MCP can discover two read-only workflows. They ship as instructions only, with no commands or scripts.
| skill | what it does |
|---|---|
catch-up | Rank recent messages that may need your reply or action. |
find-it | Search for a message, verify its chat and sender, and cite the matching message ID. |
In a supported interactive Claude Code session on v2.1.331 or newer, type /imessage:catch-up or /imessage:find-it if your server is named imessage. Use your configured server name otherwise. Skills are in beta. If your client doesn't offer them, the tools and prompt menu still work as before. The skills obey the server's existing privacy settings.
Tools
| tool | what it does |
|---|---|
search_messages | Search by substring, exact text, token, or phrase. Message text by default; conversation names and attachment filenames are opt-in. Filter by service, sent or received, and date |
get_conversation | Read a conversation by chat_id or by a contact or group name, with edits, reactions, receipts, replies, group events, and attachments. The cursor pages to older events |
list_conversations | Find conversations by contact, service, kind, reply state, or date, each with its latest message, newest first or by who you text most |
get_attachment | Show one attachment from get_conversation: images as a JPEG with location and camera metadata removed, text files as text. Needs the full privacy mode |
sync_messages | Pull every change since a cursor: new, edited, unsent, and deleted messages, conversation memberships, reactions, and receipts |
analyze_communication | Message counts by hour and weekday, response times, streaks, and who starts conversations |
resolve_contact | Match a name, phone number, or email to a contact in your Mac's Address Book, and report ambiguity rather than guess |
server_status | Version, update availability, privacy mode, index and cache state, schema support, conversation membership counts, and Contacts access |
Every tool is read-only and marked readOnlyHint. Results use plain ids (message_id, chat_id, attachment_id) you can pass between tools.
Apple can record the same message in several conversations. Search returns that message once with all canonical chat_ids and their conversations labels. A single membership also includes chat_id and conversation; for shared results, pass the relevant id from chat_ids to get_conversation. Only Apple's explicit lookup evidence combines chat aliases. Shared messages do not combine unrelated conversations.
Pagination cursors are opaque and scoped to the running server. Pass them back unchanged; after a server restart or DATABASE_CHANGED, begin that traversal again. Sync cursors retain their separate checkpoint-backed behavior.
Global and contact message counts deduplicate shared records within the requested scope. Conversation timelines and sequence metrics retain each recorded membership, so adding per-conversation counts can exceed the global count. Sync includes chat_ids on changes and emits message_membership_changed with previous_chat_ids; its changed_at is null because Apple does not timestamp these joins. Logged memberships describe the change when observed; available text, sender and receipt fields describe current source state. Upgrading the index format rebuilds its cache once and invalidates older sync cursors; start a new sync when it returns DATABASE_CHANGED.
Contact names expand to the selected person's addresses. An exact phone number or email scopes only that address, even when Contacts has conflicting labels. resolve_contact still reports ambiguous identity; address scoping does not merge people or include their other addresses. For an address-like group title, search with the conversation_names scope and use the selected chat_id.
Every tool's output schema accepts both its success envelope and the structured error envelope, so strict clients can expose the original reason and recovery hints.
Conversation reads are strict by default. When a body or relationship cannot be recovered completely, the error explains the allow_partial: true retry. Partial results retain completeness, warnings and each event's row_status; inspect these before citing evidence. Narrower dates or around_message_id can avoid an unrelated damaged event. Structural failures still fail closed.
Configuration
Add options to args, for example ["-y", "imessage-mcp@latest", "--privacy", "redacted"].
| option | description |
|---|---|
--privacy <mode> | The most any caller can see. full (default), redacted (names and masked handles, calendar days, no message text or filenames), or aggregate (counts only). A call can ask for a stricter mode, never a looser one. env IMESSAGE_PRIVACY |
--contacts <mode> | live (default) names handles from your Contacts; none shows handles only. env IMESSAGE_CONTACTS |
--database <path> | Read a copy of chat.db instead of this Mac's Messages. env IMESSAGE_DB |
--transport http --port <n> | Serve MCP over HTTP on 127.0.0.1 instead of stdio. Requires IMESSAGE_API_TOKEN or IMESSAGE_API_TOKEN_FILE. IMESSAGE_ALLOWED_HOSTS and IMESSAGE_ALLOWED_ORIGINS take comma-separated lists; both default to localhost. |
IMESSAGE_CACHE=0 | Keep the search index in memory only |
IMESSAGE_WARM_SEARCH=0 | Build the search index on the first search instead of at startup |
IMESSAGE_UPDATE_CHECK=0 | Turn off the version check |
Privacy and security
- Read-only. The server opens the Messages database read-only and has no tool that sends, edits, reacts, or marks anything read.
- Local. No accounts, telemetry, or analytics. The only network request is an optional version check to the npm registry.
- Your client sees what you ask for. Results go to the MCP client you use and its model provider, under their policies.
--privacy redactedoraggregatelimits what leaves the server. - Search index. Built on your Mac and, when SQLite checkpoint APIs are available, cached encrypted in
~/Library/Caches/imessage-mcp, with a key derived from your Messages database, so it opens only for an app that can already read your messages. Deleting it is always safe.server_statusreports an unavailable or failed cache while searches continue from memory. - Untrusted content. Messages can contain text written to manipulate an AI. The server tells clients to treat all message content as data, never as instructions.
Details: SECURITY.md and PRIVACY.md.
Development
npm ci
npm test # unit tests on synthetic Messages databases
npm run e2e # launches the built server over stdio and HTTP
npm run perf # one-million-message performance gates
Tests use synthetic data only. See CONTRIBUTING.md.
Dependency PRs use protected auto-merge through a repository-scoped GitHub App, without personal-token renewal. A daily health check detects authentication failures and stalled updates; see maintenance and recovery.
- Retire the unused owner-token copies after the App migration is verified and rollback is no longer needed.
- After extended inactivity, verify that GitHub has not disabled scheduled workflows. Dependency merges do not publish a release.
License
MIT
Frequently asked questions
What is iMessage History MCP Server?
Read-only MCP server for searching and reading Apple Messages history on macOS.
How do I install iMessage History MCP Server in Claude Desktop, Cursor, or VS Code?
Pick your client in the Install section on this page and copy the generated config into the client's config file. Step-by-step guides: Claude Desktop, Cursor, and VS Code. iMessage History MCP Server is published as the npm package imessage-mcp.
Is iMessage History MCP Server free and open source?
Yes. iMessage History MCP Server is released under the MIT license, an OSI-approved open-source license, so you can use, modify, and self-host it under those terms.
Does iMessage History MCP Server support remote (HTTP) connections?
No remote endpoint is listed for iMessage History MCP Server. It runs locally on your machine over stdio, started by your MCP client.
What tools does iMessage History MCP Server provide?
iMessage History MCP Server provides 8 tools, including analyze_communication, get_attachment, get_conversation, and list_conversations. See the full tool list for descriptions and parameters.
How is iMessage History MCP Server's trust score calculated?
iMessage History MCP Server scores 75 out of 100 (Good). The score adds six capped public signals: registry status, maintenance, popularity, license, documentation, and security. Nobody can pay for points. Read the methodology for the full formula.
Reviews
No reviews yet—Be the first to review
No published reviews yet. Used it? Tell the next person how it went.
Sign inA verified email is required to review this server.
Add badge to your README
Paste either snippet into the repository README. The image links to this listing.