MCP Server Studio

Google Docs MCP MCP server

MCP server for the Google Docs API: read and edit documents, styles, tables, images, comments.

Registry name: io.github.A1-x-Tech/mcp-google-docs

Publisher
A1-x-Tech
Runs
Runs locally
Package
npm
Version
1.2.0
Category
Productivity
Updated
2026-12-02

Source code on GitHub

Set up Google Docs MCP (run locally)

Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "mcp-google-docs": {
      "command": "npx",
      "args": [
        "-y",
        "@a1-x-tech/[email protected]"
      ],
      "env": {
        "GOOGLE_DOCS_CLIENT_ID": "<GOOGLE_DOCS_CLIENT_ID>",
        "GOOGLE_DOCS_CLIENT_SECRET": "<GOOGLE_DOCS_CLIENT_SECRET>",
        "GOOGLE_DOCS_REFRESH_TOKEN": "<GOOGLE_DOCS_REFRESH_TOKEN>",
        "GOOGLE_DOCS_ACCESS_TOKEN": "<GOOGLE_DOCS_ACCESS_TOKEN>",
        "GOOGLE_DOCS_OAUTH_PORT": "<GOOGLE_DOCS_OAUTH_PORT>",
        "GOOGLE_DOCS_API_BASE": "<GOOGLE_DOCS_API_BASE>",
        "GOOGLE_DOCS_DRIVE_API_BASE": "<GOOGLE_DOCS_DRIVE_API_BASE>",
        "GOOGLE_DOCS_TIMEOUT_MS": "<GOOGLE_DOCS_TIMEOUT_MS>",
        "GOOGLE_DOCS_MAX_RETRIES": "<GOOGLE_DOCS_MAX_RETRIES>"
      }
    }
  }
}

Claude Code

Run in your terminal:

claude mcp add mcp-google-docs -e GOOGLE_DOCS_CLIENT_ID='<GOOGLE_DOCS_CLIENT_ID>' -e GOOGLE_DOCS_CLIENT_SECRET='<GOOGLE_DOCS_CLIENT_SECRET>' -e GOOGLE_DOCS_REFRESH_TOKEN='<GOOGLE_DOCS_REFRESH_TOKEN>' -e GOOGLE_DOCS_ACCESS_TOKEN='<GOOGLE_DOCS_ACCESS_TOKEN>' -e GOOGLE_DOCS_OAUTH_PORT='<GOOGLE_DOCS_OAUTH_PORT>' -e GOOGLE_DOCS_API_BASE='<GOOGLE_DOCS_API_BASE>' -e GOOGLE_DOCS_DRIVE_API_BASE='<GOOGLE_DOCS_DRIVE_API_BASE>' -e GOOGLE_DOCS_TIMEOUT_MS='<GOOGLE_DOCS_TIMEOUT_MS>' -e GOOGLE_DOCS_MAX_RETRIES='<GOOGLE_DOCS_MAX_RETRIES>' -- npx -y @a1-x-tech/[email protected]

Cursor

Add to .cursor/mcp.json:

{
  "mcpServers": {
    "mcp-google-docs": {
      "command": "npx",
      "args": [
        "-y",
        "@a1-x-tech/[email protected]"
      ],
      "env": {
        "GOOGLE_DOCS_CLIENT_ID": "<GOOGLE_DOCS_CLIENT_ID>",
        "GOOGLE_DOCS_CLIENT_SECRET": "<GOOGLE_DOCS_CLIENT_SECRET>",
        "GOOGLE_DOCS_REFRESH_TOKEN": "<GOOGLE_DOCS_REFRESH_TOKEN>",
        "GOOGLE_DOCS_ACCESS_TOKEN": "<GOOGLE_DOCS_ACCESS_TOKEN>",
        "GOOGLE_DOCS_OAUTH_PORT": "<GOOGLE_DOCS_OAUTH_PORT>",
        "GOOGLE_DOCS_API_BASE": "<GOOGLE_DOCS_API_BASE>",
        "GOOGLE_DOCS_DRIVE_API_BASE": "<GOOGLE_DOCS_DRIVE_API_BASE>",
        "GOOGLE_DOCS_TIMEOUT_MS": "<GOOGLE_DOCS_TIMEOUT_MS>",
        "GOOGLE_DOCS_MAX_RETRIES": "<GOOGLE_DOCS_MAX_RETRIES>"
      }
    }
  }
}

VS Code

Add to .vscode/mcp.json:

{
  "servers": {
    "mcp-google-docs": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@a1-x-tech/[email protected]"
      ],
      "env": {
        "GOOGLE_DOCS_CLIENT_ID": "<GOOGLE_DOCS_CLIENT_ID>",
        "GOOGLE_DOCS_CLIENT_SECRET": "<GOOGLE_DOCS_CLIENT_SECRET>",
        "GOOGLE_DOCS_REFRESH_TOKEN": "<GOOGLE_DOCS_REFRESH_TOKEN>",
        "GOOGLE_DOCS_ACCESS_TOKEN": "<GOOGLE_DOCS_ACCESS_TOKEN>",
        "GOOGLE_DOCS_OAUTH_PORT": "<GOOGLE_DOCS_OAUTH_PORT>",
        "GOOGLE_DOCS_API_BASE": "<GOOGLE_DOCS_API_BASE>",
        "GOOGLE_DOCS_DRIVE_API_BASE": "<GOOGLE_DOCS_DRIVE_API_BASE>",
        "GOOGLE_DOCS_TIMEOUT_MS": "<GOOGLE_DOCS_TIMEOUT_MS>",
        "GOOGLE_DOCS_MAX_RETRIES": "<GOOGLE_DOCS_MAX_RETRIES>"
      }
    }
  }
}

Windsurf

Add to ~/.codeium/windsurf/mcp_config.json:

{
  "mcpServers": {
    "mcp-google-docs": {
      "command": "npx",
      "args": [
        "-y",
        "@a1-x-tech/[email protected]"
      ],
      "env": {
        "GOOGLE_DOCS_CLIENT_ID": "<GOOGLE_DOCS_CLIENT_ID>",
        "GOOGLE_DOCS_CLIENT_SECRET": "<GOOGLE_DOCS_CLIENT_SECRET>",
        "GOOGLE_DOCS_REFRESH_TOKEN": "<GOOGLE_DOCS_REFRESH_TOKEN>",
        "GOOGLE_DOCS_ACCESS_TOKEN": "<GOOGLE_DOCS_ACCESS_TOKEN>",
        "GOOGLE_DOCS_OAUTH_PORT": "<GOOGLE_DOCS_OAUTH_PORT>",
        "GOOGLE_DOCS_API_BASE": "<GOOGLE_DOCS_API_BASE>",
        "GOOGLE_DOCS_DRIVE_API_BASE": "<GOOGLE_DOCS_DRIVE_API_BASE>",
        "GOOGLE_DOCS_TIMEOUT_MS": "<GOOGLE_DOCS_TIMEOUT_MS>",
        "GOOGLE_DOCS_MAX_RETRIES": "<GOOGLE_DOCS_MAX_RETRIES>"
      }
    }
  }
}

Settings

NameRequiredWhat it is
GOOGLE_DOCS_CLIENT_IDNoGoogle OAuth2 client id (refresh-token flow).
GOOGLE_DOCS_CLIENT_SECRETNoGoogle OAuth2 client secret (refresh-token flow). Treat it as a secret.
GOOGLE_DOCS_REFRESH_TOKENNoGoogle OAuth2 refresh token, exchanged for access tokens automatically. Treat it as a secret.
GOOGLE_DOCS_ACCESS_TOKENNoStatic OAuth2 access token (~1h lifetime) — alternative to the refresh-token trio, mostly for testing.
GOOGLE_DOCS_OAUTH_PORTNoFixed port for the loopback listener of the in-chat login (127.0.0.1 + PKCE). Set it when the client runs over SSH port forwarding; otherwise a free port is picked per login.
GOOGLE_DOCS_API_BASENoDocs API root override.
GOOGLE_DOCS_DRIVE_API_BASENoDrive API root override (markdown import/export, document export, comments).
GOOGLE_DOCS_TIMEOUT_MSNoPer-request timeout in milliseconds.
GOOGLE_DOCS_MAX_RETRIESNoRetries on transient errors (429 always; 5xx/network for reads).

More productivity MCP servers