Excel Automation Reference¶
This is the reference corpus that ships inside the Excel MCP Server agent skills and as MCP prompts. It is written as instruction for an AI agent — terse, imperative, and specific about what Excel actually does rather than what its documentation implies.
It is published here because the same material is useful to anyone automating Excel, whether through this project or not.
For task walkthroughs, start with the guides. For the complete operation catalogue, see the features reference.
Working with agents¶
- Key Constraints & Sequencing — what must happen before what
- Behavioral Rules — verification and destructive-operation safety
- Anti-Patterns to Avoid — common mistakes and the correct approach
- Gotchas & Known Limits — surprising Excel behaviour and workarounds
- Agent Mode in Excel — watching an agent drive the visible Excel window
Workbooks, sheets and cells¶
- Workbook Lifecycle
- Worksheet Operations
- Ranges, Number Formats & Formatting
- Excel Tables
- Window Management
Data and the model¶
- Power Query
- M Code Syntax
- Data Model & DAX
- DMV Query Reference
- PivotTables
- QueryTables
- What-If Analysis
- XML Maps