About Google Drive & Sheets MCP Server
A Rust MCP server for working with Google Drive and Google Sheets. It exposes file search and spreadsheet operations as tools for agent workflows.
Key features
- 01Filter and order Drive file listings
- 02Read values from selected sheet ranges
- 03Write and clear spreadsheet values
- 04Create spreadsheets with multiple sheets
- 05Refresh Google OAuth tokens
Use cases
- 01Find Drive files by MIME type or query
- 02Read or update spreadsheet ranges
- 03Create a spreadsheet for an agent workflow
MCP support
Exposes Google Drive and Sheets operations as MCP tools over stdio, with capabilities also listed through `resources/list`.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project READMEGoogle Drive & Sheets MCP Server
A Model Context Protocol (MCP) server built in Rust for interacting with Google Drive and Google Sheets. This tool provides MCP-compatible interfaces for Google Workspace services, allowing it to be used as part of larger agent workflows and compositions.
Features
Google Drive Operations
- List files in Google Drive with filtering options:
- Filter by MIME type
- Custom search queries
- Configurable page size
- Custom ordering
Google Sheets Operations
- Read data from Google Sheets with options:
- Specify range
- Choose major dimension (ROWS or COLUMNS)
- Write data to Google Sheets
- Create new spreadsheets with:
- Custom title
- Multiple sheets
- Clear values from ranges in spreadsheets
MCP Integration
This server implements the Model Context Protocol (MCP), making it compatible with agent frameworks like Distri. Each service exposes its capabilities as MCP tools:
Drive Tools
list_files: List and filter Drive files with customizable parameters- Available capabilities exposed via
resources/listendpoint
Sheets Tools
read_values: Read spreadsheet data with dimension controlwrite_values: Write data to spreadsheetscreate_spreadsheet: Create new spreadsheetsclear_values: Clear ranges in spreadsheets- Available capabilities exposed via
resources/listendpoint
Prerequisites
- Rust (latest stable version)
- Google Cloud Project with Drive and Sheets APIs enabled
- OAuth 2.0 credentials configured for your Google Cloud Project
Installation
Install the mcp-google binary directly from GitHub using Cargo:
cargo install --git https://github.com/distrihub/mcp-google-workspace.git
This will install the mcp-google command to your system.
Configuration
Before using the server, you need to:
- Set up a Google Cloud Project
- Enable Google Drive and Google Sheets APIss
- Create OAuth 2.0 credentials
- Set up your environment variables:
ACCESS_TOKEN: Your Google OAuth access tokenGOOGLE_CLIENT_ID: Your OAuth client IDGOOGLE_CLIENT_SECRET: Your OAuth client secretGOOGLE_REFRESH_TOKEN: Your OAuth refresh token
Usage
As MCP Server
The servers can be started independently and will communicate using the MCP protocol over stdio:
Start the Drive MCP server:
mcp-google drive --access-token <your-access-token>
Start the Sheets MCP server:
mcp-google sheets --access-token <your-access-token>
Using with Distri
This server can be used as part of a Distri agent configuration:
agents:
google_workspace:
drive:
type: mcp
command: ["mcp-google", "drive", "--access-token", "${ACCESS_TOKEN}"]
sheets:
type: mcp
command: ["mcp-google", "sheets", "--access-token", "${ACCESS_TOKEN}"]
Token Management
Refresh your OAuth token:
mcp-google refresh \
--client-id <your-client-id> \
--client-secret <your-client-secret> \
--refresh-token <your-refresh-token>
License
This project is licensed under the MIT License - see the LICENSE file for details.
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Note
This is an MCP-compatible server that interacts with Google services. Make sure you have appropriate permissions and credentials before using the tool.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.