Large Language ModelsGenerate imagesGenerate videos

Does Gemini Support MCP? Gemini App, API and CLI Explained

Gemini does support the Model Context Protocol, but each surface handles it differently. This article compares Gemini CLI, the Gemini API and SDK, managed agents, the Gemini app and Gemini Enterprise, with config fields, commands, limits and a working Python snippet.

Does Gemini Support MCP? Gemini App, API and CLI Explained
Cristian Da Conceicao
Founder of Picasso IA

Yes, Gemini supports the Model Context Protocol, but the answer changes with the door you walk through. Gemini CLI treats MCP as a built-in feature. The Gemini API reaches it through an experimental SDK client and, in preview, through managed agents. The Gemini app accepts remote servers only for a narrow group of users, and Gemini Enterprise leaves the setup to administrators. If three forum threads gave you three different answers, they were probably all correct about different products.

This article walks through each route using what Google documents as of October 2026. You will see which route runs a local process, which one needs a public HTTPS address, where the model limits sit, and which accounts can use each option. There is a working settings file, a Python snippet, a decision table and a short list of mistakes that waste the most time.

The Short Answer

MCP, the Model Context Protocol, is an open standard that lets an AI assistant call tools and read resources from a separate server. You write a server once, and any MCP client can use it. Gemini plays the client role in five different shapes, and each one has its own rules about where the server lives, who signs in and what the model is allowed to touch.

Flat lay of a laptop, smartphone and tablet side by side on an oak desk, three devices that can all reach the same MCP tools

Where MCP Works Today

SurfaceMCP supportServer locationStatus
Gemini CLIBuilt inLocal process or remote URLDocumented
Gemini API with Python and JS SDKsSession passed as a toolWherever your code can connectExperimental
Gemini API managed agentsmcp_server toolRemote serversPreview
Gemini app, web and mobileCustom appsRemote HTTPS serversLimited eligibility
Gemini EnterpriseCustom MCP serverRemote serversAdmin setup

Where It Falls Short

  • Gemini 3 and remote MCP: the Interactions API documentation lists it as a limitation and says support is coming soon.
  • Local servers in the app: the Gemini app asks for a server URL, so a process running on your laptop is not an option.
  • Write actions: the app asks for manual confirmation before a tool changes anything.
  • SDK maturity: Google labels the built-in MCP client in its Python SDK an experimental feature.

💡 Quick rule: only Gemini CLI and your own SDK code can launch a local MCP server. Every other route needs a URL.

Gemini CLI Setup

Gemini CLI is the most capable MCP client in the family. It speaks three transports (stdio, SSE and streamable HTTP), and it exposes more than tools: server resources and prompts show up inside the session too. For anyone testing a new server, this is the shortest path from idea to working call.

Over-the-shoulder view of a developer typing in a dark terminal window in a warm evening room

Add a Server in One Command

The CLI ships a small command family for managing servers:

gemini mcp add [options] <name> <commandOrUrl> [args...]
gemini mcp list
gemini mcp remove <name>
gemini mcp enable <name>
gemini mcp disable <name>

gemini mcp list prints every configured server with its connection status, which makes it the fastest sanity check after an edit. If you prefer editing by hand, servers live in the mcpServers object of your settings.json, either at user level (~/.gemini/settings.json) or at project level (.gemini/settings.json):

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-filesystem", "./docs"],
      "timeout": 30000
    },
    "remote-tools": {
      "httpUrl": "https://example.com/mcp",
      "headers": { "Authorization": "Bearer YOUR_TOKEN" },
      "includeTools": ["search_docs"]
    }
  }
}

The first entry launches a local server over stdio. The second talks to a remote server over streamable HTTP and exposes a single tool, which keeps the model's options small and predictable.

Settings Worth Knowing

Close-up of a printed configuration sheet with a red pencil circling a few lines

Every server entry needs one transport field. Everything else is optional:

  • command: the executable for a local stdio server, with args, cwd and env beside it. Values in env can reference variables with $VAR_NAME, so tokens stay out of the file.
  • url: an SSE endpoint.
  • httpUrl: a streamable HTTP endpoint.
  • headers: custom HTTP headers for the two URL transports.
  • timeout: request timeout in milliseconds, 600,000 by default.
  • includeTools and excludeTools: an allowlist and a blocklist for tool names.
  • trust: when true, tool confirmation dialogs are skipped.
  • authProviderType: picks the auth provider: automatic OAuth endpoint lookup, Google credentials (google_credentials) or service account impersonation (service_account_impersonation).

💡 Leave trust off for any server you did not write yourself. The confirmation dialog is the last checkpoint before a tool runs.

Commands Inside a Session

Once the CLI is running, /mcp shows each server's status, tools, resources and prompts. /mcp auth [serverName] handles OAuth, and /mcp enable and /mcp disable toggle a server for the current session only.

A few behaviors surprise people the first time:

  • Tools get fully qualified names in the form mcp_{serverName}_{toolName}, which prevents collisions between servers and built-in tools.
  • Resources are referenced with @server://resource/path inside your prompt.
  • Prompts exposed by a server become slash commands.
  • OAuth includes automatic endpoint lookup, dynamic client registration and a browser sign-in flow. Tokens are stored in ~/.gemini/mcp-oauth-tokens.json, and Google Application Default Credentials are supported as well.

Gemini API and Python SDK

The Gemini API does not open connections to your server by itself. The SDK does. It connects to the server, asks for its tool list, and hands those tools to the model as callable functions. In the python-genai repository, Google describes this built-in MCP support as an experimental feature, and the example is marked for the Gemini Developer API only, not for the Enterprise Agent Platform.

A developer beside a whiteboard of hand-drawn boxes and arrows while a colleague works at a dual-monitor desk

Passing a Session as a Tool

The pattern needs the mcp package next to google-genai. You open a client session against a server, then pass that session straight into the generation config:

import asyncio
from google import genai
from mcp import ClientSession, StdioServerParameters
from mcp.client.stdio import stdio_client

client = genai.Client()  # reads the API token from the environment

server = StdioServerParameters(
    command="npx",
    args=["-y", "@modelcontextprotocol/server-filesystem", "./docs"],
)

async def main():
    async with stdio_client(server) as (read, write):
        async with ClientSession(read, write) as session:
            await session.initialize()
            response = await client.aio.models.generate_content(
                model="gemini-flash-latest",
                contents="List the markdown files in the docs folder.",
                config=genai.types.GenerateContentConfig(tools=[session]),
            )
            print(response.text)

asyncio.run(main())

Because your code holds the session, the connection runs inside your own process. That is why this route works with local servers. The price is lifecycle work: you open the session, initialize it, make the call and close it again.

Remote MCP for Managed Agents

On July 7, 2026, Google announced remote MCP for managed agents in the Gemini API. Instead of writing proxy middleware, you pass an mcp_server tool at interaction time, next to tools such as Google Search or code execution. Credentials travel through custom headers, so an Authorization header can protect your endpoint. The agent then calls your endpoints from its own secure sandbox.

The announcement's examples use the agent antigravity-preview-05-2026, and the feature is in preview, so expect details to shift.

Aerial view down a long aisle of black server racks in a clean data center

The Gemini 3 Limitation

The Interactions API overview lists a limitation in plain words: Gemini 3 does not support remote MCP, and the page says it is coming soon. Google describes managed agents and the plain model path as separate capabilities, so read the limits of the exact surface you call. The SDK route above is different again, since the connection lives in your code, but test it with your target model before you build on it.

💡 When a doc page and an announcement seem to disagree, check the date. Preview features move quickly, and the older page is usually the one that lags.

Gemini App and Enterprise

Who Can Connect Custom Apps

Gemini Apps Help lists the conditions for adding your own MCP server to the Gemini app:

  • You are 18 or older and in the US.
  • You are signed in with a personal Google Account. Work and school accounts are not supported.
  • Keep Activity is turned on.
  • You use the app in English, on the Gemini web app or the Gemini mobile app.
  • You have the URL of an MCP server that follows the standard specification.

Hands holding a smartphone at a sunlit cafe table with a blurred chat conversation on screen

Write actions currently need manual confirmation, so the app asks before a tool edits, sends or deletes anything. That is a sensible default for a consumer product, even if it slows down a long chain of steps.

Adding Your Server

The help page describes adding a server from the web app:

  1. Open the Gemini web app and go to settings.
  2. Choose Connected Apps, then Add a custom app.
  3. Paste the MCP server URL and follow the prompts.
  4. If your server does not support Dynamic Client Registration, open the extra options in the form and enter your client credentials by hand.

Dynamic Client Registration lets a client register itself with the server's OAuth provider. Without it, you create the client on the provider side first and paste the credentials into Gemini.

Gemini Enterprise and Business

Organizations get a separate path. Google Cloud documents connecting a custom MCP server to Gemini Enterprise, and an administrator does the setup, not each employee. Community write-ups of the release notes report that since June 15, 2026 a custom MCP server can authenticate with a Google Cloud service account access token, which suits internal servers that never meet a human sign-in screen.

Five colleagues around a long table in a bright meeting room with laptops open

Google also announced official MCP support for its own services, so some of the servers a team needs may already exist as managed endpoints. Check there before building a custom one.

Which Route Fits You

The best choice depends on where your server runs and who the user is. Use this table as a first filter:

What you needBest routeWhy
Local files and shell toolsGemini CLIstdio servers run on your own machine
A Python or JS backend with custom logicSDK sessionYour code controls the whole loop
A hosted agent calling remote endpointsManaged agentsNo proxy layer, still in preview
A personal assistant with your own toolsGemini appURL only, US English, personal account
A company-wide rolloutGemini EnterpriseAdministrators manage connections

Two patterns come up again and again. Developers prototype in Gemini CLI because the feedback loop is a single command, then move the same server to a remote URL once it works. That move costs almost nothing, since a server written for one MCP client usually behaves the same for another. Teams that start in the app often hit the eligibility wall early, because the US, personal account and English conditions rule out many work setups.

3 Common Mistakes

A developer leaning back in an office chair with hands behind the head, looking puzzled at a laptop

Using the Wrong Transport Field

In Gemini CLI, url means SSE and httpUrl means streamable HTTP. A server that speaks streamable HTTP but sits under url will fail to connect, and the error rarely says why. Check which transport your server documents, then match the field. gemini mcp list shows the connection status right away.

Trusting a Server Too Early

Setting trust to true skips the confirmation dialogs, which feels great until a tool does something you did not expect. Start with confirmations on. Use includeTools to expose only the tools a task needs, and widen the list once you have watched the server behave.

Expecting the App to Run Local Servers

The Gemini app takes a URL, not a command. A server on your laptop cannot be reached from there. Deploy it behind HTTPS first, then paste that address under Connected Apps. If the server needs OAuth and has no Dynamic Client Registration, keep the client credentials ready before you start.

How to Use Gemini on PicassoIA

MCP projects involve a lot of writing: config blocks, tool descriptions, test prompts and review notes. PicassoIA hosts several Gemini models in its Large Language Models category, including Gemini 3.5 Flash for quick drafts, Gemini 3 Flash for fast chat, and Gemini 3.1 Pro and Gemini 3 Pro for harder reviews. In this workflow PicassoIA is the drafting desk. The MCP connection itself still happens in the Gemini surface you picked above.

  1. Open the Gemini 3.5 Flash page on PicassoIA.
  2. Paste the tool names and descriptions from your server and ask for a settings.json block that uses httpUrl.
  3. Add the details a good answer needs: the transport, the auth method and the tool names. Remove real tokens before you paste anything.
  4. Ask a follow-up such as "Which of these tools should go in excludeTools for a read-only session?"
  5. For a harder review, run the same prompt on Gemini 3.1 Pro and compare the answers.
  6. Copy the result into your config, restart the CLI and check it with /mcp.

💡 Specific prompts win. "Write a config for a remote server with a bearer header and one allowed tool" beats "set up MCP" every time.

Make Your First Image Today

Image and Video Tools Over MCP

MCP is not only for text and code. A creative team can connect an image or video generator as a tool, so an assistant produces visuals as part of a longer task, such as drafting a post and generating its header in the same session.

A creative director studying a monitor with a misty mountain lake photograph next to printed proofs

PicassoIA offers a developer API and MCP connections for its image and video models. The API follows an asynchronous pattern: you create a prediction, poll for its status, then fetch the result. As of early October 2026 the limit is 5 concurrent predictions per account, shared across your API tokens and MCP connections. Plan requirements and pricing can change, so check the pricing page before you build on it. Whether a given Gemini surface accepts that connection depends on the rules above: the CLI and SDK can reach it with the right transport, while the Gemini app needs the eligibility conditions to line up.

You do not need an API to start. PicassoIA Image turns a written prompt into a photorealistic picture, and PicassoIA Image Editor Pro refines an existing photo with plain-language edits. For video, browse the full catalog at picassoia.com/en/all-models.

Try it now: open PicassoIA, describe a scene with a lens, a light direction and a mood, and run it. Change one detail, run it again, and compare. Your first strong image is usually two or three prompts away.

Share this article