MongoDB MCP Server
@jonfreeland
About MongoDB MCP Server
MongoDB MCP Server
Basic information
Config
No standard config provided
This server doesn't expose a parseable MCP config block in its README. See the repository for install instructions.
RepositoryTools
No tools detected
We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.
Overview
What is MongoDB MCP Server?
A Model Context Protocol server that provides read-only access to MongoDB databases through standardized MCP tools and resources, enabling AI assistants to directly query and analyze MongoDB data without write access.
How to use MongoDB MCP Server?
Build from source with npm install and npm run build, then configure the server in Claude Desktop, Claude Web (via MCP Chrome extension), or Claude Code by specifying the built index.js path and the required MONGODB_URI environment variable. Optionally set MONGODB_DEFAULT_DATABASE for a default database.
Key features of MongoDB MCP Server
- List databases and collections
- Infer collection schemas from sample documents
- Execute MongoDB queries with filtering, projection, sorting, and limiting
- Run read-only aggregation pipelines with safety validation
- Perform full-text search and geospatial queries
- Export query results as JSON or CSV formats
Use cases of MongoDB MCP Server
- Let an AI assistant explore and query a production MongoDB database safely.
- Analyze collection statistics and index usage to optimize performance.
- Retrieve sample documents or distinct values for data profiling.
- Run read-only aggregation pipelines for reporting without write risk.
FAQ from MongoDB MCP Server
What data does MongoDB MCP Server access?
It connects to any MongoDB instance specified by the MONGODB_URI environment variable and provides read-only access to databases and collections.
How is write protection enforced?
The server is designed as read-only by design, and includes safety validation that prevents write operations in aggregation pipelines.
What are the runtime requirements?
Node.js for building and running, network access to the MongoDB server, and appropriate read permissions on target databases.
How do I debug the server?
Use the MCP Inspector by running npm run inspector, which provides a URL for debugging tools.
Is authentication supported?
Yes, authentication credentials can be included in the MONGODB_URI connection string. It is recommended to use a MongoDB user with read-only permissions.
More Databases MCP servers
MCP Server for MySQL based on NodeJS
benborlaA Model Context Protocol server that provides read-only access to MySQL databases. This server enables LLMs to inspect database schemas and execute read-only queries.
mcp_mysql_server
wenb1n-devModel Context Protocol (MCP) server that supports secure interaction with MySQL databases and has anomaly analysis capabilities.更加牛逼!更加好用!不仅止于mysql的增删改查功能; 还包含了数据库异常分析能力;且便于开发者们进行个性化的工具扩展
Multi Database MCP Server
FreePeakA powerful multi-database server implementing the Model Context Protocol (MCP) to provide AI assistants with structured access to databases.
Redis MCP Server
redisThe official Redis MCP Server is a natural language interface designed for agentic applications to manage and search data in Redis efficiently
Neon MCP Server
neondatabase-labsMCP server for interacting with Neon Management API and databases
Comments