MCP Hub
Back to servers

Google Sheets MCP Server

A Google Sheets MCP server that treats spreadsheets as queryable database tables, enabling full CRUD operations on sheets and rows via SSE or stdio transports.

Tools
9
Updated
Jan 10, 2026

Google Sheets MCP Server

An MCP (Model Context Protocol) server that provides tools for interacting with Google Sheets. Designed to run as a Google Cloud Function and proxies requests to the sheets-db-api.

Features

  • Full CRUD operations for sheets and rows
  • Treats Google Sheets as a database with sheets as tables
  • SSE transport for HTTP-based MCP communication
  • No authentication required (proxies to authenticated sheets-db-api)

Available Tools

ToolDescriptionParameters
list_sheetsList all sheets in the spreadsheetspreadsheet_id
create_sheetCreate a new sheetspreadsheet_id, sheet_name
delete_sheetDelete a sheetspreadsheet_id, sheet_name
get_schemaGet column headersspreadsheet_id, sheet_name
get_rowsGet all rows from a sheetspreadsheet_id, sheet_name
get_rowGet a specific row by indexspreadsheet_id, sheet_name, row_index
create_rowAdd a new rowspreadsheet_id, sheet_name, data
update_rowUpdate an existing rowspreadsheet_id, sheet_name, row_index, data
delete_rowDelete a rowspreadsheet_id, sheet_name, row_index

Installation

npm install

Build

npm run build

Deployment

Deploy to Google Cloud Functions:

npm run deploy

Or manually:

gcloud functions deploy google-sheets-mcp \
  --gen2 \
  --runtime=nodejs20 \
  --trigger-http \
  --allow-unauthenticated \
  --entry-point=mcpHandler \
  --source=.

Environment Variables

VariableDescriptionDefault
SHEETS_API_URLURL of the sheets-db-apihttps://sheetsapi-g56q77hy2a-uc.a.run.app

API Endpoints

MethodEndpointDescription
GET/healthHealth check
GET/sseSSE connection for MCP clients
POST/message?sessionId=xxxMessage endpoint for MCP communication

Local Development

With stdio transport (for local MCP clients)

MCP_STDIO=true npm run dev

With HTTP/SSE transport

npm run dev

Usage Example

Once deployed, connect your MCP client to the SSE endpoint:

https://YOUR_CLOUD_FUNCTION_URL/sse

Then use the tools with your Google Spreadsheet ID:

{
  "tool": "list_sheets",
  "arguments": {
    "spreadsheet_id": "1BxiMVs0XRA5nFMdKvBdBZjgmUUqptlbs74OgvE2upms"
  }
}

Row Indexing

  • Row 1 contains headers
  • Data rows start at index 2
  • When using get_row, update_row, or delete_row, use indices >= 2

Reviews

No reviews yet

Sign in to write a review