github-mcp-server

Install GitHub MCP Server in Windsurf

Prerequisites

  1. Windsurf IDE installed (latest version)
  2. GitHub Personal Access Token with appropriate scopes
  3. For local installation: Docker installed and running

The remote GitHub MCP server is hosted by GitHub at https://api.githubcopilot.com/mcp/ and supports Streamable HTTP protocol. Windsurf currently supports PAT authentication only.

Streamable HTTP Configuration

Windsurf supports Streamable HTTP servers with a serverUrl field:

{
  "mcpServers": {
    "github": {
      "serverUrl": "https://api.githubcopilot.com/mcp/",
      "headers": {
        "Authorization": "Bearer YOUR_GITHUB_PAT"
      }
    }
  }
}

Local Server Setup

Docker Installation (Required)

Important: The npm package @modelcontextprotocol/server-github is no longer supported as of April 2025. Use the official Docker image ghcr.io/github/github-mcp-server instead.

{
  "mcpServers": {
    "github": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "GITHUB_PERSONAL_ACCESS_TOKEN",
        "ghcr.io/github/github-mcp-server"
      ],
      "env": {
        "GITHUB_PERSONAL_ACCESS_TOKEN": "YOUR_GITHUB_PAT"
      }
    }
  }
}

Installation Steps

Via Plugin Store

  1. Open Windsurf and navigate to Cascade
  2. Click the Plugins icon or hammer icon (🔨)
  3. Search for “GitHub MCP Server”
  4. Click Install and enter your PAT when prompted
  5. Click Refresh (🔄)

Manual Configuration

  1. Click the hammer icon (🔨) in Cascade
  2. Click Configure to open ~/.codeium/windsurf/mcp_config.json
  3. Add your chosen configuration from above
  4. Save the file
  5. Click Refresh (🔄) in the MCP toolbar

Configuration Details

Verification

After installation:

  1. Look for “1 available MCP server” in the MCP toolbar
  2. Click the hammer icon to see available GitHub tools
  3. Test with: “List my GitHub repositories”
  4. Check for green dot next to the server name

Troubleshooting

Remote Server Issues

Local Server Issues

General Issues

Important Notes