comfy-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@comfy-mcpload the 'portrait' workflow, set prompt to 'a beautiful sunset', and execute it"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
comfy-mcp
MCP (Model Context Protocol) server for controlling a local ComfyUI instance from AI agents like Claude Cowork or Claude Code.
Lets an agent understand, modify, and execute ComfyUI workflows — enabling iterative AI-assisted image generation. Should work with any MCP-compatible agent, though it was built with Claude Cowork in mind.
Features
Workflow understanding — Parse workflow JSON and get a human-readable description of nodes, connections, and parameters
Parameter modification — Change prompts, seeds, models, samplers, resolution, and any other workflow parameter
PNG workflow extraction — Extract embedded workflow metadata from ComfyUI-generated PNG images
Workflow execution — Submit workflows, track progress, and retrieve generated images inline
Reproducible outputs — Output PNGs have workflow metadata embedded automatically, so images can be dragged back into ComfyUI to reproduce or tweak results with all nodes, connections, and widget values intact
Model discovery — List available checkpoints, LoRAs, VAEs, ControlNet models, samplers, and schedulers
Image upload — Upload input images for img2img, ControlNet, and other input-dependent workflows
Queue management — Monitor, cancel, and clear the execution queue
Workflow storage — Save and load workflows locally for reuse
Related MCP server: ComfyUI MCP
Platform support
Developed and tested on Windows. Should work on macOS and Linux but this has not been tested.
Requirements
Node.js 22+
A running ComfyUI instance
Setup
npm install
npm run buildConfiguration
Add to your MCP client settings. For Claude Code / Claude Cowork, add to .claude/settings.json:
{
"mcpServers": {
"comfyui": {
"command": "node",
"args": ["C:\\path\\to\\comfy-mcp\\dist\\index.js"],
"env": {
"COMFYUI_HOST": "127.0.0.1:8000"
}
}
}
}For development, use tsx instead:
{
"mcpServers": {
"comfyui": {
"command": "npx",
"args": ["tsx", "C:\\path\\to\\comfy-mcp\\src\\index.ts"],
"env": {
"COMFYUI_HOST": "127.0.0.1:8000"
}
}
}
}Set COMFYUI_HOST to match your ComfyUI instance (default: 127.0.0.1:8000).
Tools
Tool | Description |
| GPU, VRAM, RAM, and system info |
| Available node types and their schemas |
| Checkpoints, LoRAs, VAEs, and other model files |
| Human-readable workflow analysis |
| Modify workflow parameters by node ID |
| Find nodes by class type or title |
| Extract workflow from PNG metadata |
| Run a workflow and return images (with embedded metadata for reproducibility) |
| Check job status |
| Retrieve output images |
| Upload input images to ComfyUI |
| Download images from ComfyUI |
| View running and pending jobs |
| Stop a running job |
| Clear all pending jobs |
| View execution history |
| Save workflow to local storage |
| Load a saved workflow |
| List saved workflows |
Typical usage flow
Extract a workflow from a PNG or load a saved one
Describe the workflow to understand its structure
Check available models
Modify parameters (prompt, seed, model, etc.)
Execute and view the result
Drag the output PNG back into ComfyUI to reproduce or continue iterating
PNG metadata
Output images automatically embed the full workflow in ComfyUI-compatible PNG metadata. This means any image generated through this server can be dragged directly into the ComfyUI canvas to restore all nodes, connections, and widget values. If you provide the original UI-format workflow (via the ui_workflow parameter), exact node positions and group labels are preserved; otherwise, the server auto-generates a clean left-to-right layout from the API-format workflow.
Environment variables
Variable | Default | Description |
|
| ComfyUI API host and port |
|
| Local workflow storage directory |
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Alicense-qualityCmaintenanceA lightweight MCP server that bridges AI agents with a local ComfyUI instance to generate and iteratively refine images, audio, and video through conversational tool calls.151MIT
- Flicense-qualityBmaintenanceMCP server that connects local ComfyUI to AI agents, enabling natural language control of ComfyUI for creating workflows, generating images, and managing the queue.
- Alicense-qualityCmaintenanceAn MCP server that bridges AI agents with ComfyUI for automated workflow building, execution, monitoring, and output routing.1MIT
- Alicense-qualityBmaintenanceA lightweight MCP server that bridges AI agents with a local ComfyUI instance, enabling them to generate and iteratively refine images, audio, and video through conversational tool calls.276MIT
Related MCP Connectors
MCP server for Producer/Riffusion AI music generation
Remote MCP server for RunComfy Serverless API (ComfyUI): deployments and async inference.
MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/cuzelac/comfy-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server