Get the FREE Ultimate OpenClaw Setup Guide →

google_workspace_mcp

Control Gmail, Google Calendar, Docs, Sheets, Slides, Chat, Forms, Tasks, Search & Drive with AI - Comprehensive Google Workspace / G Suite MCP Server & CLI Tool

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio taylorwilsdon-google_workspace_mcp uvx workspace-mcp --tool-tier core \
  --env GOOGLE_OAUTH_CLIENT_ID="OAuth client ID from Google Cloud" \
  --env GOOGLE_OAUTH_CLIENT_SECRET="OAuth client secret" \
  --env OAUTHLIB_INSECURE_TRANSPORT="1 (development only)"

How to use

This MCP server provides a production-ready integration of Google Workspace services (Gmail, Drive, Calendar, Docs, Sheets, Slides, Forms, Apps Script, Tasks, Contacts, and more) with AI-assisted capabilities. Built on FastMCP and enhanced for multi-user OAuth 2.1 support, it exposes a consolidated backend that can be queried by MCP clients and AI assistants. You can launch the server in core mode to enable essential tools, and you can enable additional tooling as needed. The included CLI tooling supports interacting with Google Workspace programmatically, including creating and managing emails, calendar events, Drive files, and more. Use the launcher command to start the server, and then use the client tools to invoke specific Workspace capabilities (e.g., gmail, drive, calendar) through natural language prompts or scripted automation.

How to install

Prerequisites:

  • Python 3.10+
  • uvx (the installation utility for instant UV-based MCP deployment)

Installation steps:

  1. Ensure Python is installed and available in your PATH.
  2. Install uvx (the launcher used by this MCP):
python -m pip install --upgrade uvx
  1. Install the Google Workspace MCP package via uvx (this registers the server for local execution):
uvx workspace-mcp --tool-tier core
  1. Run the MCP server:
uvx workspace-mcp --tool-tier core
  1. If you prefer to run a single instance directly via uvx without a global registry:
uv run main.py --tools gmail drive

Prerequisites for OAuth: set up Google OAuth credentials in the Google Cloud Console and export the required environment variables (GOOGLE_OAUTH_CLIENT_ID and GOOGLE_OAUTH_CLIENT_SECRET) before starting the server.

Additional notes

Environment variables: set GOOGLE_OAUTH_CLIENT_ID and GOOGLE_OAUTH_CLIENT_SECRET with your Google Cloud credentials. For development, OAUTHLIB_INSECURE_TRANSPORT=1 can be used to allow http redirects. Optional settings include USER_GOOGLE_EMAIL for single-user auth, GOOGLE_PSE_API_KEY and GOOGLE_PSE_ENGINE_ID for Custom Search capabilities, and MCP_ENABLE_OAUTH21 to enable OAuth 2.1 features. If you plan to operate in stateless mode or use an external OAuth flow, configure EXTERNAL_OAUTH21_PROVIDER and WORKSPACE_MCP_STATELESS_MODE accordingly. The README also mentions one-click Claude Desktop integration via a packaged distribution in DXT format; this is optional and specific to Claude Desktop users.

Related MCP Servers

Sponsor this space

Reach thousands of developers