Use MCP servers in GitHub Copilot CLI with Toolport
Toolport is a free, open source local MCP gateway. Add your servers to Toolport once, flip the GitHub Copilot CLI toggle, and GitHub Copilot CLI gets all of them through a single gateway entry, with lazy discovery loading a handful of meta-tools instead of every server's full tool list.
Setup
- Download Toolport for Windows, macOS or Linux, and add your MCP servers to it (or import the ones your other AI agents already have; secrets go to your OS keychain).
- Open the Clients tab and toggle GitHub Copilot CLI on. Toolport writes its gateway entry into GitHub Copilot CLI's config, next to anything already there.
- Restart or reload GitHub Copilot CLI. Your full server set is available through Toolport, and any server you add later shows up without touching GitHub Copilot CLI again.
Where GitHub Copilot CLI keeps its MCP config
- All platforms
~/.copilot/mcp-config.json
JSON with a top-level mcpServers object.
Good to know
- Copilot CLI also installs Agent Plugins 1.0 packages, so you can connect with Toolport's plugin instead of a config entry. Use one or the other; both at once connects the gateway twice.
- Set COPILOT_HOME and Toolport writes mcp-config.json under that directory.
Why a gateway instead of GitHub Copilot CLI's own server list?
- One setup, every agent. The same servers work in GitHub Copilot CLI and every other AI agent on your machine; add a server once and they all get it.
- Up to 91% fewer tool tokens. Instead of every server dumping its tool list into context, the agent loads a handful of meta-tools and searches on demand (measured).
- Secrets in the OS keychain. API keys are injected at runtime and never sit in GitHub Copilot CLI's config file.
- Watched by default. Rug-pull and tool-poisoning detection on every tool, plus per-tool governance and a destructive-tool kill switch. How the security works.