MongoDB Atlas MCP Server

MongoDB Atlas MCP Server

An MCP server that enables users to create and manage MongoDB Atlas clusters, users, and network access through natural language commands.

Category
Visit Server

README

MongoDB Atlas MCP Server

An MCP (Model Context Protocol) server for managing MongoDB Atlas projects. This package provides tools for creating and managing MongoDB Atlas clusters, users, and network access through the MCP interface.

Demo Video

MongoDB Atlas MCP Server Demo

Watch the demonstration video to see MongoDB Atlas MCP Server in action.

Features

MCP Tools

  • create_atlas_cluster - Create a new MongoDB Atlas cluster in an existing project
  • setup_atlas_network_access - Configure network access for an Atlas project
  • create_atlas_user - Create a new database user with atlasAdmin role
  • get_atlas_connection_strings - Retrieve connection strings for a cluster
  • list_atlas_projects - List all Atlas projects accessible with the provided API key
  • list_atlas_clusters - List all clusters in a specific Atlas project

Installation

npm install mcp-mongodb-atlas

Usage

As a Command Line Tool

You can run the Atlas Project Manager directly from the command line:

# Using environment variables
export ATLAS_PUBLIC_KEY="your-public-key"
export ATLAS_PRIVATE_KEY="your-private-key"
npx mcp-mongodb-atlas

# Or passing keys as arguments
npx mcp-mongodb-atlas "your-public-key" "your-private-key"

With Cline (VSCode Extension)

To use with Cline in VSCode, add the server config to your MCP settings file:

{
  "mcpServers": {
    "atlas": {
      "command": "npx",
      "args": ["mcp-mongodb-atlas"],
      "env": {
        "ATLAS_PUBLIC_KEY": "your-public-key",
        "ATLAS_PRIVATE_KEY": "your-private-key"
      },
      "disabled": false,
      "autoApprove": []
    }
  }
}

The MCP settings file is located at:

  • macOS: ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
  • Windows: %APPDATA%\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json
  • Linux: ~/.config/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json

With Cursor

To use with Cursor, go to "Cursor settings" > "MCP" in the settings and add a new server with the following configuration:

  1. Name: atlas (or any name you prefer)
  2. Command: npx mcp-mongodb-atlas
  3. Arguments: provide your API keys as arguments
## Suggested Command
npx mcp-mongodb-atlas <public_key> <private_key>

Newer versions can set the ~/.cursor/mcp.json file with:

{
  "mcpServers": {
    "atlas": {
      "command": "npx",
      "args": ["mcp-mongodb-atlas"],
      "env": {
        "ATLAS_PUBLIC_KEY": "your-public-key",
        "ATLAS_PRIVATE_KEY": "your-private-key"
      },
      "disabled": false,
      "autoApprove": []
    }
  }
}
  1. Environment Variables (Optional):
    • ATLAS_PUBLIC_KEY: Your MongoDB Atlas public key
    • ATLAS_PRIVATE_KEY: Your MongoDB Atlas private key

With Claude Desktop

To use with Claude Desktop, add the server config:

On macOS: ~/Library/Application Support/Claude/claude_desktop_config.json On Windows: %APPDATA%/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "atlas": {
      "command": "npx",
      "args": ["mcp-mongodb-atlas"],
      "env": {
        "ATLAS_PUBLIC_KEY": "your-public-key",
        "ATLAS_PRIVATE_KEY": "your-private-key"
      }
    }
  }
}

API Keys

You need MongoDB Atlas API keys to use this tool. To create API keys:

  1. Log in to your MongoDB Atlas account
  2. Go to Access Manager > API Keys
  3. Create a new API key with the appropriate permissions
  4. Save the public and private keys

Development

Clone the repository and install dependencies:

git clone https://github.com/mongodb-developer/mcp-mongodb-atlas.git
cd mcp-mongodb-atlas
npm install

Build the project:

npm run build

For development with auto-rebuild:

npm run watch

Debugging

Since MCP servers communicate over stdio, debugging can be challenging. We recommend using the MCP Inspector:

npm run inspector

The Inspector will provide a URL to access debugging tools in your browser.

License

MIT

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured