Connecting External Tools — MCP Integration
Connecting External Tools
MCP: The Universal Connector
The Model Context Protocol (MCP) is an open standard that connects Cursor's AI agents to external tools, databases, and services. Think of it as USB for AI - build an MCP server once, connect it to any AI client.
How MCP Works in Cursor
- Cursor acts as the MCP Client
- MCP Servers expose tools, resources, and prompts
- When an agent needs data, it calls an MCP tool
- The server executes the request and returns results to the agent
Configuration
| Scope | Location | Use Case |
|---|---|---|
| Global | ~/.cursor/mcp.json | Tools available in all projects |
| Project | .cursor/mcp.json | Project-specific databases, APIs |
// .cursor/mcp.json example
{
"mcpServers": {
"postgres": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-postgres"],
"env": { "DATABASE_URL": "postgresql://..." }
}
}
}
Popular MCP Servers
- Filesystem: Read/write files outside the project
- PostgreSQL/MySQL: Query databases directly from the AI
- GitHub: Create PRs, manage issues, review code
- Notion/Slack: Read docs, send notifications
- Brave Search: Web search from within the editor
MCP Transports & Enterprise Governance
Local servers speak JSON-RPC over stdio (with env and envFile support); remote servers use modern Streamable HTTP or legacy SSE (Server-Sent Events) with dynamic browser OAuth authentication or ${env:TOKEN} headers - and Cloud Agents support all of them. To protect the model's context window, Cursor enforces a hard global cap of 40 active tools across all connected MCP servers (excess tools are silently dropped, so enable only what your workflow needs). On Team plans, admins distribute vetted MCP servers via the team marketplace (Cursor 3.10+), and Bugbot can call MCP tools during reviews on Team/Enterprise plans.
Give Cursor's agent real tools. Create the project-level MCP config, then smoke-test a reference server with npx before Cursor launches it.