Sheets MCP

v1.4.0
io.github.atc07/sheets-mcp Checked 1 hour ago Published 1 month ago

Google Sheets for agent workflows in Claude Code and Claude Desktop: APIs, files, schedules, undo.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

google_accounts Google accounts

Manage the Google accounts Sheets MCP can use. list: show signed-in accounts and the default. add: sign in to a Google account (opens a browser sign-in; also use this when a sign-in has expired). remove: sign an account out and revoke access. set_default: choose the account used for new spreadsheets.

ParameterTypeDescription
action *string
emailstringFor remove/set_default: the account's email or a unique part of it

find_spreadsheet Find a spreadsheet

Find a spreadsheet by name among the ones the user has opened or created with Sheets MCP before (the list is kept on their computer). Use it when the user names a sheet instead of pasting a link, e.g. "my budget sheet". It can't search the rest of their Google Drive: if nothing matches, ask for the link. Leave query empty to list the most recent.

ParameterTypeDescription
querystringAll or part of the spreadsheet's name

create_spreadsheet Create a spreadsheet

Create a new Google Sheets spreadsheet.

ParameterTypeDescription
title *string
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
sheet_namesarrayTab names (default: one tab)

get_spreadsheet_info Spreadsheet overview

Get a spreadsheet's title, tabs (sizes, frozen rows/cols), charts (ids, types, data ranges), named ranges, and the first few rows of each tab. Call this first to understand a sheet's layout.

ParameterTypeDescription
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
preview_rowsinteger

read_range Read cells

Read cell contents from a range, or its formatting with mode "formats". Large ranges are truncated; use next_range to continue.

ParameterTypeDescription
range *stringA1 range, e.g. "Sheet1!A1:D20", "'My Tab'!B:B", or a tab name
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
max_cellsinteger
modestringvalues = as displayed; formulas = show formulas instead of results; raw = unformatted numbers; formats = cell formatting (fill, font, alignment, number format, borders) as a style table plus a per-row…

read_ranges Read several ranges

Read several ranges in one call, across any tabs. Faster than calling read_range repeatedly. Each range is truncated to its share of max_cells; use its next_range with read_range to continue.

ParameterTypeDescription
ranges *array
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
max_cellsintegerTotal across all ranges
modestringvalues = as displayed; formulas = show formulas instead of results; raw = unformatted numbers

write_range Write cells

Write values and/or formulas starting at the top-left cell of the range. Input is parsed like typing into the UI (formulas, dates, percentages work). Previous contents are saved for undo_last. Returns any formula errors found after writing.

ParameterTypeDescription
range *stringTop-left cell or full range, e.g. "Sheet1!B2"
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
values *array2D array of rows. Strings starting with = are formulas.
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
allow_largebooleanRequired for writes over 10000 cells
dry_runbooleanOnly show what would be overwritten

fill_range Fill cells

Fill cells from a source block, like dragging the fill handle or pasting onto a bigger selection: the source's formulas (relative references shift), values and formatting repeat across the destination. Use it after writing one row or column of formulas to extend them across a table, instead of sending every column. With continue_series, patterns continue instead (1, 2, 3 → 4, 5, 6; Jan → Feb; dates). The destination's previous contents are saved for undo_last. Returns any formula errors found after filling.

ParameterTypeDescription
destination *stringThe cells to fill, e.g. "Model!P25:AE97" (it may include the source). For continue_series it must sit right after, or right before, the source in the same rows or columns
source *stringThe cells to fill from, e.g. "Model!O25:O97"
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
allow_largebooleanRequired for fills over 10000 cells
continue_seriesbooleanExtend the pattern in the source (like the fill handle) instead of repeating it
pastestringall = formulas, values and formatting; formulas = formulas and values without formatting; values = results as plain values; formats = formatting only

append_rows Append rows

Append rows after the last row of data in a table (detected from the given range or tab).

ParameterTypeDescription
range *stringTab name or table range, e.g. "Sales" or "Sales!A:F"
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
values *array2D array of rows. Strings starting with = are formulas.
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.

clear_range Clear cells

Clear values and formulas in a range (formatting is kept). Previous contents are saved for undo_last.

ParameterTypeDescription
range *stringA1 range, e.g. "Sheet1!A1:D20", "'My Tab'!B:B", or a tab name
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
dry_runboolean

find_replace Find and replace

Find and replace text across a tab or the whole spreadsheet. Not undoable - consider read_range first.

ParameterTypeDescription
find *string
replacement *string
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
include_formulasboolean
match_caseboolean
match_entire_cellboolean
sheetstringLimit to this tab (default: all tabs)
use_regexboolean

undo_last Undo last change

Undo the most recent write_range, append_rows, or clear_range made through this server (restores values/formulas only, not formatting or structure). History is kept in memory until the server restarts.

ParameterTypeDescription
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.

manage_tab Manage tabs

Add, delete, rename, or duplicate a tab (sheet).

ParameterTypeDescription
action *string
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
columnsintegerColumn count for add
new_namestringNew name (rename/duplicate)
rowsintegerRow count for add
tabstringExisting tab (for delete/rename/duplicate), or new tab name for add

insert_rows_or_columns Insert rows or columns

Insert blank rows or columns before a given row number or column letter.

ParameterTypeDescription
before *stringRow number (e.g. "5") or column letter (e.g. "C") to insert before
dimension *string
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
countinteger
tabstringTab name (default: first tab)

delete_rows_or_columns Delete rows or columns

Delete entire rows (e.g. "Sheet1!5:7") or columns (e.g. "Sheet1!C:D"). Not undoable.

ParameterTypeDescription
range *stringWhole-row range like "Tab!5:7" or whole-column range like "Tab!C:D"
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.

freeze Freeze rows or columns

Freeze header rows and/or columns on a tab. Use 0 to unfreeze.

ParameterTypeDescription
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
columnsinteger
rowsinteger
tabstring

resize_columns Resize columns

Set column widths in pixels, or auto-fit them to content when width is omitted.

ParameterTypeDescription
range *stringColumn range like "Sheet1!A:D"
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
widthinteger

merge_cells Merge cells

Merge or unmerge cells in a range.

ParameterTypeDescription
range *stringA1 range, e.g. "Sheet1!A1:D20", "'My Tab'!B:B", or a tab name
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
actionstring
merge_typestring

format_range Format cells

Apply formatting to a range: font styles, colors, number formats, alignment, wrapping, borders. Only provided options are changed. To style several ranges differently in one go, use format_ranges.

ParameterTypeDescription
range *stringA1 range, e.g. "Sheet1!A1:D20", "'My Tab'!B:B", or a tab name
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
background_colorstringHex, e.g. #f1f3f4
boldboolean
bordersobject
clear_formattingbooleanReset all formatting first
font_familystring
font_sizenumber
horizontal_alignmentstring
italicboolean
number_formatobject
strikethroughboolean
text_colorstringHex, e.g. #1a73e8
underlineboolean
vertical_alignmentstring
wrapstring

format_ranges Format several ranges

Apply different formatting to several ranges in one call (same options as format_range, one entry per range): headers, input cells, number formats, borders and so on for a whole tab at once. Ranges may repeat; later entries win where they overlap.

ParameterTypeDescription
items *arrayOne entry per range, each with the formatting to apply there
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.

add_conditional_format Add conditional formatting

Add a conditional formatting rule: either a condition (e.g. NUMBER_GREATER, TEXT_CONTAINS, CUSTOM_FORMULA) with a style, or a color scale.

ParameterTypeDescription
range *stringA1 range, e.g. "Sheet1!A1:D20", "'My Tab'!B:B", or a tab name
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
color_scaleobject
conditionobject

sort_range Sort a range

Sort rows within a range by one or more columns.

ParameterTypeDescription
range *stringA1 range, e.g. "Sheet1!A1:D20", "'My Tab'!B:B", or a tab name
sort_by *array
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
has_headerbooleanKeep the first row of the range in place

set_filter Set a filter

Turn on a basic filter (filter buttons in the header row) for a range, or clear the tab's filter.

ParameterTypeDescription
range *stringData range including header, or tab name when clearing
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
clearboolean

set_data_validation Dropdowns and validation

Add data validation to a range: dropdown list, dropdown from a range, checkbox, number range, custom formula - or clear it.

ParameterTypeDescription
range *stringA1 range, e.g. "Sheet1!A1:D20", "'My Tab'!B:B", or a tab name
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
type *string
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
maxnumber
minnumber
optionsarraydropdown: list items; dropdown_from_range: ["=Lists!A2:A20"]; custom_formula: ["=ISNUMBER(A2)"]
strictbooleanReject invalid input (vs. show a warning)

add_chart Add a chart

Create a chart from a data range. The first column is the X axis/labels; each following column is a series. Use a header row for series names.

ParameterTypeDescription
data_range *stringe.g. "Sales!A1:C13"
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
anchor_cellstringWhere to place the chart's top-left, e.g. "Sales!F2" (default: right of the data)
chart_typestring
has_headerboolean
stackedboolean
titlestring

update_chart Update a chart

Change an existing chart: its title, type, data range, stacking, position or size. Only the options you give are changed. Chart ids come from get_spreadsheet_info or add_chart.

ParameterTypeDescription
chart_id *integer
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
anchor_cellstringMove the chart's top-left corner here, e.g. "Sales!F2"
chart_typestring
data_rangestringNew data, laid out as for add_chart: first column labels, then one column per series
has_headerbooleanUsed with data_range
heightintegerPixels
stackedboolean
titlestring
widthintegerPixels

delete_chart Delete a chart

Delete a chart. Chart ids come from get_spreadsheet_info or add_chart. Not undoable through undo_last.

ParameterTypeDescription
chart_id *integer
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.

add_pivot_table Add a pivot table

Summarize a table with a pivot table: group by one or more columns, and total, count or average others. It goes on a new tab unless anchor_cell is given. The source range needs a header row; refer to columns by header name or letter.

ParameterTypeDescription
source_range *stringThe table to summarize, header row included, e.g. "Orders!A1:F500" or a tab name
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
values *array
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.
anchor_cellstringTop-left cell for the pivot table, e.g. "Summary!A1". The area below and right of it must be empty. Default: a new tab
columnsarrayColumns to group by across the top
new_tab_namestringName for the new tab when anchor_cell isn't given
rowsarrayColumns to group by down the side, e.g. ["Region"]
show_totalsboolean

batch_update Advanced batch update

Send raw Google Sheets API batchUpdate requests for anything the other tools don't cover (e.g. named ranges, protected ranges, pivot tables, row heights, hiding rows, updating charts). Requests use sheetId numbers from get_spreadsheet_info.

ParameterTypeDescription
requests *arrayArray of Request objects, see developers.google.com/sheets/api/reference/rest/v4/spreadsheets/request
spreadsheet *stringGoogle Sheets link or spreadsheet ID. The name of a spreadsheet used with Sheets MCP before also works
accountstringGoogle account to use: an email or unique part of one (e.g. "acme.com"). Default: the account that can open the spreadsheet, else the default account.