ComfyUI

v0.2.1Data Science & MLstable

MCP server for ComfyUI — text-to-image, variations, img2img refine, upscale, image proxy, and workflow runner.

comfyuicomfyui-apiimage-mcplocal-datalocal-mcp
Share:
320
Stars
0
Downloads
0
Weekly
0/5

What is ComfyUI?

ComfyUI is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to mcp server for comfyui — text-to-image, variations, img2img refine, upscale, image proxy, and workflow runner.

MCP server for ComfyUI — text-to-image, variations, img2img refine, upscale, image proxy, and workflow runner.

This server falls under the Data Science & ML category on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • MCP server for ComfyUI — text-to-image, variations, img2img

Use Cases

Generate images from text prompts.
Perform image upscaling and refinement.
Run custom ComfyUI workflows.
miller-joe

Maintainer

LicenseMIT License
Languagepython
Versionv0.2.1
UpdatedMay 22, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

NPM

npx -y @miller-joe/comfyui-mcp

Manual Installation

npx -y @miller-joe/comfyui-mcp

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use ComfyUI

ComfyUI MCP is an MCP server that connects AI assistants to a local or remote ComfyUI instance, exposing 16 tools for text-to-image generation, image variations, img2img refinement, upscaling, ControlNet conditioning, IP-Adapter style transfer, and full custom workflow execution. Rather than using ComfyUI's visual node editor manually, users can ask Claude or another MCP client to generate images with natural language and have the server translate those requests into ComfyUI API calls. It is particularly useful for integrating generative image capabilities into automated pipelines or conversational interfaces.

Prerequisites

  • A running ComfyUI instance accessible at an HTTP URL (default: http://127.0.0.1:8188)
  • At least one Stable Diffusion checkpoint model installed in ComfyUI's models/checkpoints/ directory
  • Node.js 18+ and npx (for the npx transport), or Docker (for the container transport)
  • An MCP-compatible client such as Claude Desktop or Claude Code
1

Start your ComfyUI instance

Launch ComfyUI and confirm it is accessible at its API endpoint. By default this is http://127.0.0.1:8188.

# In your ComfyUI directory:
python main.py --listen
2

Run the comfyui-mcp server with npx

Start the MCP server, pointing it at your ComfyUI instance. Adjust the URL if ComfyUI is on a different host or port.

npx -y @miller-joe/comfyui-mcp --comfyui-url http://127.0.0.1:8188
3

Configure the MCP client

Add the server to your Claude Desktop config file. Pass environment variables to set the ComfyUI URL and the default checkpoint model.

4

Verify available models

Once connected, ask the AI assistant to list available models. This confirms the server can reach ComfyUI and that checkpoints are loaded correctly.

5

Generate a test image

Try a simple text-to-image prompt to confirm the full pipeline works end-to-end before building more complex workflows.

ComfyUI Examples

Client configuration

Register comfyui-mcp in Claude Desktop's config. Set COMFYUI_URL to point to your ComfyUI server and COMFYUI_DEFAULT_CKPT to a model file that exists in your checkpoints folder.

{
  "mcpServers": {
    "comfyui": {
      "command": "npx",
      "args": ["-y", "@miller-joe/comfyui-mcp"],
      "env": {
        "COMFYUI_URL": "http://127.0.0.1:8188",
        "COMFYUI_PUBLIC_URL": "http://127.0.0.1:8188",
        "COMFYUI_DEFAULT_CKPT": "sd_xl_base_1.0.safetensors",
        "MCP_TRANSPORT": "stdio"
      }
    }
  }
}

Prompts to try

Natural language prompts that map to the server's 16 tools.

- "Generate a photorealistic image of a mountain lake at sunset, 1024x768"
- "Create 4 variations of this landscape image with slightly different lighting"
- "Upscale this image to 4x resolution using ComfyUI"
- "List all available checkpoint models loaded in ComfyUI"
- "Run my saved 'portrait-workflow' template with this prompt: elegant woman, studio lighting"

Troubleshooting ComfyUI

Connection refused when the server tries to reach ComfyUI

Make sure ComfyUI is started with '--listen' so it binds to 0.0.0.0 rather than just localhost. If ComfyUI is on a remote machine, use its actual IP address in COMFYUI_URL and ensure port 8188 is open in the firewall.

Image generation fails with 'model not found' or checkpoint errors

Run 'list_models' from the MCP session to see what checkpoints ComfyUI can see. Set COMFYUI_DEFAULT_CKPT to the exact filename returned by that list (including the .safetensors extension). Models must be placed in ComfyUI's models/checkpoints/ directory.

Frequently Asked Questions about ComfyUI

What is ComfyUI?

ComfyUI is a Model Context Protocol (MCP) server that mcp server for comfyui — text-to-image, variations, img2img refine, upscale, image proxy, and workflow runner. It connects AI assistants to external tools and data sources through a standardized interface.

How do I install ComfyUI?

Install via npm with the command: npx -y @miller-joe/comfyui-mcp. Then add the server configuration to your AI client's JSON config file (e.g., claude_desktop_config.json or .cursor/mcp.json).

Which AI clients work with ComfyUI?

ComfyUI works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is ComfyUI free to use?

Yes, ComfyUI is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.

Browse More Data Science & ML MCP Servers

Explore all data science & ml servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "comfyui": { "command": "npx", "args": ["-y", "@miller-joe/comfyui-mcp"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use ComfyUI?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides