imessage-mcp
Provides read-only access to iMessage data, allowing listing of chats, retrieving messages from specific chats, and searching messages across all chats with automatic contact name resolution.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@imessage-mcpSearch my messages for 'meeting tomorrow'"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
imessage-mcp
A read-only MCP server for macOS that exposes your iMessage data over the Model Context Protocol (MCP), with automatic contact name resolution.
Use it with Cursor, OpenAI Codex, Claude Desktop, Claude Code, or any other MCP-capable client your terminal editor supports.
Setup
1. Install
cd ~/workspace/imessage-mcp
python3.12 -m venv .venv
source .venv/bin/activate
pip install -e .2. Grant Full Disk Access
The server needs to read ~/Library/Messages/chat.db and the Contacts database. Grant Full Disk Access to the app that runs the server:
Open System Settings → Privacy & Security → Full Disk Access
For terminal-based MCP (Cursor agent, Claude Code, Codex in the terminal, etc.): add your terminal app (e.g., Terminal, iTerm2, Ghostty, Warp).
For Claude Desktop: add the Claude app itself.
3. Configure Cursor
In Cursor Settings → MCP (or your user MCP config, depending on Cursor version), register a server with the same command and args as in the Claude Code snippet below — only the host config file/path differs.
Example shape:
{
"mcpServers": {
"imessage": {
"command": "<path-to-this-repo>/.venv/bin/python",
"args": ["-m", "imessage_mcp"]
}
}
}4. Configure Claude Code
Add to ~/.claude/settings.json:
{
"mcpServers": {
"imessage": {
"command": "/Users/jaredmoskowitz/workspace/imessage-mcp/.venv/bin/python",
"args": ["-m", "imessage_mcp"]
}
}
}5. Configure Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"imessage": {
"command": "/Users/jaredmoskowitz/workspace/imessage-mcp/.venv/bin/python",
"args": ["-m", "imessage_mcp"]
}
}
}Related MCP server: imessage-rich-search
Tools
list_chats
List your iMessage chats sorted by recent activity.
limit(optional, default 50): max chats to return
get_messages
Get messages from a specific chat.
chat_id(required): chat identifier fromlist_chatslimit(optional, default 50): max messagessince(optional): ISO date string — only messages after this date
search_messages
Search all chats for messages containing a keyword.
query(required): search textlimit(optional, default 50): max results
Example Usage
"List my group chats" "Get the last 20 messages from my Business Ideas chat" "Search my messages for 'startup idea'"
Available Tools
3 toolsget_messagesA
Get messages from a specific iMessage chat.
Args: chat_id: The chat identifier (from list_chats) limit: Maximum number of messages to return (default 50) since: Only return messages after this ISO date (e.g. '2024-01-15' or '2024-01-15T10:30:00')
| Name | Required | Description | Default |
|---|---|---|---|
| chat_id | Yes | ||
| limit | No | ||
| since | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description must disclose behavior. It describes a read operation with filtering, but omits details like rate limits, permissions, or whether messages are sorted.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise with two short paragraphs: one for purpose, one for parameters. No unnecessary words or repetition.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple read tool with output schema, the description covers the key aspects: what it does and what each parameter does. Could mention sorting or pagination, but not essential.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema has 0% description coverage; the description adds crucial meaning by explaining chat_id as from list_chats, limit with its default, and since with ISO date examples.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool gets messages from a specific iMessage chat, distinguishing it from sibling search_messages by specifying the chat_id is obtained from list_chats.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage by stating chat_id comes from list_chats and provides limit/since filters, but does not explicitly compare to search_messages or advise when not to use this tool.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_chatsA
List iMessage chats sorted by most recent activity.
Args: limit: Maximum number of chats to return (default 50)
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It mentions sorting by activity but does not disclose if it requires authentication, rate limits, pagination, or that it is read-only. It adds minimal behavioral context beyond the action itself.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is extremely terse: one sentence for purpose and one for the parameter. Every sentence earns its place with no wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (one parameter, output schema available), the description covers the essential purpose and parameter semantics. It lacks mention of sorting direction but 'most recent activity' implies descending. Mostly complete for a simple list tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description explains the 'limit' parameter as 'Maximum number of chats to return (default 50)', adding meaning beyond the schema's type and default. With 0% schema coverage, this compensates adequately, though other implicit constraints are not mentioned.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states 'List iMessage chats sorted by most recent activity', using a specific verb and resource, and is differentiated from sibling tools (get_messages, search_messages) which focus on individual messages.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives like get_messages or search_messages, nor any context for selection or prerequisites.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
search_messagesB
Search all iMessage chats for messages containing the query text.
Args: query: The text to search for limit: Maximum number of results to return (default 50)
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | ||
| limit | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must disclose behavior. It only states that it searches all chats, without detailing performance, pagination, error handling, or what happens with empty queries or limits.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is very concise, with two sentences and a bullet list. It front-loads the core purpose. However, it could be more structured (e.g., separate sections) to improve readability for complex use cases.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (2 parameters, no nested objects) and the presence of an output schema, the description is mostly adequate. However, it lacks usage context and any mention of return structure, leaving some gaps for an agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, yet the description adds only minimal clarification: 'The text to search for' for query and 'Maximum number of results to return (default 50)' for limit. This adds little beyond the schema's title fields, failing to compensate for the lack of schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool searches all iMessage chats for messages containing the query text, specifying the verb 'search', resource 'iMessage chats', and scope 'all'. It distinguishes from siblings 'get_messages' (which likely retrieves specific messages) and 'list_chats'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool vs. its siblings ('get_messages', 'list_chats'), nor are there any prerequisites or exclusions mentioned. The agent is left to infer usage context without explicit direction.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
3 tool updates
v0.1.0- First observed
get_messages - First observed
list_chats - First observed
search_messages
TDQS
Each tool targets a distinct operation: listing chats, retrieving messages from a specific chat, and searching across all chats. There is no functional overlap.
All tool names follow a consistent verb_noun pattern using snake_case (list_chats, get_messages, search_messages), making the set predictable.
Three tools is appropriate for the server's scope, covering essential read operations without being too few or excessive.
The tool set provides solid coverage for reading iMessage data. A potential minor gap is the lack of a send message tool, but that may be intentional for a read-only server.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
MCP connector for iMessage & Contacts via a local Mac agent + Vercel relay
Search your AI chat history (ChatGPT, Claude, Codex) from any MCP client. Remote, private, read-only
An MCP server that provides read access to your cloud storage providers, bank accounts and more.
- QuallaaOAuthcom.quallaa
Talk to your public-facing AI from any MCP client — Claude, ChatGPT, Cursor, Cline, Windsurf.
Related MCP Servers
- AlicenseAqualityCmaintenanceA local MCP server that enables reading iMessage conversations and sending new messages through Claude Desktop. It provides secure, read-only access to your Mac's iMessage database and AppleScript-based message sending capabilities.6MIT
- AlicenseAqualityCmaintenanceEnables full-text search of macOS iMessages including link preview metadata. Works as an MCP server for Claude Desktop to search your messages locally.1MIT
- AlicenseNot gradedqualityDmaintenanceRead-only MCP server for your iMessage DB. No hosted service.MIT
- AlicenseNot gradedqualityDmaintenanceRead-only MCP server for local macOS Messages database, enabling querying of chats, messages, attachments, and metadata.975MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/jaredmoskowitz/imessage-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server