Models

How to Configure Model Context Protocol Servers in Cursor

How to Configure Model Context Protocol Servers in Cursor

The Model Context Protocol is an open standard originally published by Anthropic that defines how an AI agent talks to external tools and data sources. Cursor adopted it as the backbone for connecting its agent to anything outside the local file tree. Tech Insider reports that searches for cursor mcp servers pull approximately 720 monthly queries in the US. While Cursor is not built on MCP, it has added native MCP support, allowing developers to connect MCP-compatible servers to the Cursor IDE.

Cursor exposes MCP configuration in two layers. There is a GUI at Settings → MCP that lists connected servers and lets you toggle them on or off per session, underneath that sits plain JSON configuration that you can edit directly or check into version control. Users can configure Cursor MCP settings using the mcp.json file located at ~/.cursor/mcp.json. Cursor reads MCP servers from ~/.cursor/mcp.json for entries available in every project, while a .cursor/mcp.json file inside a repository adds servers for that project only. Global configuration registers tools directly within Cursor’s general settings. Hacker News reports that their Cursor setup connects to 22 MCP servers when it starts, with ten coming from entries in ~/.cursor/mcp.json and the other twelve arriving through eight plugins installed from the Cursor Marketplace.

Communication mechanisms vary depending on whether the server runs locally or remotely. A local server is a command Cursor starts for you, and the two talk over stdin and stdout, while a remote server is a URL. For local commands, Cursor resolves ${env:NAME} from your shell environment, so the token itself never has to sit in the file.

Plugins offer an alternative distribution method by bundling skills, subagents, and MCP servers. A Cursor plugin bundles skills, subagents and MCP servers, and installs from the Marketplace in one click, with an OAuth login when the service needs one. For instance, Bright Data provides a Web MCP integration for the editor featuring 69 tools, giving Cursor the ability to perform live web searches, extract structured data, consume dynamic data feeds, and automate browser interactions, with a one-click path through the Cursor Marketplace. Similarly, community built packages such as the Apple Music MCP server connect directly to macOS Music.app via local AppleScript and native CoreAudio timing, exposing 74 tools to Cursor Agent and Composer, importing public Spotify playlists without logging in, adjusting per-speaker AirPlay volumes, and running background DJ transitions.

Standard developer tool servers provide specific capabilities across different domains. The GitHub MCP server enables Cursor to interact directly with GitHub repositories, read and analyze code, create and update pull requests, review code changes, and manage issues. The Filesystem MCP server provides structured access to the local file system, allowing Cursor to read and write files, traverse directories, and manage project structure. The PostgreSQL MCP server connects Cursor to PostgreSQL databases, allowing Cursor to run SQL queries, inspect schemas, and fetch and update data. Additional integrations include the REST API MCP server which allows Cursor to interact with external APIs, send HTTP requests, fetch external data, and trigger backend services. The Terminal / Shell MCP server gives Cursor the ability to execute shell commands, run scripts, execute CLI commands, and trigger builds/tests. The Slack MCP server enables interaction with Slack workspaces, allowing Cursor to send messages, notify teams, and trigger alerts. The Notion MCP server connects Cursor with Notion workspaces, allowing Cursor to read/write docs, update internal documentation, and sync knowledge. The Web Browser MCP server allows Cursor to access and interact with web content, fetch web pages, extract information, and perform web-based actions.

To set up a testing tool such as Playwright, developers can follow a specific installation and validation workflow. Open the Cursor and run npm install @playwright/mcp --save-dev in the Cursor’s terminal. The --save-dev flag adds Playwright MCP as a development dependency, since it is only needed during local testing and AI-assisted development, not in production builds. For project-level setup, create a file named mcp.json inside the .cursor folder. Alternatively, for GUI-based setup, open Cursor Settings, navigate to Tools & MCP tab, and add a New Server by clicking “Add Custom MCP”, then paste the JSON payload straight into the box. The configuration uses npx with args for @playwright/mcp@latest. Go to Tools & MCP, confirm that Playwright MCP appears in the list, and validate the connection by running a full login flow on app.cms.testdino.com with screenshots and logout using the Cursor chat panel.

Sources

Explore more Models coverage.