agent-spreadsheet: Excel for AI agents
agent-spreadsheet
An MCP server, CLI and SDK for agents: read and edit Excel workbooks, recalculate formulas, prove changes without UI automation
- 65 ★ on the repository
- Last commit
- Apache-2.0
Extended access
Why this level
- With writing enabled the agent changes workbooks in the workspace, and overwriting originals is a separate switch
- Cell contents reach the agent context and may carry instructions from others
Install
- Works in
Manual install
cargo install agent-spreadsheet-mcpInstalls the MCP server through Cargo. A Docker image and an install script also exist.
Access and checks
How we reviewExtended accessThe tool runs code or makes network calls and only reads external data.
- With writing enabled the agent changes workbooks in the workspace, and overwriting originals is a separate switch
- Cell contents reach the agent context and may carry instructions from others
This is third-party code. Review the repository files before installing.
What it does
agent-spreadsheet gives an agent one layer for spreadsheet work in three forms: the asp CLI (also agent-spreadsheet), the stateful MCP server agent-spreadsheet-mcp and a TypeScript SDK with an embedded WASM engine. All three share one Rust runtime and a registry of 32 operations. .xlsx and .xlsm files are read and written, and .xls and .xlsb are read only. Formula recalculation runs on the Rust Formualizer engine: formula parsing, a dependency graph and more than 400 Excel functions. The agent recalculates the real workbook, sees which cells changed and why, and confirms it with asp verify proof and asp verify diff. Editing is cautious: preview modes, table and footer-aware row appends, template row cloning, named ranges, formula-only replace and sessions with a log, branches and undo. Replies are machine-readable with pagination and compact modes to save tokens.
Who it is for. Analysts, finance people and developers who need an agent to edit working Excel files with formula recalculation and result verification.
Good fit when
- The agent should append rows to a table with totals and keep the formulas
- After an edit you must prove which cells changed and why
- Before a big workbook rework you need structural impact analysis
- A block of rows should be cloned from a template row by data
- Multi-turn workbook editing runs with undo and branching
Not a fit when
- Workbooks in .xls and .xlsb: they open read-only
- You need work with a live Excel window and macros: the tool does not drive the app interface
- A single formula on a sheet: fixing it by hand is faster than starting a server
Example request
Open budget.xlsx, append an expense row to the table on the Q4 sheet without breaking totals, recalculate and show which cells changed.MCP
- Transport
- http, stdio
- Authentication
- not required
Environment variables
SPREADSHEET_MCP_WORKSPACE- Workbook folder, the current one by default
SPREADSHEET_MCP_RECALC_ENABLED- Enables write and recalculation tools
SPREADSHEET_MCP_ALLOW_OVERWRITE- Allows overwriting original files in save_fork
Limitations
Writing and recalculation in the MCP server are off by default and enabled with SPREADSHEET_MCP_RECALC_ENABLED, and overwriting the source file requires SPREADSHEET_MCP_ALLOW_OVERWRITE. The workbook folder is set by SPREADSHEET_MCP_WORKSPACE and the server can be locked to a single workbook. For some recalculation scenarios you can pick LibreOffice instead of the built-in engine. The install script runs through curl, so read it before running. The README is long and developer-oriented, and the version at check time was 0.16.
How to disable. Remove the agent-spreadsheet block from the client config, then cargo uninstall agent-spreadsheet-mcp or brew uninstall agent-spreadsheet. The server stores no workbooks and reads them from the configured folder.
FAQ
Which files are supported?
.xlsx and .xlsm for reading and writing, .xls and .xlsb for discovery and reading only. Saving over the original file is off by default.
Why is it better than UI automation?
The agent works with the workbook itself: it recalculates formulas, sees cell changes and checks the result with verify commands. There are no fragile clicks on an Excel window.
How are changes protected?
There are write previews, output modes without overwriting, sessions with a log, branches and undo, and structural impact analysis before a big edit.
What address does the MCP server use?
HTTP on 127.0.0.1:8079 by default with POST /mcp and the canonical /v1 route. The stdio transport is enabled by SPREADSHEET_MCP_TRANSPORT.
Can it be used without a server?
Yes, the asp CLI works with files directly, and the TypeScript SDK runs the embedded WASM engine in-process without a server.
Discussion
No questions or reviews yet.
Related
MCP serversoffice-oxide-mcp: Office and PDF for AI agents
office-oxide-mcp
A Rust MCP server that reads and creates Excel, Word, PowerPoint and PDF locally and fills PDF forms after your approval
An MCP server to create and edit Excel files without Microsoft Office: formulas, formatting, charts, pivot tables
Excel MCP Server (negokaz): read and write Excel
Excel MCP Server (negokaz)
An MCP server that reads and writes Excel workbooks: values, formulas, tables, formatting and new sheets; on Windows it can also capture a sheet screenshot
A Python package, CLI and MCP server: Excel workbooks become structured JSON for LLMs and edits go through patches with a dry run
A framework where an agent writes a spreadsheet as React and open-sheet builds a live .xlsx from references.
MCP for PDF and ebook files: the agent finds books in a folder and reads EPUB and PDF by chapter and page, with contents and metadata as Markdown
Comparison with similar tools
Cards that share the main search query, and how they differ.
| Tool | Official | Authentication | Repository stars | Main difference |
|---|---|---|---|---|
| agent-spreadsheet: Excel for AI agents (this card) | no | not required | 65 | |
| Excel MCP Server | no | not required | 4,297 | an MCP for reading and writing Excel, without formula recalculation or change proofs |
| ExcelMcp | no | not required | 887 | another MCP for Excel, a separate implementation |
README in short
The README explains the three product forms and the shared engine, lists safe editing and verification techniques, then comes installation, an MCP quick start, an environment variable table and a CLI command reference.