This server brings Excel's COM API to Claude through 25 tools covering Power Query workflows, DAX measures, VBA execution, PivotTables, charts, and range operations. It's Windows only because it automates your actual Excel process, not server side spreadsheet manipulation. You get 230 operations total: create tables with structured references, manage data model relationships, export M code for version control, apply conditional formatting, even capture screenshots for visual verification. The agent mode shows Excel side by side so you watch changes happen in real time. If you're already on Windows with Excel installed and need to automate complex workbooks through conversation rather than writing VBA or Python scripts, this connects those capabilities directly to your AI assistant.
Public tool metadata for what this MCP can expose to an agent.
EXCEL_ADD_CHARTAdd a chart to a worksheet using Microsoft Graph API.6 paramsAdd a chart to a worksheet using Microsoft Graph API.
typestringitem_idstringseriesbystringworksheetstringsession_idstringsourcedatastringEXCEL_ADD_SHAREPOINT_WORKSHEETAdd a new worksheet to a SharePoint Excel workbook using Microsoft Graph Sites API.4 paramsAdd a new worksheet to a SharePoint Excel workbook using Microsoft Graph Sites API.
namestringitem_idstringsite_idstringsession_idstringEXCEL_ADD_TABLECreate a new table in a worksheet using the Microsoft Graph API.5 paramsCreate a new table in a worksheet using the Microsoft Graph API.
addressstringitem_idstringworksheetstringhasHeadersbooleansession_idstringEXCEL_ADD_TABLE_COLUMNAdd a column to a table using Microsoft Graph API.5 paramsAdd a column to a table using Microsoft Graph API.
indexintegervaluesarrayitem_idstringtable_idstringsession_idstringEXCEL_ADD_TABLE_ROWAdd a row to a table using Microsoft Graph API.5 paramsAdd a row to a table using Microsoft Graph API.
indexintegervaluesarrayitem_idstringtable_idstringsession_idstringEXCEL_ADD_WORKBOOK_PERMISSIONTool to grant access to a workbook via invite. Use when you need to share a specific workbook file with designated recipients and roles.9 paramsTool to grant access to a workbook via invite. Use when you need to share a specific workbook file with designated recipients and roles.
rolesarrayitem_idstringmessagestringpasswordstringrecipientsarrayrequireSignInbooleansendInvitationbooleanexpirationDateTimestringretainInheritedPermissionsbooleanEXCEL_ADD_WORKSHEETAdd a new worksheet to an Excel workbook using Microsoft Graph API.3 paramsAdd a new worksheet to an Excel workbook using Microsoft Graph API.
namestringitem_idstringsession_idstringEXCEL_APPLY_TABLE_FILTERApply a filter to a table column using Microsoft Graph API.6 paramsApply a filter to a table column using Microsoft Graph API.
item_idstringcriteriaobjecttable_idstringcolumn_idstringworksheetstringsession_idstringEXCEL_APPLY_TABLE_SORTApply a sort to a table using Microsoft Graph API.5 paramsApply a sort to a table using Microsoft Graph API.
fieldsarrayitem_idstringtable_idstringworksheetstringsession_idstringEXCEL_CLEAR_RANGETool to clear values, formats, or contents in a specified worksheet range. Use when you need to reset cells before adding new data.5 paramsTool to clear values, formats, or contents in a specified worksheet range. Use when you need to reset cells before adding new data.
addressstringapplyTostringAll · Formats · Contentsitem_idstringsession_idstringworksheet_idstringEXCEL_CLEAR_TABLE_FILTERClear a filter from a table column using Microsoft Graph API.5 paramsClear a filter from a table column using Microsoft Graph API.
item_idstringtable_idstringcolumn_idstringworksheetstringsession_idstringEXCEL_CLOSE_SESSIONTool to close an existing Excel workbook session. Use when you need to explicitly end a persistent session to release workbook locks.2 paramsTool to close an existing Excel workbook session. Use when you need to explicitly end a persistent session to release workbook locks.
item_idstringsession_idstringEXCEL_CONVERT_TABLE_TO_RANGEConvert a table to a range using Microsoft Graph API.3 paramsConvert a table to a range using Microsoft Graph API.
item_idstringtable_idstringsession_idstringEXCEL_CREATE_WORKBOOKTool to create a new Excel workbook file at a specified drive path. Generates a new .xlsx file with specified worksheets and data, then uploads it to OneDrive.4 paramsTool to create a new Excel workbook file at a specified drive path. Generates a new .xlsx file with specified worksheets and data, then uploads it to OneDrive.
pathstringdrive_idstringworksheet_dataobjectworksheet_namesarrayEXCEL_DELETE_TABLE_COLUMNDelete a column from a table using Microsoft Graph API.4 paramsDelete a column from a table using Microsoft Graph API.
item_idstringtable_idstringcolumn_idstringsession_idstringEXCEL_DELETE_TABLE_ROWDelete a row from a table using Microsoft Graph API.4 paramsDelete a row from a table using Microsoft Graph API.
item_idstringtable_idstringrow_indexintegersession_idstringEXCEL_DELETE_WORKSHEETTool to delete a worksheet from the workbook. Use when cleaning up unused or temporary sheets after verifying no dependencies exist. Example: "Delete 'Sheet2' after review."3 paramsTool to delete a worksheet from the workbook. Use when cleaning up unused or temporary sheets after verifying no dependencies exist. Example: "Delete 'Sheet2' after review."
item_idstringworksheetstringsession_idstringEXCEL_GET_CHART_AXISTool to retrieve a specific axis from a chart. Use when you need properties like min, max, interval, and formatting of the chart axis.7 paramsTool to retrieve a specific axis from a chart. Use when you need properties like min, max, interval, and formatting of the chart axis.
expandstringselectstringitem_idstringaxis_typestringvalueAxis · seriesAxis · categoryAxisworksheetstringchart_namestringsession_idstringEXCEL_GET_CHART_DATA_LABELSTool to retrieve the data labels object of a chart. Use when you need to inspect label settings like position, separator, and visibility flags after creating or updating a chart.4 paramsTool to retrieve the data labels object of a chart. Use when you need to inspect label settings like position, separator, and visibility flags after creating or updating a chart.
item_idstringchart_idstringsession_idstringworksheet_idstringEXCEL_GET_CHART_LEGENDTool to retrieve the legend object of a chart. Use after creating or updating a chart when you need to inspect legend visibility and formatting.6 paramsTool to retrieve the legend object of a chart. Use after creating or updating a chart when you need to inspect legend visibility and formatting.
expandstringselectstringitem_idstringchart_namestringsession_idstringworksheet_idstringEXCEL_GET_RANGEGet a range from a worksheet using Microsoft Graph API.4 paramsGet a range from a worksheet using Microsoft Graph API.
addressstringitem_idstringsession_idstringworksheet_idstringEXCEL_GET_SESSIONCreate a session for an Excel workbook using Microsoft Graph API.2 paramsCreate a session for an Excel workbook using Microsoft Graph API.
item_idstringpersist_changesbooleanEXCEL_GET_SHAREPOINT_RANGEGet a range from a worksheet in SharePoint using Microsoft Graph Sites API.5 paramsGet a range from a worksheet in SharePoint using Microsoft Graph Sites API.
addressstringitem_idstringsite_idstringsession_idstringworksheet_idstringEXCEL_GET_SHAREPOINT_WORKSHEETGet a worksheet by name or ID from a SharePoint Excel workbook using Microsoft Graph Sites API.4 paramsGet a worksheet by name or ID from a SharePoint Excel workbook using Microsoft Graph Sites API.
item_idstringsite_idstringworksheetstringsession_idstringEXCEL_GET_TABLE_COLUMNTool to retrieve a specific column from a workbook table. Use when you need to fetch column properties and data by its ID or name.4 paramsTool to retrieve a specific column from a workbook table. Use when you need to fetch column properties and data by its ID or name.
item_idstringtable_idstringcolumn_idstringsession_idstringEXCEL_GET_WORKBOOKTool to retrieve the properties and relationships of a workbook. Use when you need to inspect comments, names, tables, or worksheets.4 paramsTool to retrieve the properties and relationships of a workbook. Use when you need to inspect comments, names, tables, or worksheets.
expandarrayitem_idstringdrive_idstringsession_idstringEXCEL_GET_WORKSHEETGet a worksheet by name or ID from an Excel workbook using Microsoft Graph API.3 paramsGet a worksheet by name or ID from an Excel workbook using Microsoft Graph API.
item_idstringworksheetstringsession_idstringEXCEL_INSERT_RANGETool to insert a new cell range into a worksheet, shifting existing cells down or right. Use when you need to create space for new content without overwriting.5 paramsTool to insert a new cell range into a worksheet, shifting existing cells down or right. Use when you need to create space for new content without overwriting.
shiftstringDown · Rightaddressstringitem_idstringsession_idstringworksheet_idstringEXCEL_LIST_CHARTSList charts in a worksheet using Microsoft Graph API.3 paramsList charts in a worksheet using Microsoft Graph API.
item_idstringworksheetstringsession_idstringEXCEL_LIST_CHART_SERIESTool to list all data series in a chart. Use when you need to enumerate chart series for further analysis.4 paramsTool to list all data series in a chart. Use when you need to enumerate chart series for further analysis.
item_idstringworksheetstringchart_namestringsession_idstringEXCEL_LIST_COMMENTSTool to list comments in an Excel workbook. Use when you need to retrieve all workbook comments via Microsoft Graph API.2 paramsTool to list comments in an Excel workbook. Use when you need to retrieve all workbook comments via Microsoft Graph API.
item_idstringsession_idstringEXCEL_LIST_FILESList files and folders in a drive root or specified path.2 paramsList files and folders in a drive root or specified path.
pathstringdrive_idstringEXCEL_LIST_NAMED_ITEMSList named items in a workbook using Microsoft Graph API.2 paramsList named items in a workbook using Microsoft Graph API.
item_idstringsession_idstringEXCEL_LIST_SHAREPOINT_TABLESList tables in a SharePoint worksheet using Microsoft Graph Sites API.4 paramsList tables in a SharePoint worksheet using Microsoft Graph Sites API.
item_idstringsite_idstringworksheetstringsession_idstringEXCEL_LIST_SHAREPOINT_WORKSHEETSList worksheets in an Excel workbook stored in SharePoint using Microsoft Graph Sites API.3 paramsList worksheets in an Excel workbook stored in SharePoint using Microsoft Graph Sites API.
item_idstringsite_idstringsession_idstringEXCEL_LIST_TABLE_COLUMNSList columns in a table using Microsoft Graph API.3 paramsList columns in a table using Microsoft Graph API.
item_idstringtable_idstringsession_idstringEXCEL_LIST_TABLE_ROWSList rows in a table using Microsoft Graph API.3 paramsList rows in a table using Microsoft Graph API.
item_idstringtable_idstringsession_idstringEXCEL_LIST_TABLESList tables in a worksheet using Microsoft Graph API. This action retrieves information about all tables present in a specified worksheet of an Excel file. It requires the file ID and worksheet name or ID, and can optionally use a session ID for workbook operations.3 paramsList tables in a worksheet using Microsoft Graph API. This action retrieves information about all tables present in a specified worksheet of an Excel file. It requires the file ID and worksheet name or ID, and can optionally use a session ID for workbook operations.
item_idstringworksheetstringsession_idstringEXCEL_LIST_WORKBOOK_PERMISSIONSTool to list permissions set on the workbook file. Use when you need to see which users or links have access to a specific Excel file by supplying its drive and item IDs. Example: "List permissions for workbook with drive_id 'b!abc123' and item_id '0123456789abcdef'."6 paramsTool to list permissions set on the workbook file. Use when you need to see which users or links have access to a specific Excel file by supplying its drive and item IDs. Example: "List permissions for workbook with drive_id 'b!abc123' and item_id '0123456789abcdef'."
$topinteger$skipinteger$expandstring$selectstringitem_idstringdrive_idstringEXCEL_LIST_WORKSHEETSList worksheets in an Excel workbook using Microsoft Graph API.2 paramsList worksheets in an Excel workbook using Microsoft Graph API.
item_idstringsession_idstringEXCEL_MERGE_CELLSMerge cells in a worksheet range using Microsoft Graph API.5 paramsMerge cells in a worksheet range using Microsoft Graph API.
rangestringacrossbooleanitem_idstringworksheetstringsession_idstringEXCEL_PROTECT_WORKSHEETTool to protect a worksheet using optional protection options. Use when you need to prevent editing certain parts of a sheet before sharing. Example: "Protect 'Sheet1' to lock formatting and sorting."4 paramsTool to protect a worksheet using optional protection options. Use when you need to prevent editing certain parts of a sheet before sharing. Example: "Protect 'Sheet1' to lock formatting and sorting."
item_idstringoptionsobjectworksheetstringsession_idstringEXCEL_SORT_RANGESort a range in a worksheet using Microsoft Graph API.5 paramsSort a range in a worksheet using Microsoft Graph API.
fieldsarrayitem_idstringworksheetstringrange_typestringsession_idstringEXCEL_UPDATE_CHARTUpdate a chart in a worksheet using Microsoft Graph API.9 paramsUpdate a chart in a worksheet using Microsoft Graph API.
topnumberleftnumbernamestringwidthnumberheightnumberitem_idstringchart_idstringworksheetstringsession_idstringEXCEL_UPDATE_CHART_LEGENDTool to update formatting or position of a chart legend. Use when adjusting legend settings after confirming chart and worksheet exist.7 paramsTool to update formatting or position of a chart legend. Use when adjusting legend settings after confirming chart and worksheet exist.
item_idstringoverlaybooleanvisiblebooleanchart_idstringpositionstringTop · Bottom · Left · Right · Corner · Customworksheetstringsession_idstringEXCEL_UPDATE_RANGEUpdate a range in a worksheet using Microsoft Graph API.5 paramsUpdate a range in a worksheet using Microsoft Graph API.
valuesarrayaddressstringitem_idstringsession_idstringworksheet_idstringEXCEL_UPDATE_SHAREPOINT_RANGEUpdate a range in a SharePoint worksheet using Microsoft Graph Sites API.6 paramsUpdate a range in a SharePoint worksheet using Microsoft Graph Sites API.
valuesarrayaddressstringitem_idstringsite_idstringsession_idstringworksheet_idstringEXCEL_UPDATE_TABLEUpdate a table in a workbook using Microsoft Graph API.7 paramsUpdate a table in a workbook using Microsoft Graph API.
namestringstylestringitem_idstringtable_idstringsession_idstringshowTotalsbooleanshowHeadersbooleanEXCEL_UPDATE_WORKSHEETUpdate worksheet properties (name, position) in an Excel workbook using Microsoft Graph API.5 paramsUpdate worksheet properties (name, position) in an Excel workbook using Microsoft Graph API.
namestringitem_idstringpositionintegerworksheetstringsession_idstringAutomate Excel with AI — A Model Context Protocol (MCP) server for comprehensive Excel automation through conversational AI.
MCP Server for Excel enables AI assistants (GitHub Copilot, Claude, ChatGPT) to automate Excel through natural language commands. Automate Power Query, DAX measures, VBA macros, PivotTables, Charts, formatting, and data transformations (25 tools with 230 operations).
🛡️ 100% Safe - Uses Excel's Native COM API - Zero risk of file corruption. Unlike third-party libraries that manipulate .xlsx files directly, this project uses Excel's official API ensuring complete safety and compatibility.
💡 Interactive Development - See results instantly in Excel. Create a query, run it, inspect the output, refine and repeat. Excel becomes your AI-powered workspace for rapid development and testing.
🧪 LLM-Tested Quality - Tool behavior validated with real LLM workflows using pytest-skill-engineering. We test that LLMs correctly understand and use our tools.
Technical Requirements:
25 specialized tools with 230 operations:
📚 Complete Feature Reference → - Detailed documentation of all 230 operations
Create & Populate Data:
Analysis & Visualization:
Formatting & Styling:
Formatting split: number display formats use the range tool, while visual styling and auto-fit use range_format.
Automation:
🪟 Agent Mode — Watch AI Work in Excel:
Perfect for:
Not suitable for:
| Platform | Installation |
|---|---|
| VS Code | Install Extension (one-click, recommended) |
| Claude Desktop | Download .mcpb from latest release |
| Any MCP Client | Download mcp-excel.exe from latest release and add to PATH |
| Details | 📖 Installation Guide |
⚠️ Important: Close all Excel files before using. The server requires exclusive access to workbooks during automation.
This package provides both CLI and MCP Server interfaces. Choose based on your use case:
| Interface | Best For | Why |
|---|---|---|
CLI (excelcli) | Coding agents (Copilot, Cursor, Windsurf) + Scripting | 64% fewer tokens - single tool, no large schemas. Auto-generated from Core code, ensuring 1:1 feature parity. Bundled with excel-cli skill. |
| MCP Server | Conversational AI (Claude Desktop, VS Code Chat) | Rich tool discovery, persistent connection. Better for interactive, exploratory workflows. |
Installation:
excel-cli plugin for skill guidance, then install excelcli separatelyexcel-cli skill separately when your agent already has excelcli available on PATH⚡ CLI Commands: Generated automatically from Core service definitions using Roslyn source generators. All 22 command categories maintain exact 1:1 parity with MCP tools through shared code generation. See code generation docs for details.
ExcelMcp is available as two GitHub Copilot CLI plugins in the Copilot plugin marketplace:
# Register the plugin marketplace (one-time)
copilot plugin marketplace add sbroenne/mcp-server-excel-plugins
# Install one or both plugins
copilot plugin install excel-mcp@mcp-server-excel-plugins # For conversational AI
copilot plugin install excel-cli@mcp-server-excel-plugins # For scripting / coding agents
excel-mcp — MCP server for conversational workflowsexcel-cli — Skill for coding agents (install excelcli separately if you want the CLI tool)Note: After each release, there may be a short delay before plugins appear in the marketplace. You may need to wait a few moments for updates to sync.
| Metric | CLI | MCP Server | Winner |
|---|---|---|---|
| Tokens | ~59K | ~163K | 🏆 CLI (64% fewer) |
Key insight: MCP sends 23 tool schemas to the LLM on each request (~100K+ tokens).
Manual Installation:
# Primary: Download standalone executables from latest release (no .NET runtime required)
# https://github.com/sbroenne/mcp-server-excel/releases/latest
# - ExcelMcp-MCP-Server-{version}-windows.zip → extract mcp-excel.exe
# - ExcelMcp-CLI-{version}-windows.zip → extract excelcli.exe (optional, for scripting)
# Secondary: Install via .NET tool (requires .NET 10 runtime)
dotnet tool install --global Sbroenne.ExcelMcp.McpServer
dotnet tool install --global Sbroenne.ExcelMcp.CLI
# After installing either way, auto-configure all your coding agents:
npx add-mcp "mcp-excel" --name excel-mcp
⚠️ Step 2 requires Node.js for
npx. Install withwinget install OpenJS.NodeJS.LTSif needed.
# Optional: Install agent skills for better AI guidance
npx skills add sbroenne/mcp-server-excel --skill excel-cli # Coding agents
npx skills add sbroenne/mcp-server-excel --skill excel-mcp # Conversational AI
💡 Skills provide AI guidance - The CLI skill is highly recommended (agents don't work perfectly with CLI without it). The MCP skill is recommended - it adds workflow best practices and reduces token usage.
ExcelMcp uses Windows COM automation to control the actual Excel application (not just .xlsx files).
Both the MCP Server and CLI communicate with a shared ExcelMCP Service that manages Excel sessions. This unified architecture enables:
┌─────────────────────┐ ┌─────────────────────┐
│ MCP Server │ │ CLI (excelcli) │
│ (AI assistants) │ │ (coding agents) │
└─────────┬───────────┘ └─────────┬───────────┘
│ │
└──────────┬────────────────┘
▼
┌─────────────────────────┐
│ ExcelMCP Service │
│ (shared session mgmt) │
└─────────┬───────────────┘
▼
┌─────────────────────────┐
│ Excel COM API │
│ (Excel.Application) │
└─────────────────────────┘
Key Benefits:
💡 Tip: Watch Excel While AI Works By default, Excel runs hidden for faster automation. To see changes in real-time, just ask:
The AI will display the Excel window so you can watch every operation happen live - great for learning or verifying changes!
📚 CLI Guide → | CLI Skill for Agents → | MCP Server Guide → | All Agent Skills →
License: MIT License - see LICENSE file
Privacy: See PRIVACY.md for our privacy policy Contributing: See CONTRIBUTING.md for guidelines
Built With: This entire project was developed using GitHub Copilot AI assistance - mainly with Claude but lately with Auto-mode.
Acknowledgments:
Other projects by the author:
makafeli/n8n-workflow-builder
danishashko/make-mcp
lukisch/n8n-manager-mcp
io.github.us-all/airflow
io.github.infoinlet-marketplace/mcp-workflow