
sheet mcp
通过 Claude 聊天直接读取、写入和管理 Google Sheets 的 MCP 服务器。
Repository Info
About This Server
通过 Claude 聊天直接读取、写入和管理 Google Sheets 的 MCP 服务器。
Model Context Protocol (MCP) - This server can be integrated with AI applications to provide additional context and capabilities, enabling enhanced AI interactions and functionality.
Documentation
Google Sheets MCP Server
An MCP server to read, write, and manage Google Sheets directly through Claude chat.
Features
- List all available spreadsheets
- Open spreadsheets by title or URL
- Create new spreadsheets and worksheets
- Read data from worksheets (entire sheet or specific ranges)
- Update individual cells or ranges of cells
- Append rows to worksheets
Quick Setup
Prerequisites
- Google Sheets API Credentials:
- Go to Google Cloud Console
- Create a new project
- Enable the Google Sheets API and Google Drive API
- Create a Service Account
- Download the JSON credentials file
- Share your target Google Sheets with the service account email
Installing via Smithery (Recommended)
To install Google Sheets MCP Server for Claude Desktop automatically via Smithery:
npx -y @smithery/cli install sheets-mcp --client claude
Manual Installation
- Clone the repository:
git clone https://github.com/yourusername/sheets-mcp.git
- Install UV globally using Homebrew in Terminal:
brew install uv
-
Create claude_desktop_config.json:
- For MacOS: Open directory
~/Library/Application Support/Claude/and create the file inside it - For Windows: Open directory
%APPDATA%/Claude/and create the file inside it
- For MacOS: Open directory
-
Add this configuration to claude_desktop_config.json:
{
"mcpServers": {
"sheets_mcp": {
"command": "uv",
"args": [
"--directory",
"/path/to/sheets-mcp",
"run",
"sheets-mcp"
],
"env": {
"GOOGLE_SHEETS_CREDENTIALS_FILE": "/path/to/your-credentials.json"
}
}
}
}
-
Update the config file:
- Replace
/path/to/sheets-mcpwith your actual repository path - Replace
/path/to/your-credentials.jsonwith the path to your Google Service Account credentials JSON file
- Replace
-
Quit Claude completely and reopen it
Usage Examples
- "Show me all my available spreadsheets"
- "Open my Budget 2025 spreadsheet"
- "List all worksheets in my spreadsheet"
- "Read data from my Expenses worksheet"
- "Update cell A1 to 'Total Expenses' in my Budget worksheet"
- "Add a new row with today's expenses"
- "Create a new spreadsheet called 'Project Tracker'"
Troubleshooting
If not working:
- Make sure UV is installed globally (if not, uninstall with
pip uninstall uvand reinstall withbrew install uv) - Or find UV path with
which uvand replace"command": "uv"with the full path - Verify your Google Sheets API credentials file exists and is correctly referenced
- Check if the sheets-mcp path in config matches your actual repository location
- Ensure your Google Service Account has access to the spreadsheets you're trying to read/write
API Reference
Available Tools
-
list_spreadsheets
- Lists all available spreadsheets
- No parameters required
-
open_spreadsheet
- Opens a spreadsheet by title or URL
- Parameters:
identifier(string) - The title or URL of the spreadsheet
-
list_worksheets
- Lists all worksheets in a spreadsheet
- Parameters:
spreadsheet_id(string) - The ID of the spreadsheet
-
read_worksheet
- Reads data from a worksheet
- Parameters:
spreadsheet_id(string) - The ID of the spreadsheetworksheet_name(string) - The name of the worksheetrange(string, optional) - The range to read (e.g., 'A1:D10')
-
update_cell
- Updates a single cell in a worksheet
- Parameters:
spreadsheet_id(string) - The ID of the spreadsheetworksheet_name(string) - The name of the worksheetcell(string) - The cell reference (e.g., 'A1')value(string/number/boolean) - The value to write
-
update_range
- Updates a range of cells in a worksheet
- Parameters:
spreadsheet_id(string) - The ID of the spreadsheetworksheet_name(string) - The name of the worksheetrange(string) - The range to update (e.g., 'A1:B2')values(2D array) - The values to write
-
append_row
- Appends a row to a worksheet
- Parameters:
spreadsheet_id(string) - The ID of the spreadsheetworksheet_name(string) - The name of the worksheetvalues(array) - The values to append as a new row
-
create_spreadsheet
- Creates a new spreadsheet
- Parameters:
title(string) - The title for the new spreadsheet
-
create_worksheet
- Creates a new worksheet in an existing spreadsheet
- Parameters:
spreadsheet_id(string) - The ID of the spreadsheettitle(string) - The title for the new worksheetrows(integer, optional) - Number of rows (default: 100)cols(integer, optional) - Number of columns (default: 26)
Quick Start
Clone the repository
git clone https://github.com/ushishu/sheet-mcpInstall dependencies
cd sheet-mcp
npm installFollow the documentation
Check the repository's README.md file for specific installation and usage instructions.
Repository Details
Recommended MCP Servers
Discord MCP
Enable AI assistants to seamlessly interact with Discord servers, channels, and messages.
Knit MCP
Connect AI agents to 200+ SaaS applications and automate workflows.
Apify MCP Server
Deploy and interact with Apify actors for web scraping and data extraction.
BrowserStack MCP
BrowserStack MCP Server for automated testing across multiple browsers.
Zapier MCP
A Zapier server that provides automation capabilities for various apps.