Stormproof Submit a server

MongoDB

Official

Query MongoDB databases and manage Atlas clusters.

Checks
9 of 9 passed
License
Apache License 2.0
Last commit
yesterday
GitHub stars
1.2k
Reviewed at
6900d84 · Dec 4, 2026

Install

npm · mongodb-mcp-server@latest

Needs MDB_MCP_CONNECTION_STRING.

Claude Code
claude mcp add mongodb -e MDB_MCP_CONNECTION_STRING=... -- npx -y mongodb-mcp-server@latest --readOnly
Cursor, Claude Desktop and other clients
{
  "mcpServers": {
    "mongodb": {
      "command": "npx",
      "args": [
        "-y",
        "mongodb-mcp-server@latest",
        "--readOnly"
      ],
      "env": {
        "MDB_MCP_CONNECTION_STRING": "..."
      }
    }
  }
}

Tools

18 tools and 2 resources listed by MongoDB MCP Server 3.4.0 in our sandbox on Dec 4, 2026.

  • aggregate-dbRead-onlyReaches outside

    Run an aggregation against a MongoDB database

  • aggregateRead-onlyReaches outside

    Run an aggregation against a MongoDB collection

  • collection-indexesRead-onlyReaches outside

    Describe the indexes for a collection

  • collection-schemaRead-onlyReaches outside

    Describe the schema for a collection

  • collection-storage-sizeRead-onlyReaches outside

    Gets the size of the collection

  • connectRead-onlyReaches outside

    Connect to a MongoDB instance and get back a connectionId to pass to the other MongoDB tools.

  • countRead-onlyReaches outside

    Gets the number of documents in a MongoDB collection using db.collection.count() and query as an optional filter parameter

  • db-statsRead-onlyReaches outside

    Returns statistics that reflect the use state of a single database

  • disconnectRead-onlyReaches outside

    Close a MongoDB connection and revoke its connectionId.

  • explainRead-onlyReaches outside

    Returns statistics describing the execution of the winning plan chosen by the query optimizer for the evaluated method.

  • exportRead-onlyReaches outside

    Export a query or aggregation results in the specified EJSON format.

  • findRead-onlyReaches outside

    Run a find query against a MongoDB collection

  • list-collectionsRead-onlyReaches outside

    List all collections for a given database

  • list-connectionsRead-onlyReaches outside

    List the active MongoDB connections and their connectionIds.

  • list-databasesRead-onlyReaches outside

    List all databases for a MongoDB connection

  • mongodb-logsRead-onlyReaches outside

    Returns the most recent logged mongod events

  • search-knowledgeRead-onlyReaches outside

    Search for information in the MongoDB Assistant knowledge base.

  • list-knowledge-sourcesRead-onlyReaches outside

    List available data sources in the MongoDB Assistant knowledge base.

Related MCP servers

More databases