VS Code · GitHub / Microsoft

Give GitHub Copilot Agent Mode Custom MCP Tools

GitHub Copilot's VS Code agent mode reads MCP servers from .vscode/mcp.json. Point it at Agent MCP Studio's relay bridge to give Copilot access to Python, SQL, and API tools you build in your browser — no server setup required.

Share:

Prerequisites

Step-by-Step Setup

  1. Get your relay URL and download bridge.js

    Open the studio → SettingsMCP Relay Bridge. Copy the session URL, click Connect, then:

    curl -O https://agentmcp.studio/bridge.js && npm install ws
  2. Create .vscode/mcp.json in your project

    VS Code Copilot agent reads MCP servers from a file in your workspace. Create .vscode/mcp.json:

    {
      "servers": {
        "agent-mcp-studio": {
          "type": "stdio",
          "command": "node",
          "args": [
            "/absolute/path/to/bridge.js",
            "wss://agentmcp.studio/api/relay/YOUR-SESSION-UUID"
          ]
        }
      }
    }
    User-level config

    To make tools available across all projects, add the server to VS Code's User settings.json instead: "github.copilot.chat.mcp.servers".

  3. Switch Copilot Chat to Agent mode

    Open Copilot Chat (Ctrl+Alt+I), click the mode dropdown and select Agent. You'll see a tools icon (🔧) indicating MCP servers are active.

  4. Ask Copilot to use your tools

    In agent mode, type: "What MCP tools are available?" Copilot will list your registered tools and can call them during coding tasks.

Note on MCP support

GitHub Copilot's MCP support is in the agent mode of Copilot Chat — it is not available in inline completions or the Ask/Edit modes. Make sure you're using Agent mode.

Frequently Asked Questions

Yes — GitHub Copilot in VS Code (agent mode) added MCP support in early 2025. Configure servers in your workspace .vscode/mcp.json and Copilot's agent will automatically discover and call your tools.

Create or edit .vscode/mcp.json in your project (or user-level settings). Add your server under servers with type stdio and the command / args for bridge.js. Restart VS Code to pick up changes.

Copilot agent mode (also called "agentic Copilot") lets Copilot autonomously plan multi-step tasks, run terminal commands, and call MCP tools — going beyond single-step autocomplete to full task execution.

MCP tools are available in Copilot's agent mode (the @ agent in Chat). Standard Copilot Chat completions don't call MCP tools directly, but switching to agent mode in the Chat panel gives full MCP tool access.

MCP configuration in VS Code works with all Copilot tiers (Individual, Business, Enterprise) as it's a client-side feature of the VS Code extension, not a server-side restriction.

Related Integrations