A connector lets your assistant use another tool or service. Connectors use a shared standard called MCP (Model Context Protocol). The connector itself is called an MCP server.
There are two common kinds:
- Local (stdio): the connector runs on your computer. You add it with the command that starts it.
- Remote (http): the connector runs on the internet. You add it with a web address (URL).
Find the connector's setup line
Open the official page of the connector you want. Look for a URL, or a start command such as a line that starts with npx. Only add connectors from people you trust.
Add the connector
You run this in your normal terminal, not inside a Gemini session. The pattern is:
gemini mcp add [options] <name> <commandOrUrl> [args...]You choose the name. For a remote connector, add --transport http. Google's example, with a made-up address:
gemini mcp add --transport http http-server https://api.example.com/mcp/For a local connector, give the start command after the name. Google's example, with a made-up server:
gemini mcp add python-server python server.py -- --server-arg my-valueTo pass a setting such as a key, add -e KEY=value. To send a sign-in header to a remote connector, add --header.
Choose where it applies
By default, gemini mcp add saves the connector for the current project, in .gemini/settings.json inside the project folder. Add --scope user to save it in ~/.gemini/settings.json, so that it works in all your projects.
Since Gemini CLI 0.65.0, the project choice only works in a folder that Gemini CLI trusts. In any other folder the command stops with this error: "Cannot modify settings in an untrusted workspace". Add --scope user to the command, or open Gemini CLI in the folder and trust it first.
Do not use the --trust option while you learn. It skips every confirmation question for that connector.
Check that it worked
gemini mcp listEach connector shows Connected or Disconnected. A local connector shows as connected only in a folder that you trust. Inside a session, type /mcp list to see connectors and their tools. If a remote connector needs a sign-in, type /mcp auth <name>.
Remove a connector
gemini mcp remove <name>Add --scope user if you added it with that option. Browse connectors that we checked in our Connectors list.
Sources
- geminicli.com/docs/tools/mcp-server
- geminicli.com/docs/reference/commands
- github.com/google-gemini/gemini-cli/blob/main/docs/changelogs/latest.md
- github.com/google-gemini/gemini-cli/pull/29583