sheets-mcp-server
An MCP server that lets AI agents read and write Google Sheets using the Google Sheets API v4.
README
sheets-mcp-server
An MCP server that lets AI agents read and write Google Sheets. Built with the Model Context Protocol and the Google Sheets API v4.
Tools
| Tool | Description |
|---|---|
sheets_read |
Read data from a range in a Google Sheet |
sheets_write |
Write a 2D array of values to a range |
sheets_append |
Append rows to the end of a sheet |
sheets_create |
Create a new spreadsheet with custom tabs |
sheets_info |
Get spreadsheet metadata (title, sheets, dimensions) |
sheets_format |
Apply bold, background color, or text color to a range |
Setup
1. Create a Google Cloud project
- Go to the Google Cloud Console.
- Click Select a project > New Project.
- Give it a name and click Create.
2. Enable the Google Sheets API
- In the Cloud Console, go to APIs & Services > Library.
- Search for Google Sheets API and click Enable.
3. Create a service account
- Go to APIs & Services > Credentials.
- Click Create Credentials > Service account.
- Give it a name (e.g.
sheets-mcp) and click Done. - Click the new service account, go to the Keys tab.
- Click Add Key > Create new key > JSON and download the file.
- Save the JSON key file somewhere secure (e.g.
~/.config/sheets-mcp/service-account.json).
4. Share your spreadsheets
Open any Google Sheet you want the server to access, click Share, and add the service account email address (found in the JSON key file under client_email). Grant Editor access.
5. Set the environment variable
export GOOGLE_SERVICE_ACCOUNT_KEY=/path/to/service-account.json
Or create a .env file in the project directory:
GOOGLE_SERVICE_ACCOUNT_KEY=/path/to/service-account.json
Installation
# With pip
pip install .
# Or with uv
uv pip install .
Claude Desktop configuration
Add this to your Claude Desktop config file (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
{
"mcpServers": {
"sheets": {
"command": "sheets-mcp",
"env": {
"GOOGLE_SERVICE_ACCOUNT_KEY": "/path/to/service-account.json"
}
}
}
}
Or if running from the source directory with uv:
{
"mcpServers": {
"sheets": {
"command": "uv",
"args": ["run", "--directory", "/path/to/sheets-mcp", "sheets-mcp"],
"env": {
"GOOGLE_SERVICE_ACCOUNT_KEY": "/path/to/service-account.json"
}
}
}
}
Example usage
Once connected, an AI agent can use the tools like this:
Read data:
Read cells A1 through D10 from spreadsheet
1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgVE2upms
Write data:
Write these sales figures to Sheet1!A1:C3: [["Product", "Q1", "Q2"], ["Widget", 150, 230], ["Gadget", 320, 180]]
Create a new spreadsheet:
Create a new spreadsheet called "Project Tracker" with tabs "Tasks", "Timeline", and "Budget"
Format headers:
Bold the header row A1:E1 and give it a blue background (#4285F4) with white text (#FFFFFF)
Append rows:
Append these new entries to the bottom of the log in Sheet1: [["2026-03-13", "Completed review", "Alice"]]
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.