Skip to main content

WhatsApp MCP Server for macOS - Connect Claude to your WhatsApp

Project description

WhatsApp MCP for macOS

A Model Context Protocol server that connects Claude to your WhatsApp. Read messages, search contacts, send replies — all through natural conversation.

macOS MCP 1.0 MIT License

Features

  • Search contacts — Find anyone by name or phone number
  • Read messages — Get chat history with date filtering and search
  • List chats — See recent conversations with unread counts
  • Send messages — Reply directly through Claude (with QR authentication)
  • Real-time incoming — Get messages as they arrive

Requirements

  • macOS with WhatsApp desktop app installed and logged in
  • Python 3.10+
  • Node.js 18+ (for sending messages)

Installation

Using pip

pip install whatsapp-mcp-macos

From source

git clone https://github.com/kalki-kgp/whatsapp-mcp.git
cd whatsapp-mcp
pip install -e .

Claude Desktop

Add to ~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "whatsapp": {
      "command": "python",
      "args": ["-m", "whatsapp_mcp"]
    }
  }
}

Cursor

Add to .cursor/mcp.json:

{
  "mcpServers": {
    "whatsapp": {
      "command": "python",
      "args": ["-m", "whatsapp_mcp"]
    }
  }
}

Usage

Reading messages (works immediately)

Just ask Claude:

  • "Show my recent WhatsApp chats"
  • "Search for messages about dinner"
  • "What did John say yesterday?"
  • "Catch me up on unread messages"

Sending messages (requires bridge)

  1. Start the WhatsApp bridge:

    cd bridge && npm install && npm start
    
  2. Ask Claude to check connection:

    • "Check WhatsApp status"
  3. If it shows a QR code, open the data URL in a browser and scan with your phone

  4. Once connected, you can send:

    • "Send a message to Mom saying I'll be late"
    • "Reply to John with 'sounds good'"

Tools

Tool Description Requires Bridge
whatsapp_status Check connection, get QR if needed No
whatsapp_search_contacts Search contacts by name/phone No
whatsapp_list_chats List recent conversations No
whatsapp_get_messages Get messages from a chat No
whatsapp_search_messages Search across all chats No
whatsapp_unread Get unread message summary No
whatsapp_send Send a message Yes
whatsapp_incoming Get real-time incoming messages Yes

How it works

Claude ──MCP──▶ WhatsApp MCP Server
                       │
                       ├──▶ Local SQLite DBs (read messages)
                       │    ~/Library/Group Containers/group.net.whatsapp.WhatsApp.shared/
                       │
                       └──▶ WhatsApp Bridge (:3010) ──▶ WhatsApp Web
                            (for sending)

Read operations query the local WhatsApp database directly — fast and works offline.

Send operations go through the bridge, which connects to WhatsApp Web using Baileys.

Development

# Clone
git clone https://github.com/anthropics/whatsapp-mcp.git
cd whatsapp-mcp

# Install in dev mode
pip install -e ".[dev]"

# Run server
python -m whatsapp_mcp

# Run tests
pytest

Privacy

  • All data stays local — messages are read from your own WhatsApp database
  • No data is sent to external servers (except WhatsApp Web when sending)
  • The MCP server runs locally on your machine

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

whatsapp_mcp_macos-0.1.0.tar.gz (14.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

whatsapp_mcp_macos-0.1.0-py3-none-any.whl (12.3 kB view details)

Uploaded Python 3

File details

Details for the file whatsapp_mcp_macos-0.1.0.tar.gz.

File metadata

  • Download URL: whatsapp_mcp_macos-0.1.0.tar.gz
  • Upload date:
  • Size: 14.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for whatsapp_mcp_macos-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6ba1f1e2ef1d3ad6d550cc586e449c75f4eb36b3eda00a210dc7be4e976ec8d8
MD5 56d30aa11932964f27ccf259da4ccd9c
BLAKE2b-256 df5a51d9e268ebc2239f1f4877e3f6db1e3c44a68ae189cbd736140e2beb4371

See more details on using hashes here.

File details

Details for the file whatsapp_mcp_macos-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for whatsapp_mcp_macos-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b4b443d22eefa97da29150b04d0cbfa2f8cfd71664d813094c0b5b5c71db7e5d
MD5 8d641a002113c3e61f016a6fc4d604fa
BLAKE2b-256 eff2e743c4e8efee58405ef16c99b72f6773ede0794e9b6cb9fb7bc06a110941

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page