Skip to main content
Safe Docx runs entirely as a local process on your machine. No document content is sent to external servers.

Prerequisites

  • Node.js >= 18
  • An MCP-compatible AI client (Claude Desktop, Claude Code, Gemini CLI, Cline, or any stdio MCP client)

Run the server

Safe Docx requires no global installation. Start the MCP server with:
npx -y @usejunior/safe-docx
This launches a local stdio MCP server. Your AI client connects to it automatically once configured.

Add to Claude Desktop

1

Open your Claude Desktop config file

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
2

Add the safe-docx entry

{
  "mcpServers": {
    "safe-docx": {
      "command": "npx",
      "args": ["-y", "@usejunior/safe-docx"]
    }
  }
}
3

Restart Claude Desktop

The server starts automatically when Claude launches. You should see safe-docx listed in the MCP tools panel.
4

Verify with a test prompt

Try this prompt to confirm the server is working:
Use safe-docx to edit /absolute/path/to/Agreement.docx.
1) Read the file and identify the paragraph IDs that contain "Term" and "Termination".
2) Replace the clause text in those paragraphs with clearer language while preserving formatting.
3) Save both outputs:
   - clean: /absolute/path/to/Agreement.clean.docx
   - tracked changes: /absolute/path/to/Agreement.tracked.docx
Return a short summary of what changed and list the paragraph IDs edited.
Replace the path with a real .docx file on your machine.

Other clients

For setup instructions for Claude Code, Gemini CLI, Cline/VS Code, and generic MCP clients, see the full installation guide.

What’s next

Core workflows

Learn how to read, search, edit, and save Word documents.

Golden prompts

Known-good prompt patterns for reliable first-run results.

Tool reference

Full reference for all available MCP tools.

Security

How Safe Docx handles file access and security.

Build docs developers (and LLMs) love