Gdrive MCP Server

MCP server for Google Drive access with secure OAuth2 authentication

Local serverstdioGo

What is the Gdrive MCP server?

Gdrive MCP server exists for a simple reason — assistants are far more useful when they can act on Gdrive directly instead of describing what you should do. MCP server for Google Drive access with secure OAuth2 authentication.

What you get

A Model Context Protocol (MCP) server that provides access to Google Drive documents.

  • search_drive — Search for files and documents across all of Google Drive
  • get_doc_contents — Retrieve the full text contents of a Google Doc by URL or document ID
  • list_doc_comments — List all comment threads on a Google Doc with details
  • create_doc_comment — Create unanchored comments on a Google Doc
  • reply_to_comment — Reply to existing comment threads
  • insert_doc_note — Insert auto-numbered styled note blocks (📝 NOTE 1:, 📝 NOTE 2:, etc.) into document content

Setting it up

Setup follows the usual MCP pattern — install or clone the server, register it in your client's configuration file, restart the client. The configuration blocks on this page cover the common clients.

What the assistant can call

Once Gdrive is connected, these are the calls the assistant has available:

  • OpenCode — The OpenCode tool exposed by this server
  • search_drive — Search for files and documents across all of Google Drive using text queries
  • get_doc_contents — The get_doc_contents tool exposed by this server
  • list_doc_comments — Lists all comment threads on a Google Doc, including quoted text, replies, and status
  • create_doc_comment — Creates an unanchored comment on a Google Doc (appears in "All Comments" view)
  • reply_to_comment — The reply_to_comment tool exposed by this server
  • insert_doc_note — Inserts an auto-numbered styled note block directly into the document content. Notes are automatically numbered sequentially (📝 NOTE 1:, 📝 NOTE 2:
  • update_doc_note — Updates the text of an existing note by its number. The note number and formatting remain the same
  • remove_doc_note — Removes a note from the document by its number. This completely deletes the note block including all formatting

Configuration and credentials

You will need 2 environment variables: YOUR_CLIENT_ID, YOUR_CLIENT_SECRET. The server will not start without them, which is usually why the tools fail to appear on a first run. Keep credentials in your client's env block or a secrets manager rather than in a file you might commit.

Before you rely on it

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • With 9 tools registered it takes up a noticeable share of the context window; turn it off in projects that never touch Gdrive.
  • Missing credentials fail quietly in some clients — if no tools show up, check the environment block first.
  • MCP clients confirm each tool call by default. Leave that on until you have watched what the gdrive mcp server does with a few real requests.

Choosing this one

Among the planning and project tracking options, the useful question is rarely "what can it do" but "what does it cost you to run" — permissions, credentials, and how much of your context its toolset consumes. Gdrive's toolset — OpenCode, search_drive, get_doc_contents and 6 more — is a fair guide to whether it matches your workflow. It is maintained by beneidel; worth a glance at recent repository activity before you build anything load-bearing on it.

SyncDev reviews every entry in this directory against the project's own documentation before publishing, and revisits them as servers change.

Available tools

ToolWhat it does
OpenCodeThe OpenCode tool exposed by this server.
search_driveSearch for files and documents across all of Google Drive using text queries.
get_doc_contentsThe get_doc_contents tool exposed by this server.
list_doc_commentsLists all comment threads on a Google Doc, including quoted text, replies, and status.
create_doc_commentCreates an unanchored comment on a Google Doc (appears in "All Comments" view).
reply_to_commentThe reply_to_comment tool exposed by this server.
insert_doc_noteInserts an auto-numbered styled note block directly into the document content. Notes are automatically numbered sequentially (📝 NOTE 1:, 📝 NOTE 2:, etc.). This is a workaround for the API's inability to create anchored
update_doc_noteUpdates the text of an existing note by its number. The note number and formatting remain the same.
remove_doc_noteRemoves a note from the document by its number. This completely deletes the note block including all formatting.

How to install the Gdrive MCP server

✨ Setup Complete!

✅ Credentials stored securely in your system keychain
   (macOS Keychain / Linux libsecret / Windows Credential Manager)

Add this to your Claude Desktop config:
{
  "mcpServers": {
    "gdrive": {
      "command": "bunx",
      "args": ["--bun", "gdrive-mcp"]
    }
  }
}

💡 No need to store sensitive credentials in config files!

Configuration as documented by the project. Restart the client after saving.

Configuration

VariableDescriptionRequired
YOUR_CLIENT_IDConfiguration value read at startup.Optional
YOUR_CLIENT_SECRETCredential the server authenticates with.Yes

Example prompts to try

  • Use Gdrive to OpenCode.
  • Use Gdrive to search drive.
  • Use Gdrive to get doc contents.

Frequently asked questions

It connects Gdrive to MCP-compatible AI assistants such as Claude and Cursor, exposing 9 tools (OpenCode, search_drive, get_doc_contents, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Gdrive directly.