Excel MCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Excel MCP Server Analyze the sales sheet and format the top row with a blue background"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Excel MCP Server
A cross-platform MCP server for reading, writing, and formatting Excel files. Works with both open Excel workbooks (live) and closed .xlsx files (no Excel needed).
Two Modes
workbook— Operate on an open Excel workbook in real-time via xlwingspath— Edit closed .xlsx files directly using pure Python (preserves images, charts, and all embedded content)
Related MCP server: xlwings Excel MCP Server
Tools
Tool | workbook | path | Required |
| - | - | (none) |
| OK | OK | range |
| OK | OK | range, value |
| OK | OK | range, format |
| OK | - | workbook, code |
Requirements
Node.js 18+
Python 3.8+
xlwings (for live Excel mode —
pip install xlwings)Microsoft Excel (only needed for
workbookmode andexecute_vba)
Works on Windows and macOS. The path mode also works on Linux.
Installation
git clone https://github.com/kousunh/excel-mcp-server.git
cd excel-mcp-server
npm install
pip install -r scripts/requirements.txtConfigure MCP Client
Add to your MCP client config (Claude Desktop, Cursor, etc.):
{
"mcpServers": {
"excel-mcp": {
"command": "node",
"args": ["/path/to/excel-mcp-server/src/index.js"]
}
}
}To use a specific Python executable, set the EXCEL_MCP_PYTHON environment variable:
{
"mcpServers": {
"excel-mcp": {
"command": "node",
"args": ["/path/to/excel-mcp-server/src/index.js"],
"env": {
"EXCEL_MCP_PYTHON": "/path/to/python"
}
}
}
}Usage
Closed files (path mode)
read_cells path="/data/report.xlsx" range="A1:D20" formats=true
write_cells path="/data/report.xlsx" range="A1:C3" value=[["Name","Age","City"],["Alice",30,"NYC"],["Bob",25,"LA"]]
format_cells path="/data/report.xlsx" range="A1:C1" format={"bold":true,"backgroundColor":"#4472C4","fontColor":"#FFFFFF"}No Excel installation required. Images, charts, and shapes are preserved.
Open workbooks (workbook mode)
get_excel_info
read_cells workbook="Sales.xlsx" range="B2:F10"
write_cells workbook="Sales.xlsx" range="G2" value="=SUM(B2:F2)"
execute_vba workbook="Sales.xlsx" code="Range(\"A1:G10\").AutoFilter"Requires Excel to be running with the workbook open.
License
MIT
Available Tools
5 toolsexecute_vbaA
Execute VBA code in an open workbook (live Excel only, cannot use with closed files). Code is wrapped in a Sub automatically if needed. MsgBox calls are stripped. Temp modules are cleaned up after execution.
Inputs: workbook (required), code (required), sheet.
format_cellsA
Apply formatting to cells. Use "workbook" for live Excel, or "path" for a .xlsx file on disk (no Excel needed, preserves images/charts). Options: bold, italic, underline, fontSize, fontName, fontColor, backgroundColor, textAlign (left/center/right), verticalAlign (top/middle/bottom), numberFormat, wrapText, borders ({top/bottom/left/right/inside/outside: {style, color}}).
Inputs: range (required), format (required), workbook, path, +1 more.
get_excel_infoB
Get Excel running status, open workbooks, and their sheets.
Inputs: no named parameters.
read_cellsA
Read cell formulas/values from a range. By default returns formulas where they exist. Use "workbook" for an open Excel workbook, or "path" for a .xlsx file on disk (no Excel needed, preserves images/charts). Set valuesOnly=true to get calculated values instead of formulas. Set formats=true to include formatting details.
Inputs: range (required), workbook, path, sheet, +2 more.
write_cellsA
Write values to a cell or range. Use "workbook" for live Excel, or "path" for a .xlsx file on disk (no Excel needed, preserves images/charts). Accepts a single value, a flat array, or a 2D array.
Inputs: range (required), value (required), workbook, path, +1 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 5 tools
Each tool has a clearly distinct purpose with no overlap: execute_vba runs code, format_cells applies styling, get_excel_info retrieves metadata, read_cells extracts data, and write_cells inserts data. The descriptions explicitly differentiate between live Excel and file-based operations where applicable, eliminating ambiguity.
All tool names follow a consistent verb_noun pattern (execute_vba, format_cells, get_excel_info, read_cells, write_cells) with clear, descriptive verbs. There are no deviations in style or convention, making the set predictable and easy to understand.
With 5 tools, this server is well-scoped for basic Excel operations, covering execution, formatting, information retrieval, reading, and writing. Each tool earns its place without redundancy, and the count is appropriate for the domain, avoiding both excessive complexity and oversimplification.
The toolset provides solid coverage for core Excel workflows, including CRUD-like operations (read/write), formatting, and automation (VBA). Minor gaps exist, such as no explicit tools for managing sheets (e.g., create/delete sheets) or advanced features like charts, but agents can likely work around these with the available tools.
Maintenance
Related MCP Connectors
The Excel engine for AI agents: read, check and edit Excel models over MCP.
Open, inspect, filter, edit and convert xlsx and csv files from your AI chat. Processing is local.
Open, inspect, filter, edit and convert xlsx and csv files from your AI chat. Processing is local.
Convert, create and edit Word, PowerPoint, Excel and PDF documents from any AI agent.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables AI agents to directly create, read, edit, and save Excel (.xlsx) spreadsheets using natural language through the Model Context Protocol, supporting cells, sheets, formatting, and formulas without writing Python code.216MIT
- FlicenseBqualityDmaintenanceEnables Excel automation via natural language, providing session-based workbook management, data manipulation, formulas, charts, and formatting through the Model Context Protocol.29-
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to automate Microsoft Excel tasks such as reading/writing cells, formatting, creating charts, and managing sheets through natural language using the Model Context Protocol.1Apache 2.0
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to read, write, analyze, and transform Excel spreadsheets (.xlsx) through the Model Context Protocol.MIT