LaunchDarkly hosted MCP server

This topic describes how to connect your AI client to the LaunchDarkly hosted Model Context Protocol (MCP) server. To use the hosted MCP server, you must have an AI client that supports MCP, such as Cursor, Claude Code, VS Code with Copilot, or Windsurf.

Configure the MCP server

The hosted MCP server at https://mcp.launchdarkly.com/mcp/launchdarkly connects your AI client to LaunchDarkly using OAuth and supports feature flag management, AgentControl configs, and observability.

Quick configuration

If you’re using an AI client, like Claude or Cursor, the install page connects to it without requiring you to manually edit a configuration file. Open the install page, select your AI client, and follow the prompts to authorize and connect.

Manual configuration

If you prefer to configure your AI client manually, read the instructions in this section. Here, we show examples for Cursor, Claude Code, Windsurf, and GitHub Copilot.

Cursor supports two methods for adding the MCP server.

To add the server through Cursor Settings:

  1. In Cursor, navigate to Settings > Cursor Settings > Tools & Integrations > MCP Tools.
  2. Click Add Custom MCP. An “Install MCP Server?” dialog appears.
  3. Enter the following values:
    • Name: LaunchDarkly
    • Type: streamableHttp
    • URL: https://mcp.launchdarkly.com/mcp/launchdarkly
  4. Click Install.

To edit the configuration file directly:

  1. Create or update .cursor/mcp.json in your project root:

    Cursor
    1{
    2 "mcpServers": {
    3 "launchdarkly": {
    4 "url": "https://mcp.launchdarkly.com/mcp/launchdarkly",
    5 "headers": {}
    6 }
    7 }
    8}
  2. In Cursor, navigate to Settings > Cursor Settings > Tools & Integrations > MCP Tools.

  3. Toggle on the LaunchDarkly server.

  4. Click Connect to authorize with your LaunchDarkly account.

To manually configure the MCP server in Claude Code, add the server to your Claude Code MCP configuration:

Claude Code
$claude mcp add --transport http "launchdarkly" \
> "https://mcp.launchdarkly.com/mcp/launchdarkly"

To manually configure the MCP server in Windsurf:

  1. Open Windsurf Settings and navigate to Cascade.

  2. Click View raw config. This opens mcp_config.json. You can also open this file directly:

    • macOS: ~/.codeium/windsurf/mcp_config.json
    • Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json
  3. Add the LaunchDarkly server to the mcpServers object:

    Windsurf
    1{
    2 "mcpServers": {
    3 "launchdarkly": {
    4 "serverUrl": "https://mcp.launchdarkly.com/mcp/launchdarkly"
    5 }
    6 }
    7}
  4. Save the file and restart Windsurf.

To manually configure the MCP server with GitHub Copilot, add the server to the MCP configuration for a target GitHub repo:

  1. Navigate to a target repository on GitHub.

  2. Select Settings > Code and automation > Copilot > Coding agent.

  3. Under the MCP configuration section, add the following .json configuration:

    GitHub Copilot
    1{
    2 "mcpServers": {
    3 "launchdarkly": {
    4 "url": "https://mcp.launchdarkly.com/mcp/launchdarkly",
    5 "headers": {}
    6 }
    7 }
    8}
  4. Click Save.

Migrate to the hosted server

If you used an earlier version of the local npx-based server, migrate to the hosted server using these steps:

  1. Replace your old server configuration. Your old configuration looks like this:

    Old configuration to remove
    1{
    2 "mcpServers": {
    3 "LaunchDarkly": {
    4 "command": "npx",
    5 "args": [
    6 "-y", "--package", "@launchdarkly/mcp-server",
    7 "--", "mcp", "start",
    8 "--api-key", "api-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
    9 ]
    10 }
    11 }
    12}

    and should be replaced with this:

    New configuration to add
    1{
    2 "mcpServers": {
    3 "launchdarkly": {
    4 "type": "http",
    5 "url": "https://mcp.launchdarkly.com/mcp/launchdarkly"
    6 }
    7 }
    8}
  2. Remove any environment variables for the local server, such as LD_ACCESS_TOKEN. Instead, OAuth now handles authentication.

  3. Close and reopen your AI client.

  4. (Cursor only) If you are using Cursor, authorize your LaunchDarkly account:

    • Navigate to Settings > Cursor Settings > Tools & Integrations > MCP Tools.
    • Toggle on the LaunchDarkly server.
    • Click connect.

To learn how to use the MCP server in your AI client, read Use the MCP server.