MCP setup guide

Antigravity

Google Antigravity shares a global MCP configuration across Antigravity, the Antigravity IDE, and the Antigravity CLI, and also reads a workspace-level .agents/mcp_config.json. Add servers from the Customizations page or write the config file directly.

Paths checked against the client's docs · November 2026

Surfaces

Antigravity · IDE · CLI

Scope

Global and workspace

Global config~/.gemini/config/mcp_config.json
Installer agentantigravity
1 / How it works

How Antigravity handles MCP

Google Antigravity shares a global MCP configuration across Antigravity, the Antigravity IDE, and the Antigravity CLI, and also reads a workspace-level .agents/mcp_config.json. Add servers from the Customizations page or write the config file directly.

Global and workspace. Project scope keeps the server with the repository; global scope makes it available in every workspace.

Best for

Antigravity users who switch between the app, IDE, and CLI.

Installer flag-a antigravity
2 / Where it goes

Where the MCP config lives

The installer writes this file for you. Use the paths below when you want to inspect, edit, or remove a server by hand.

Global
~/.gemini/config/mcp_config.json

Shared by Antigravity, Antigravity IDE, and Antigravity CLI

Workspace
.agents/mcp_config.json

Project-scoped; shared by the CLI and SDK in that workspace

Project paths are relative to the workspace. Global paths are per user. On Windows, ~ means your user folder; use %USERPROFILE% in Explorer or PowerShell. A project config is shared with the team; a global config is personal.

3 / Install

Add a remote server

Start with a server in the MCP directory, or use your provider's endpoint. The examples use https://mcp.example.com/mcp so you can see the shape; replace it with the real URL.

  1. 01

    Find the endpoint

    Open a server page and copy its hosted endpoint. Do not use a local command or an npm package name for a remote server; those are different connection types.

    Open the MCP directory
  2. 02

    Run the installer

    Add the JSON entry to the workspace file for one project, or to the shared global file for every workspace. The server name becomes example in the config.

    Antigravity · project
    # Add this to .agents/mcp_config.json:
    {
      "mcpServers": {
        "example": {
          "serverUrl": "https://mcp.example.com/mcp"
        }
      }
    }
    Antigravity · global
    # Add this to ~/.gemini/config/mcp_config.json:
    {
      "mcpServers": {
        "example": {
          "serverUrl": "https://mcp.example.com/mcp"
        }
      }
    }

    Antigravity remote servers use Streamable HTTP. Use the serverUrl field; the legacy HTTP+SSE httpUrl field is not supported.

  3. 03

    Authorize if the provider asks

    The first connection may open a browser for OAuth. Sign in with the provider and approve only the scopes you need. If the server uses an API key, create it in the provider's dashboard and add it through the client's auth flow or config.

    Never paste a provider token into a project config you will commit. Prefer the client's secret store or a user-level config for credentials.

  4. 04

    Reload and verify

    Open `/mcp` in an Antigravity CLI session, or Customizations > Installed > MCP Servers in the App, to confirm the server is enabled. Complete provider authentication before using its tools.

    Antigravity CLI MCP Servers panel showing only cloudflare-code-mode and an authentication error.Open larger view
    Open /mcp in your project workspace to inspect the server. This remote endpoint needs sign-in before its tools can be used.View full size

    The server appears in /mcp, and its tools appear after sign-in.

    Unauthorized before sign-in is expected. If it persists, remove and re-add the server.

    Full screenshot
    Antigravity CLI MCP Servers panel showing only cloudflare-code-mode and an authentication error.

    Then ask for a task, not a tool: “Find the open issues assigned to me” or “Summarize the latest release.” The client decides which advertised tool to call.

4 / Use

What changes in the chat

Once the server is connected, its tools appear in the client's tool list. You still talk to the agent normally; MCP is plumbing, not a different chat interface.

Read

“Find the customer notes mentioning the migration and summarize the blockers.”

Write

“Create a draft page with this outline, but do not publish it yet.”

Investigate

“Check the failed deployment and list the last three changes that touched it.”

Verify

“Which MCP tools do you have available for this task?”

If the agent ignores the server, check that the server is enabled and that its tools are approved. Some clients require a per-tool confirmation before the first call.

5 / Troubleshooting

When it does not connect

The server is missing

Confirm the file exists at the path above, the JSON or TOML is valid, and you restarted the client or opened a new session.

It connects but tools are empty

Enable the server in the client's MCP UI, approve its tools, and check that the provider has not revoked your token.

OAuth keeps reopening

Remove the server from the client, revoke the app's access in the provider's account settings, then add it again.

A project server is ignored

Some clients require you to trust the folder before loading project MCP config. Trust the repository, then start a new session.

6 / Notes

What to watch for in Antigravity

  • Add a server in the App under Customizations > Installed > MCP Servers, or edit the config file directly.
  • For one workspace, create `.agents/mcp_config.json` with an `mcpServers` object.
  • Run `/mcp` in an Antigravity CLI session to check status and authentication.
  • Reload the surface you are using after changing the config.
7 / Remove

Remove or reset the server

Remove the server when it is no longer needed, or reset it when a credential or connection state gets stuck.

  1. For the global config, delete the server entry from ~/.gemini/config/mcp_config.json.
  2. For a workspace server, delete its entry from .agents/mcp_config.json.
  3. Open /mcp in a new session, or Customizations > Installed > MCP Servers, and confirm that it is gone.

Remove and re-add the server if sign-in is stuck. Tokens live in `~/.gemini/antigravity/mcp_oauth_tokens.json`.

Sources

Official documentation

Client behavior changes. These links are the source of truth for paths, flags, and approval behavior.

Next setup guideFactory Droid