Cursor Integration
Overview
Cursor is an AI-first code editor that combines the power of large language models with a modern development environment. The MCP Gearbox CLI provides seamless integration with Cursor, enabling you to easily configure and manage Model Context Protocol (MCP) servers for use with Cursor.
Key Features
- Direct Integration: Configure MCP servers specifically for Cursor
- Global Configuration: Set up MCP servers for Cursor across your entire system
- Project-Specific Setup: Configure MCP servers for individual projects using Cursor
- Cross-Platform Support: Works on Windows, macOS, and Linux
Prerequisites
Before configuring MCP servers for Cursor, ensure you have:
- Installed Cursor application
- Set up your Cursor account and AI model preferences
- Installed the MCP Gearbox CLI
Configuration
Global Configuration
To configure MCP servers for Cursor globally:
mcp init -a cursor
This command will:
- Detect your Cursor installation
- Present an interactive menu of available MCP servers
- Generate the appropriate configuration files for Cursor
Project-Specific Configuration
To configure MCP servers for Cursor in a specific project:
mcp init . -a cursor
Or for a new project directory:
mcp init my-project -a cursor
Direct Server Configuration
To directly configure specific MCP servers for Cursor without interactive selection:
# Using space-separated server names
mcp init -a cursor --servers "git filesystem"
# Using multiple option flags
mcp init -a cursor -s git -s filesystem
Managing Configurations
Listing Configured Servers
To list MCP servers configured for Cursor:
# List global configuration
mcp list -a cursor
# List project-specific configuration
mcp list -a cursor -p .
# List with JSON output
mcp list -a cursor --json
Removing Configurations
To remove MCP servers configured for Cursor:
# Interactive removal
mcp rm -a cursor
# Remove specific servers
mcp rm git filesystem -a cursor
# Remove all servers
mcp rm --all -a cursor
# Force removal without confirmation
mcp rm git filesystem -a cursor --force
Usage Notes
- Configuration Location: MCP configurations for Cursor are stored in the standard Cursor configuration directory
- Project-Level Support: Cursor supports both global and project-level MCP configurations
- Server Compatibility: Not all MCP servers may be compatible with Cursor; check individual server documentation for compatibility information
Troubleshooting
Common Issues
-
Agent Not Detected: If the CLI reports that Cursor is not installed, ensure you have:
- Installed Cursor application
- Set up your Cursor account and AI model preferences
-
Configuration Not Applied: If your MCP configuration doesn't seem to be working:
- Verify the configuration was created successfully with
mcp list -a cursor - Restart Cursor to ensure it picks up the new configuration
- Check that the MCP servers you've configured are compatible with Cursor
- Verify the configuration was created successfully with
Checking Installation
To verify that Cursor is properly detected by MCP Gearbox:
mcp check -a cursor
This command will show whether Cursor is installed and accessible to the MCP Gearbox CLI.