
Excel Webview2 Mcp
io.github.dsbissettPublished by GitHub account dsbissettv0.0.13Updated Oct 25, 2026
MCP server for Excel add-ins via WebView2 CDP
Overview
A local MCP server that connects an assistant to Excel add-ins running in WebView2, letting it launch, inspect and stop add-in sessions through the Chrome DevT
- What you can do
- Detect, launch and stop Excel add-in sessions, including starting the local dev server and sideloading the add-in into Excel with remote debugging enabled on port 9222, then tearing the process tree down again. Read workbook and worksheet structure, active and used ranges, and range values, formulas, properties and special cells. Inspect conditional formats, data validations, tables, filters, named items, comments and shapes. Read calculation state, pivot tables and pivot values, charts and chart images, custom XML parts and settings. Use the inherited DevTools foundation for page inspection, screenshots, console access, network inspection and performance analysis.
- When to use it
- Useful when developing or debugging an Office Excel add-in on Windows and you want an assistant to start the add-in, look at what the workbook contains, and check the add-in's console, network traffic and performance without switching tools. Not applicable to Excel for Mac, which uses Safari Web Inspector instead.
- Requirements
- Windows with Excel desktop installed, plus Node.js (supported versions ^20.19.0, ^22.12.0 or >=23) to run the npm package via npx. An Office add-in project on disk with a manifest and dev server script for auto-launch, or an already running add-in with WebView2 remote debugging bound to port 9222, typically enabled through the WEBVIEW2_ADDITIONAL_BROWSER_ARGUMENTS environment variable or a registry policy.
Installation
In SourceWeft
- Open Excel Webview2 Mcp in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
Excel WebView2 MCP
Professional MCP connectivity for Microsoft Excel add-ins running inside WebView2.
[!IMPORTANT] As of v0.0.2, this server can launch Excel and sideload your add-in for you. You no longer need to start the dev server or attach a debugger before using it —
excel_launch_addinwill start your local dev server (if configured) and launch Excel with WebView2 remote debugging enabled on port9222. Manual pre-launch is still supported: if an Excel add-in is already running with remote debugging on9222, the server will attach to it.
What's New in v0.0.2
- Add-in lifecycle management — new tools launch and stop Excel add-ins directly from Claude Code:
- excel_detect_addin — discover manifest and dev server configuration for the current project.
- excel_launch_addin — start the dev server (if needed) and launch Excel with the add-in sideloaded and CDP port
9222enabled. - excel_stop_addin — tear down the launched Excel session and dev server process tree.
- Read-only Excel inspection tools — a broad set of read operations for inspecting workbooks, worksheets, ranges, tables, pivots, charts, and more. None of these mutate workbook state:
- Context & structure:
excel_context_info,excel_workbook_info,excel_list_worksheets,excel_worksheet_info,excel_active_range,excel_used_range. - Range reads:
excel_read_range,excel_range_properties,excel_range_formulas,excel_range_special_cells,excel_find_in_range. - Formatting & validation:
excel_list_conditional_formats,excel_list_data_validations. - Tables & names:
excel_list_tables,excel_table_info,excel_table_rows,excel_table_filters,excel_list_named_items. - Comments & shapes:
excel_list_comments,excel_list_shapes. - Calculation & pivots:
excel_calculation_state,excel_list_pivot_tables,excel_pivot_table_info,excel_pivot_table_values. - Charts:
excel_list_charts,excel_chart_info,excel_chart_image. - Misc:
excel_custom_xml_parts,excel_settings_get.
- Context & structure:
- Socket-based port detection replaces HTTP polling for more reliable dev-server and CDP readiness checks on Node 24.
- Robust cleanup on Windows —
excel_stop_addinnow force-kills the dev server process tree viataskkill.
Fork Notice
This repository is a fork of the Chrome DevTools MCP repository, ChromeDevTools/chrome-devtools-mcp. It preserves the upstream DevTools and MCP foundation, while adapting the connection model for Microsoft Excel add-ins hosted in WebView2.
What This Project Does
- Connects Claude Code to a locally running Excel add-in through the Chrome DevTools Protocol (CDP).
- Exposes MCP tools for inspection, automation, screenshots, console access, network inspection, and performance analysis.
- Targets the embedded WebView2 runtime used by Excel add-ins instead of a standalone Chrome session.
Connection Model
That separation matters: excel-webview2-mcp is a bridge to an existing debug session. It is not the thing that launches or hosts the add-in.
Prerequisites
You have two supported workflows:
Auto-launch (recommended, v0.0.2+)
- Your Office add-in project (with a
manifest.xmland a dev server script) lives on disk. - Excel desktop is installed on Windows.
- Node.js is installed and
npx @dsbissett/excel-webview2-mcp@latestis runnable.
Call excel_detect_addin first to confirm the project is discovered, then excel_launch_addin to start the dev server and sideload the add-in into Excel with CDP port 9222 enabled. Use excel_stop_addin to tear everything down.
Manual / pre-attached
- Your Excel add-in is already loaded and running in the local Excel desktop client.
- WebView2 remote debugging is enabled and bound to port
9222(see Launching Excel with the debug port). - The debugging endpoint is reachable at
http://127.0.0.1:9222.
Verify with:
Launching Excel with the debug port
This section applies to Excel desktop on Windows. Per Microsoft's WebView2 and Office add-in documentation, the supported way to pass Chromium flags into the WebView2 runtime is WEBVIEW2_ADDITIONAL_BROWSER_ARGUMENTS. The WebView2 team also documents a registry-based fallback for persistent configuration.
If you are using Excel for Mac, this MCP server does not apply. Microsoft documents Excel for Mac debugging through Safari Web Inspector instead of a WebView2 CDP port.
Sources:
- WebView2 debug arguments and registry policy: https://learn.microsoft.com/en-us/microsoft-edge/webview2/how-to/debug-visual-studio-code
- Office add-ins debugging with Edge DevTools: https://learn.microsoft.com/en-us/office/dev/add-ins/testing/debug-add-ins-using-devtools-edge-chromium
- Office add-ins debugging overview, including Mac: https://learn.microsoft.com/en-us/office/dev/add-ins/testing/debug-add-ins-overview
Windows: preferred local-dev setup
Set the environment variable before launching Excel so the Excel process inherits it:
Then:
- Launch Excel from that same shell or from a parent process that inherited the variable.
- Start your add-in locally.
- Confirm the debug endpoint is live.
Worked example:
The Office add-ins team documents this environment-variable mechanism generically for WebView2-hosted add-ins, and the WebView2 team documents --remote-debugging-port=9222 as a valid browser argument.
Windows: persistent registry fallback
If you need a persistent machine-local setting, the WebView2 team documents this registry policy path:
Use:
- Value name:
EXCEL.EXE - Value data:
--remote-debugging-port=9222
Use the environment variable first for local development. It is easier to turn on and off and avoids leaving a persistent machine-wide setting behind.
Verify the endpoint
Run:
A healthy response is JSON and includes fields such as:
If that curl command fails, Excel is not exposing the WebView2 debug port yet, and excel-webview2-mcp will not be able to attach.
Installation
The server ships as the npm package @dsbissett/excel-webview2-mcp and is invoked via npx. The configuration below is the same across every host — only the location of the config file changes.
Canonical MCP entry:
Claude Code (CLI)
One-liner:
Use claude mcp add --scope user ... to make the server available in every project, or --scope project to check the config into .mcp.json for teammates.
Alternatively, install the bundled plugin:
- Add the marketplace from
.claude-plugin/marketplace.jsonwith/plugin marketplace add dsbissett/excel-webview2-mcp. - Install with
/plugin install excel-webview2-mcp.
Claude Code (VS Code extension)
- Open the Claude Code side panel in VS Code.
- Open the command palette and run Claude Code: Manage MCP Servers (or click the MCP icon in the Claude panel).
- Choose Add Server and paste the canonical MCP entry above, or run the
claude mcp addcommand in the VS Code integrated terminal — the extension reads the same config.
Cursor
Edit ~/.cursor/mcp.json (global) or .cursor/mcp.json in the project root and add the canonical MCP entry above. Restart Cursor, then open Settings → MCP to confirm excel-webview2 shows as connected.
Codex (OpenAI Codex CLI)
Codex reads MCP servers from ~/.codex/config.toml. Add:
Then launch codex and confirm the server appears in /mcp.
GitHub Copilot (VS Code)
GitHub Copilot Chat in VS Code supports MCP servers through the agent-mode configuration.
-
Create or edit
.vscode/mcp.jsonin your workspace (or the user-levelmcp.jsonvia MCP: Open User Configuration from the command palette). -
Add the server entry:
-
Open Copilot Chat, switch to Agent mode, and click the Tools icon to confirm the
excel-webview2tools are available. Use MCP: List Servers from the command palette to inspect status or restart the server.
Verifying the install
After adding the server, ask the model to call excel_detect_addin from your Office add-in project directory. A successful response confirms the MCP server is wired up; from there excel_launch_addin will take care of starting Excel.
By default, the server connects to the local WebView2 debugging endpoint at http://127.0.0.1:9222.
Local Development
Supported Node.js versions are ^20.19.0, ^22.12.0, or >=23.
Source: README.md at commit 51a2812
Tools
0Version history
1- v0.0.13LatestSep 16, 2026
Score
40% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts
Declare a license in the repository or the registry entry.