Statsig MCP with Cursor
Learn how to set up the Statsig MCP server in Cursor IDE.
Installation and authentication with OAuth
MCP OAuth only supports Personal Console API Keys. Ensure your Statsig org owner has enabled Personal Console API Keys creation for your role here{" "}
You can add the Statsig MCP with OAuth to Cursor in two ways:
Option 1: Quick install (recommended)
Click here to automatically add the Statsig MCP to Cursor.Option 2: Manual configuration
- Open Cursor settings
- Navigate to Settings → Cursor Settings → Tools & Integrations
- Find the MCP servers section
- Add the following configuration to
~/.cursor/mcp.json:
json
{
"mcpServers": {
"statsig": {
"url": "https://api.statsig.com/v1/mcp"
}
}
}
Cursor automatically handles OAuth authentication when you first use the Statsig MCP. You'll be prompted to:
- Sign in to your Statsig account
- Authorize the MCP server to access your Statsig project
- Restart Cursor to apply the changes
- Verify the connection by navigating to Settings → Cursor Settings → Tools & Integrations, where the Statsig MCP server should appear and be active
Cursor saves the authentication for future sessions.
Using Statsig MCP with Cursor
After configuration, you can use Statsig MCP commands in Cursor's chat interface:
- Query Experiments: "What experiments are currently running?"
- Manage Gates: "List all my feature flags"
- Get Details: "Show me the configuration for gate 'new-feature'"
- Create Entities: "Create a new experiment called 'checkout-test'"
Troubleshooting
If the MCP server doesn't appear:
- Make sure you've restarted Cursor after adding the configuration
- Check that the
mcp.jsonfile is in the correct location:~/.cursor/mcp.json - Verify your Statsig account has the necessary permissions
Next steps
- MCP capabilities
- Use cases for Statsig MCP
- Stale gate cleanup example
Was this helpful?