MCP Directory

How to add Instagram DM MCP to Cursor

Send, read and search Instagram DMs from your AI client: 22 tools for messages, media, threads and user lookups. Paste the config into ~/.cursor/mcp.json and restart Cursor.

Last updated June 14, 2026 · 174 · stdio · apikey

Cursor config for Instagram DM MCP

git clone https://github.com/trypeggy/instagram_dm_mcp.git && cd instagram_dm_mcp && uv sync
{
  "mcpServers": {
    "instagram-dm-mcp": {
      "command": "uv",
      "args": [
        "run",
        "--directory",
        "PATH/TO/instagram_dm_mcp",
        "python",
        "src/mcp_server.py"
      ]
    }
  }
}

Setup steps

  1. 1Open Cursor → Settings → MCP → Add new MCP server (or edit ~/.cursor/mcp.json directly).
  2. 2Paste the Instagram DM MCP config below into the "mcpServers" object.
  3. 3Fill in placeholder secrets, then save.
  4. 4Cursor reloads MCP servers automatically — check Settings → MCP for a green status dot.
  5. 5Ask Cursor to use one of Instagram DM MCP's tools to confirm it's connected.

Before you start

  • Python 3.11+
  • An Instagram account (logs in with username/password)
  • uv (recommended) or pip to install dependencies
  • Claude Desktop or Cursor as the MCP client

What Instagram DM MCP can do in Cursor

send_message

Send an Instagram DM to a user by username.

send_photo_message

Send a photo as a DM to a user by username.

send_video_message

Send a video as a DM to a user by username.

list_chats

Get DM threads from your account, with optional filters and limits.

list_messages

Get messages in a thread by thread ID, including item_type and shared post/reel info.

download_media_from_message

Download a direct-uploaded photo or video from a DM message.

download_shared_post_from_message

Download media from a shared post, reel, or clip in a DM message.

list_media_messages

List all messages containing direct-uploaded media in a thread.

Security

You hand the server your real Instagram username and password (stored in a local .env plus reused session files), and it can read and send DMs as you. This is unofficial account automation, not the Meta API — Instagram may restrict accounts that automate logins, so consider a secondary account.

Instagram DM MCP + Cursor FAQ

Where is the Cursor config file?

Cursor reads MCP servers from ~/.cursor/mcp.json. Paste the Instagram DM MCP config there under the "mcpServers" key and restart the client.

Is Instagram DM MCP safe to use with Cursor?

You hand the server your real Instagram username and password (stored in a local .env plus reused session files), and it can read and send DMs as you. This is unofficial account automation, not the Meta API — Instagram may restrict accounts that automate logins, so consider a secondary account.

Is the Instagram DM MCP safe for my main account?

Treat it as risky for a main account: it is unofficial automation that logs in with your real username and password and acts as you, and Instagram can flag automated behavior. Credentials stay local (in your .env and session files), but many users run it on a secondary account first. Session reuse at least avoids repeated logins.

Do I need a Meta developer account or Instagram API access?

No. It authenticates with a normal Instagram username and password — no developer app, access tokens, or business account required. That is also exactly why it is not an official integration.

Can it read and download messages, or only send them?

Both. list_chats, list_messages and search_threads read conversations; download_media_from_message and download_shared_post_from_message pull photos, videos and shared reels; list_pending_chats covers the request inbox. Sending supports text, photos and videos.

View repo Full Instagram DM MCP page