Excel MCP Server
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Excel MCP Agent
An AI-powered Excel automation project built using FastAPI, Model Context Protocol (MCP), Groq LLM, HTTPX, JWT Authentication, and OpenPyXL.
The project enables users to manipulate Excel spreadsheets through natural language by combining an AI agent, an MCP server, and a secure REST API.
Architecture
Natural Language Request
│
▼
Groq LLM Agent
│
▼
MCP Client
│
▼
MCP Server
│
▼
HTTPX API Client (JWT)
│
▼
FastAPI REST API
│
▼
Excel WorkbookRelated MCP server: @node2flow/google-sheets-mcp
Features
Secure REST API using JWT Authentication
AI-powered Excel automation
MCP Server exposing Excel tools
Natural language interaction through Groq LLM
CRUD operations on Excel spreadsheets
Swagger UI documentation
Modular project structure
Automatic JWT handling inside the MCP server
Project Structure
excel_project/
│
├── excel_api/
│ ├── auth.py
│ ├── main.py
│ ├── models.py
│ ├── services.py
│ └── files/
│ └── data.xlsx
│
├── excel_mcp_server/
│ ├── api_client.py
│ ├── config.py
│ └── mcp_server.py
│
├── excel_mcp_client/
│ ├── agent.py
│ ├── client.py
│ ├── llm_config.py
│ ├── main.py
│ └── prompts.py
│
├── requirements.txt
└── README.mdTechnologies Used
Python 3
FastAPI
MCP (Model Context Protocol)
Groq API
HTTPX
OpenPyXL
PyJWT
Pydantic
Uvicorn
Excel API Endpoints
Authentication
Method | Endpoint | Description |
POST |
| Authenticate user and obtain JWT token |
GET |
| Retrieve current authenticated user |
Excel Operations
Method | Endpoint | Description |
POST |
| Insert data into a single Excel cell |
POST |
| Insert data into multiple Excel cells |
DELETE |
| Clear data from a single cell |
DELETE |
| Clear data from a range of cells |
MCP Tools
The MCP server exposes the following tools:
add_data
add_data_range
delete_cell_data
delete_cell_range
These tools internally communicate with the secured FastAPI application.
Authentication Flow
Client
│
▼
POST /auth/login
│
▼
JWT Access Token
│
▼
Authorization: Bearer <token>
│
▼
Protected Excel APIsThe MCP server automatically:
logs in to the FastAPI application
retrieves a JWT token
stores the token
includes the Authorization header in every API request
re-authenticates if required
Installation
Clone the repository.
git clone https://github.com/<your-username>/excel-mcp-agent.gitNavigate to the project.
cd excel-mcp-agentCreate a virtual environment.
python -m venv .venvActivate the virtual environment.
Windows
.venv\Scripts\activateLinux/macOS
source .venv/bin/activateInstall dependencies.
pip install -r requirements.txtEnvironment Variables
Create a .env file in the project root.
GROQ_API_KEY=your_groq_api_key
JWT_SECRET_KEY=your_secret_key
JWT_ALGORITHM=HS256
JWT_ACCESS_TOKEN_EXPIRE_MINUTES=30
API_BASE_URL=http://127.0.0.1:8000
API_USERNAME=admin
API_PASSWORD=admin123Running the FastAPI Server
uvicorn excel_api.main:app --reloadSwagger UI
http://127.0.0.1:8000/docsRunning the MCP Server
python -m excel_mcp_server.mcp_serveror
mcp dev excel_mcp_server/mcp_server.py:mcpRunning the AI Agent
python -m excel_mcp_client.mainExample prompts:
Add "John" to row 3 column 2
Insert "Apple", "Banana", "Orange" into A1:A3
Delete data from C5
Clear the range B2:D5Example Workflow
User
│
▼
Natural Language Prompt
│
▼
Groq LLM
│
▼
MCP Client
│
▼
MCP Server
│
▼
FastAPI API
│
▼
Excel Workbook UpdatedFuture Improvements
Multiple worksheets support
Read/search Excel data
Update existing cell values
File upload support
User management with database
Refresh token implementation
Role-based authorization
Docker support
License
This project is intended for learning purposes.
This server cannot be deployed
Maintenance
Related MCP Connectors
Let AI agents read, check and edit Excel models. Open a workbook or drop in one MCP config. Either way: typed cells, a formula dependency graph, and a verification certificate. Deterministic — no OCR, no model guessing at your numbers.
Query your warehouse or a CSV with Claude/ChatGPT over MCP, governed by table-level ACL + audit.
Build and run AI workflows, agents, data tables and 1000+ API integrations from any MCP client.
Teable is an AI spreadsheet for business that combines a familiar spreadsheet interface with a structured database. Its remote MCP server lets AI agents inspect project and table structure, read and update records, and access the Teable API through OAuth with existing project permissions. Website: [teable.ai](https://teable.ai)
Related MCP Servers
- AlicenseBqualityDmaintenanceMCP server for semantic spreadsheet operations that lets LLMs create and edit Excel workbooks by describing spreadsheet intent.42MIT
- AlicenseNot gradedqualityDmaintenanceMCP server for managing Google Sheets via 23 tools, enabling read/write, formatting, sheet management, and data operations through natural language.8 npm1MIT
- AlicenseNot gradedqualityDmaintenanceEnables manipulation of Excel files including creating, reading, writing data, formatting, charts, pivot tables, and worksheet management via natural language.14 npmMIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to read, write, and manage Google Sheets spreadsheets through natural language commands, providing a bridge between MCP clients and the Google Sheets API.548 npm1MIT