ComfyUI MCP Server
Uses TOML configuration files to specify ComfyUI base URL, workflow paths, and asset directories for orchestrating ComfyUI workflows
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., "@ComfyUI MCP Serverlist 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.
| Name | Required | Description | Default |
|---|---|---|---|
| kind | No | ||
| recursive | No | ||
| search | No |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions using 'object info endpoints' and the effect of 'recursive mode', but it lacks details on permissions, rate limits, error handling, or what the output looks like (though an output schema exists). This leaves significant gaps for a tool with 3 parameters.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise and front-loaded, consisting of two sentences that directly address the tool's functionality and parameter usage without any wasted words. Every sentence adds value, making it efficient and well-structured.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has 3 parameters with 0% schema coverage and an output schema exists, the description provides basic context on what the tool does and some parameter usage. However, it lacks details on behavioral aspects like permissions or error handling, and does not fully explain all parameters, making it minimally adequate but with clear gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate. It explains the purpose of 'kind' (to get a flat list) and 'recursive' (to aggregate multiple kinds), adding some meaning beyond the schema. However, it does not cover the 'search' parameter at all, and the explanations are brief without details on allowed values or examples, failing to fully compensate for the low coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('List models') and resource ('exposed by the configured ComfyUI server using the object info endpoints'), making the purpose understandable. However, it does not explicitly differentiate from sibling tools like 'list_workflows' or 'read_workflow', which prevents a score of 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides implied usage by explaining how to use 'kind' and 'recursive' parameters to get different types of lists, but it does not explicitly state when to use this tool versus alternatives like 'list_workflows' or 'read_workflow', nor does it mention any exclusions or prerequisites.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_workflowsB
List all ComfyUI workflow files that are available on disk.
| Name | Required | Description | Default |
|---|---|---|---|
| include_preview | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It mentions 'available on disk', hinting at a read operation, but does not disclose behavioral traits such as permissions needed, rate limits, error handling, or what 'list' entails (e.g., format, pagination). The description is minimal and lacks critical operational details.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, clear sentence with no wasted words. It is front-loaded with the main purpose and efficiently conveys the essential information without unnecessary elaboration.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has an output schema, the description does not need to explain return values. However, with no annotations and low schema coverage, it lacks details on behavior and parameters. The description is adequate for a simple list operation but misses context on usage and transparency, making it minimally viable.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate. It does not mention the 'include_preview' parameter at all, but since there is only one optional parameter, the baseline is high. The description focuses on the core action, but fails to explain parameter usage, resulting in a slight deduction from the ideal.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb 'list' and the resource 'ComfyUI workflow files', specifying they are 'available on disk'. It distinguishes from 'read_workflow' by indicating listing vs reading content, but does not explicitly differentiate from 'list_models' beyond the resource type.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance on when to use this tool versus alternatives like 'list_models' or 'read_workflow'. The description implies usage for listing files on disk, but lacks context on prerequisites, exclusions, or comparative scenarios.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
read_workflowB
Read a specific workflow file by its relative path inside the configured workflow directory.
| Name | Required | Description | Default |
|---|---|---|---|
| relative_path | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool reads a file, implying a read-only operation, but doesn't specify permissions required, error handling (e.g., if the path doesn't exist), or any side effects. This is a significant gap for a tool that accesses files, lacking details on safety or constraints.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, clear sentence that directly states the tool's purpose and key parameter context. It's front-loaded with essential information and has no wasted words, making it highly efficient and easy to parse.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has an output schema (which likely describes the returned workflow file content), the description doesn't need to explain return values. However, with no annotations and a simple parameter, it adequately covers the basic operation but lacks behavioral details like error handling or permissions, making it minimally viable but with gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema description coverage is 0%, but the description adds meaning by explaining that 'relative_path' refers to a path 'inside the configured workflow directory'. This clarifies the parameter's context beyond the schema's basic string type. However, it doesn't detail format examples or constraints, so it partially compensates but not fully, aligning with the baseline expectation.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb ('Read') and resource ('a specific workflow file'), specifying it's identified by 'relative path inside the configured workflow directory'. This distinguishes it from sibling tools like 'list_workflows' which presumably list workflows rather than read individual files. However, it doesn't explicitly contrast with siblings, keeping it at 4 instead of 5.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives like 'list_workflows' or 'list_models'. It mentions the context ('configured workflow directory') but offers no explicit when/when-not instructions or prerequisites, leaving usage unclear beyond the basic operation.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
3 tool updates
- First observed
list_models - First observed
list_workflows - First observed
read_workflow
TDQS
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
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
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.
Create, browse, remix, collaborate on, and run durable AI workflow nodes from MCP hosts.
Generate reproducible image, video, and audio assets with leading models and your own provider keys.
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.3114MIT
- AlicenseNot gradedqualityNot gradedmaintenanceEnables AI assistants to interact with local ComfyUI installations to list nodes, validate workflows, and execute image generation workflows directly without requiring an HTTP server.1-
- 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.-
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/neutrinotek/ComfyUI_MCP'
If you have feedback or need assistance with the MCP directory API, please join our Discord server