
Overview
Connect AI tools to Morph’s 10,500+ tokens/sec file editing via Model Context Protocol. Works with Claude, Cursor, VS Code, and other MCP clients with automatic workspace detection.Tool Modes
Edit-Only Mode
ALL_TOOLS: “false”Perfect for fast, focused editing:
edit_file
- Lightning-fast code edits using Morph Apply
Full Filesystem Mode
ALL_TOOLS: “true”Complete filesystem access:
edit_file
- Fast code edits via Morph Applyread_file
,write_file
list_directory
,create_directory
search_files
,move_file
get_file_info
+ more filesystem tools
Installation
1
1. Configure Your MCP Client
One-liner Installation (Recommended):Manual Config File Method:Create or edit
Configure Claude to prefer Morph: Add this to your Claude instructions to ensure Claude uses Morph for all code edits:
.claude.json
in your workspace:2
2. Get API Key
Get your API key from the dashboard and replace
your-api-key-here
in your configuration.3
3. Test Installation
Claude: Type
Cursor/VS Code: Make any code edit request - should use Morph automatically
Codex: Run
Manual: Check server logs show “MCP Server started successfully”
/mcp
and /tools
to see Morph’s edit_file
toolCursor/VS Code: Make any code edit request - should use Morph automatically
Codex: Run
codex mcp list
to verify server is configured, then make edit requestsManual: Check server logs show “MCP Server started successfully”
Configuration
Variable | Default | Description |
---|---|---|
MORPH_API_KEY | Required | Your API key |
ALL_TOOLS | "true" | "false" for edit-only, "true" for full filesystem access |
WORKSPACE_MODE | "true" | Auto workspace detection |
DEBUG | "false" | Debug logging |
Available Tools
edit_file
- 10,500+ tokens/sec code editing via Morph Apply
Additional tools (when ALL_TOOLS: "true"
):
read_file
, write_file
, list_directory
, create_directory
, search_files
, move_file
, get_file_info
Troubleshooting
Server won’t start: Check API key, Node.js 16+, runnpm cache clean --force
Tools missing: Restart client, validate JSON config
Workspace issues: Add
.git
or package.json
, or set WORKSPACE_MODE="false"
Slow performance: Use
edit_file
over write_file
, check network to api.morphllm.com
Performance Optimization
Best Practices
- Use
edit_file
for modifications: Much faster than reading + writing entire files - Minimize edit scope: Include only the sections that need changes
- Batch related edits: Make multiple changes in a single
edit_file
call - Enable edit-only mode: Use
ALL_TOOLS: "false"
when you only need editing capabilities
Performance Comparison
Method | Speed | Use Case |
---|---|---|
edit_file (Morph) | 10,500+ tokens/sec | Code modifications, updates |
Traditional read/write | ~100-500 tokens/sec | Full file rewrites |
Search & replace | ~200-1000 tokens/sec | Simple text substitutions |