Word MCP Live

io.github.ykarapazar由 GitHub 账号 ykarapazar 发布v1.2.0更新于 Oct 24, 2026

Live Microsoft Word editing via MCP — tracked changes, undo, comments, 40+ tools

已验证STDIO仅桌面效率与工作流文件与存储

概览

AI 生成的概览

本地 MCP 服务器,让 AI 助手读取、编辑、排版和审阅 Microsoft Word 文档,并可在文件打开时实时编辑并生成修订。

可以做什么
读写已保存的 .docx 文件:文本、查找替换、格式、样式、表格、页面布局、页眉页脚、书签、公式与交叉引用,以及目录插入和排版诊断,无需安装 Word 即可跨平台使用。在 Windows 或 macOS 上实时编辑 Word 中打开的文档:文本、格式、表格、修订和批注直接出现在打开的文件中。管理审阅:以配置的作者名生成原生修订、锚定到文本的批注,Windows 上还支持批注回复、解决/取消解决和撤销历史查看。撤销 AI 操作:Windows 上每次操作可按一次 Ctrl+Z 撤销,macOS 上按操作撤销。
适用场景
适合让助手直接处理 Word 文档而非来回复制粘贴:以修订方式起草或修改合同和报告、修正格式与版式、添加审阅批注,或批量生成和编辑 .docx 文件。
运行要求
以 Python 包形式在本地运行(Python 3.11+),依赖自动安装。实时编辑需安装 Microsoft Word:Windows 10/11 使用 COM,macOS 使用 Word for Mac 的 JXA。跨平台工具无需 Word。可选环境变量 MCP_AUTHOR 和 MCP_AUTHOR_INITIALS 设置修订与批注的作者名和缩写;MCP_TRANSPORT、MCP_HOST、MCP_PORT 配置传输方式。Docker 模式仅支持跨平台工具。
安装前请注意
助手会写入你的文档:编辑、替换、格式、批注和删除都会改动真实文件,请保留备份并在接受前检查更改。修订和批注会记在 MCP_AUTHOR 设定的名字下,可能造成作者归属不实。实时编辑需要 Word 处于打开状态,且仅限 Windows/macOS;批注回复、解决、撤销历史和 watermark 等功能仅 Windows 可用。README 称其完全在本地运行且不收集数据

安装

在 SourceWeft 中

  1. 打开 控制台中的 Word MCP Live,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

[Install in Cursor]

word-mcp-live

The only MCP server that edits Word documents while they're open

Live editing · Tracked changes · Per-action undo · 124 tools · Cross-platform

[PyPI] [Python 3.11+] [License: MIT] [Platform: Windows + macOS/Linux]


word-mcp-live gives any AI assistant that supports MCP full control of Microsoft Word. Open a document, tell the AI what you need, and watch it happen — formatting, tracked changes, comments, and all. Changes appear live in your open document.

Without word-mcp-live

  • AI can discuss your document but can't touch it
  • You copy-paste between AI and Word, losing formatting
  • Track changes? You do those manually after the fact
  • Every edit means save → close → process → reopen

With word-mcp-live

  • "Add a tracked change replacing ABC Corp with XYZ Ltd" — done
  • Changes appear live in your open Word document
  • Every AI edit is one Ctrl+Z away
  • Real tracked changes with your name, not XML hacks

See it in action

https://github.com/user-attachments/assets/fbb09af4-1e25-4e49-94d0-45b363278810

What Sets This Apart

  • Live editing — Edit documents while they're open in Word. No save-close-reopen cycle.
  • Full undo — Every AI action is a single Ctrl+Z. Made a mistake? Just undo it.
  • Native tracked changes — Real Word revisions with your name, not XML hacks.
  • Threaded comments — Add, reply, resolve, and delete comments like a human reviewer.
  • Layout diagnostics — Detects formatting problems before they become print disasters.
  • Equations & cross-references — Insert math formulas and auto-updating references.
  • 124 tools — The most comprehensive Word MCP server available.

Quick Start

bash
pip install word-mcp-live

Or install from source:

bash
git clone https://github.com/ykarapazar/word-mcp-live.gitcd word-mcp-livepip install -e .

Client Installation

Claude Desktop

Add to your claude_desktop_config.json:

json
{  "mcpServers": {    "word": {      "command": "uvx",      "args": ["word-mcp-live"],      "env": {        "MCP_AUTHOR": "Your Name",        "MCP_AUTHOR_INITIALS": "YN"      }    }  }}
Claude Code

Add to your .mcp.json:

json
{  "mcpServers": {    "word": {      "command": "uvx",      "args": ["word-mcp-live"],      "env": {        "MCP_AUTHOR": "Your Name",        "MCP_AUTHOR_INITIALS": "YN"      }    }  }}
Cursor

One-click: Click the install button at the top of this page.

Manual: Add to ~/.cursor/mcp.json:

json
{  "mcpServers": {    "word": {      "command": "uvx",      "args": ["word-mcp-live"],      "env": {        "MCP_AUTHOR": "Your Name",        "MCP_AUTHOR_INITIALS": "YN"      }    }  }}
VS Code / Copilot

One-click: Install in VS Code

Manual: Add to your VS Code settings.json:

json
{  "mcp": {    "servers": {      "word": {        "command": "uvx",        "args": ["word-mcp-live"],        "env": {          "MCP_AUTHOR": "Your Name",          "MCP_AUTHOR_INITIALS": "YN"        }      }    }  }}
Windsurf

Add to ~/.codeium/windsurf/mcp_config.json:

json
{  "mcpServers": {    "word": {      "command": "uvx",      "args": ["word-mcp-live"],      "env": {        "MCP_AUTHOR": "Your Name",        "MCP_AUTHOR_INITIALS": "YN"      }    }  }}
Docker
json
{  "mcpServers": {    "word": {      "command": "docker",      "args": ["run", "-i", "--rm", "ghcr.io/ykarapazar/word-mcp-live"],      "env": {        "MCP_AUTHOR": "Your Name",        "MCP_AUTHOR_INITIALS": "YN"      }    }  }}

Note: Docker mode supports cross-platform tools only. Live editing requires a native Windows install.

MCP_AUTHOR sets your name on tracked changes and comments (default: "Author"). MCP_AUTHOR_INITIALS sets comment initials.

Two Modes

Works everywhereLive editing (Word open)
What it doesCreate and edit saved .docx filesEdit documents live while you work in Word
PlatformWindows, macOS, LinuxWindows (COM) and macOS (JXA)
UndoFile-level savesPer-action Ctrl+Z (Windows); per-operation undo (macOS)
Best forBatch processing, document generationInteractive editing, formatting, review

Both modes work together. The AI picks the right one for the task.

macOS Live Editing (New in v1.5.0)

Live tools now work on macOS via JavaScript for Automation (JXA). Same tool names, same parameters — the server detects your platform and uses the right automation backend.

FeatureWindowsmacOS
Text read/write/find/replaceCOMJXA
Formatting (bold, font, style)COMJXA
Track changes & revisionsCOMJXA
Comments (add, delete, list)COMJXA
Tables (read, write, add rows)COMJXA
Page layout, headers, bookmarksCOMJXA
Equations, cross-referencesCOMJXA
Threaded comment repliesCOMNot available
Comment resolve/unresolveCOMNot available
Undo history inspectionCOMNot available
WatermarksCOMNot available

Configuration

VariableDefaultDescription
MCP_AUTHOR"Author"Author name for tracked changes and comments
MCP_AUTHOR_INITIALS""Author initials for comments
MCP_TRANSPORTstdioTransport type: stdio, sse, or streamable-http
MCP_HOST0.0.0.0Host to bind (for SSE/HTTP transports)
MCP_PORT8000Port to bind (for SSE/HTTP transports)

For remote deployment, see RENDER_DEPLOYMENT.md.

Example Prompts

Just tell the AI what you want in plain language:

"Draft a contract with tracked changes so my colleague can review""Format all headings as Cambria 13pt bold and add automatic numbering""Add a comment on paragraph 3 asking about the deadline""Find every mention of 'ABC Corp' and replace with 'XYZ Ltd' as a tracked change""Set the page to A4 landscape with 2cm margins""Insert a table of contents based on the document headings""Add page numbers in the footer and our company name in the header""Insert a cross-reference to Heading 2 in paragraph 5"

Usage Examples

Example 1: Read a document (cross-platform)

Tool call: get_document_text

json
{ "filename": "C:/Documents/report.docx" }

Expected output:

json
{  "status": "success",  "paragraphs": [    {"index": 0, "text": "Quarterly Report", "style": "Heading 1"},    {"index": 1, "text": "Revenue increased by 15% compared to Q3.", "style": "Normal"},    {"index": 2, "text": "Key Metrics", "style": "Heading 2"}  ],  "total_paragraphs": 3}

Example 2: Live editing with tracked changes (Windows)

Tool call: word_live_replace_text

json
{  "filename": "report.docx",  "find_text": "ABC Corporation",  "replace_text": "XYZ Ltd",  "match_case": true,  "replace_all": true,  "track_changes": true}

Expected output:

json
{  "status": "success",  "replacements": 4,  "message": "Replaced 4 occurrences (tracked changes enabled)"}

The replacements appear as tracked changes in Word with strikethrough on "ABC Corporation" and underline on "XYZ Ltd".

Example 3: Add a comment anchored to text (cross-platform)

Tool call: add_comment

json
{  "filename": "C:/Documents/contract.docx",  "target_text": "payment within 30 days",  "comment_text": "Should we extend this to 45 days?",  "author": "Jane Smith"}

Expected output:

json
{  "status": "success",  "message": "Comment added by Jane Smith on 'payment within 30 days'"}

The comment appears in Word's Review panel, anchored to the specified text.

Tool Reference

124 tools across two modes — see the complete tool reference for details.

CategoryCount
Cross-platform (python-docx)80
Windows Live (COM automation)44
macOS Live (JXA automation)40 (of the 44 live tools)

Requirements

  • Python 3.11+
  • python-docx, fastmcp, msoffcrypto-tool (installed automatically)
  • Windows Live tools: Windows 10/11 + Microsoft Word + pywin32 (installed automatically)
  • macOS Live tools: macOS + Microsoft Word for Mac (uses built-in JXA — no extra dependencies)

The cross-platform tools work without Word installed — only python-docx is needed.

Contributing

See CONTRIBUTING.md for development setup, code style, and how to add new tools.

Found a bug? Open an issue. Have an idea? Request a feature.

Acknowledgments

Built on top of GongRzhe/Office-Word-MCP-Server by GongRzhe (MIT License).

Additional libraries: python-docx · FastMCP · pywin32

Privacy

This server runs entirely on your local machine. No data is collected, transmitted, or stored. See the full Privacy Policy.

Support

License

MIT License — see LICENSE for details.

Star History

[Star History Chart]

来源:README.md,提交 c6c7617

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v1.2.0最新Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分