ComfyUI MCP Server
Uses TOML configuration files to specify ComfyUI base URL, workflow paths, and asset directories for orchestrating ComfyUI workflows
Click on "Deploy 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., "@ComfyUI MCP Server list available workflows and show me the models catalog"
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.
ComfyUI_MCP
This repository provides a Model Context Protocol (MCP) server that exposes local ComfyUI workflow files and the remote ComfyUI model catalog to compatible LLM clients.
Features
Discovers workflow
.jsonfiles stored under theworkflows/directory and exposes them as MCP resources.Tools for listing workflow metadata and reading workflow contents.
Tool for recursively querying the ComfyUI
/api/modelsendpoints so an LLM can inspect the available checkpoints, LoRAs, and other assets.Configuration via CLI arguments or environment variables so the server can be launched from JSON descriptors (e.g., Cursor MCP definitions).
Related MCP server: ComfyUI MCP Server
Installation
Create a virtual environment (recommended) and install the package in editable mode with your preferred installer:
pip install -e .The project also works with uv so you can install or run it without using pip directly:
uv pip install -e .
# or run without installing into the current environment
uvx --from . comfyui-mcp --helpRunning the server
The installed comfyui-mcp entry point launches the MCP server over stdio. Common configuration options can be supplied either as CLI flags or environment variables:
Purpose | CLI flag | Environment variable | Default |
Workflow directory |
|
|
|
ComfyUI API base URL |
|
|
|
HTTP timeout (seconds) |
|
|
|
Log level |
|
|
|
Example stdio launch configuration for a Cursor MCP JSON definition:
If you prefer uvx, the same configuration can be expressed as:
{
"comfyui": {
"command": "uvx",
"args": [
"--from",
".",
"comfyui-mcp",
"--workflow-dir",
"./workflows",
"--api-base-url",
"http://127.0.0.1:8188/"
]
}
}When referencing the project locally with uvx, ensure the working directory is set to the
repository root (or adjust the --from path accordingly) so the package can be resolved without
requiring it to be published to an external index.
Place your ComfyUI workflow files in the workflows/ directory (or whatever directory you configure) so they are available to the LLM.
Available Tools
3 toolslist_modelsB
List models exposed by the configured ComfyUI server using the object info endpoints. Specify a kind to get a flat list or use recursive mode to aggregate multiple kinds.
Inputs: kind, recursive, search. Returns: result
list_workflowsB
List all ComfyUI workflow files that are available on disk.
Inputs: include_preview. Returns: object
read_workflowB
Read a specific workflow file by its relative path inside the configured workflow directory.
Inputs: relative_path (required). Returns: object
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose: list_models handles model enumeration, list_workflows lists workflow files, and read_workflow reads specific workflow content. There is no overlap or ambiguity between these functions, making tool selection straightforward for an agent.
All tools follow a consistent verb_noun pattern with snake_case naming: list_models, list_workflows, and read_workflow. This uniformity makes the tool set predictable and easy to understand at a glance.
With only 3 tools, the server feels thin for a ComfyUI integration, which typically involves more operations like executing workflows, managing nodes, or handling images. While the tools are well-defined, the count is borderline low for the apparent scope of interacting with a workflow automation system.
The tool set has significant gaps for a ComfyUI server, missing core operations such as executing workflows, uploading or managing models, and handling generated outputs. This incomplete surface will likely cause agent failures when trying to perform typical ComfyUI tasks beyond basic listing and reading.
Maintenance
Related MCP Connectors
Design, save, and run outcome-aligned AI workflows and verifiers, with reliable image output.
Build and run visual creative-production workflows from your AI agent.
LLM chat, text tools, image generation, editing, batch image jobs, and asynchronous video generation
Create, browse, remix, collaborate on, and run durable AI workflow nodes from MCP hosts.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables AI agents to manage ComfyUI workflows using a human-readable Domain Specific Language (DSL), with automatic conversion to/from JSON format. Supports workflow creation, validation, execution, and monitoring through natural language interactions.163MIT
- AlicenseAqualityDmaintenanceEnables comprehensive ComfyUI workflow automation including image generation, workflow management, node discovery, and system monitoring through natural language interactions with local or remote ComfyUI servers.3163 PyPI14MIT
- AlicenseNot gradedqualityNot gradedmaintenanceEnables AI agents to generate and iteratively refine images, audio, and video by interacting with a local ComfyUI instance through natural conversation. It provides comprehensive tools for workflow management, node introspection, and publishing generated assets.Apache 2.0
- AlicenseNot gradedqualityDmaintenanceA plain-English co-pilot for ComfyUI that lets you describe image generation changes in natural language, automatically loading workflows, swapping models, tweaking parameters, and running generations while learning your preferences.24MIT