cursor mcp
Facilitates integration with the Cursor code editor by enabling real-time code indexing, analysis, and bi-directional communication with Claude, supporting concurrent sessions and automatic reconnection.
Facilitates integration with the Cursor code editor by enabling real-time code indexing, analysis, and bi-directional communication with Claude, supporting concurrent sessions and automatic reconnection.
A Model Context Protocol (MCP) implementation that enables seamless integration between Claude AI and desktop applications through Cursor IDE. This tool serves as a bridge between Claude's capabilities and desktop software, allowing for enhanced AI-powered development workflows.
To install Cursor for Claude Desktop automatically via Smithery:
npx -y @smithery/cli install cursor-mcp-tool --client claude
Windows 10 or higher
Installation
# Install globally
npm install -g mcp-cursor
# Or install locally
git clone https://github.com/yourusername/cursor-mcp.git
cd cursor-mcp
npm install
Configuration
Create a .env
file in your project root:
# Windows path example
DEFAULT_WORKSPACE_PATH=C:/Users/YourUsername/Documents/cursor-workspaces
Add to Claude's MCP Configuration Add the following to your Claude configuration:
{
"name": "cursor",
"type": "mcp",
"config": {
"server": "https://glama.ai/mcp/servers/4fg1gxbcex",
"capabilities": ["cursor_control", "window_management"]
}
}
Start the Server
# If installed globally
mcp-cursor
# If installed locally
npm start
Clone and install:
git clone https://github.com/yourusername/cursor-mcp.git
cd cursor-mcp
npm install
Create environment config:
cp .env.example .env
Edit .env
and set your workspace path:
DEFAULT_WORKSPACE_PATH=C:/Users/YourUsername/Documents/cursor-workspaces
Build and run:
# Development mode with hot reload
npm run dev
# Production mode
npm run build
npm start
Check if your workspace path is correct
Permission Issues
Ensure proper file permissions in workspace directory
Node Version Issues
nvm
to switch to Node.js v18 or higher:
nvm install 18
nvm use 18
cursor-mcp/
├── src/ # Source code
│ ├── services/ # Core services
│ ├── handlers/ # Event handlers
│ └── types/ # TypeScript definitions
├── build/ # Compiled JavaScript
└── .env # Environment configuration
npm run build
- Compile TypeScriptnpm start
- Run production servernpm run dev
- Start development server with hot-reloadgit checkout -b feature/amazing-feature
)git commit -m 'Add feature'
)git push origin feature/amazing-feature
)MIT License - see LICENSE file for details.
For support: - Open an issue in the GitHub repository - Join our Discord community - Check the FAQ
[
{
"description": "Get weather alerts for a state",
"inputSchema": {
"properties": {
"state": {
"description": "Two-letter state code (e.g. CA, NY)",
"type": "string"
}
},
"required": [
"state"
],
"type": "object"
},
"name": "get-alerts"
},
{
"description": "Get weather forecast for a location",
"inputSchema": {
"properties": {
"latitude": {
"description": "Latitude of the location",
"type": "number"
},
"longitude": {
"description": "Longitude of the location",
"type": "number"
}
},
"required": [
"latitude",
"longitude"
],
"type": "object"
},
"name": "get-forecast"
}
]