Comfy MCP Server

MCP Server for ComfyUI text to image Workflow

Remote serverstreamable-httpPython

What is the Comfy MCP Server?

MCP Server for ComfyUI text to image Workflow

What the server does

This script sets up a server using the FastMCP framework to generate images based on prompts using a specified workflow. It interacts with a remote Comfy server to submit prompts and retrieve generated images.

Credentials and setup notes

  • uv package and project manager for Python. - Workflow file exported from Comfy UI. This code includes a sample Flux-Dev-ComfyUI-Workflow.json which is only used here as reference. You will need to export from your workflow and set the environment variables accordingly. You can install the required packages for local development:

More MCP options

Compare MCP servers by category, or browse hosted MCP servers if you prefer an endpoint over a local process.

Maintainer setup documentation.

Configuration

  • uv package and project manager for Python. - Workflow file exported from Comfy UI. This code includes a sample Flux-Dev-ComfyUI-Workflow.json which is only used here as reference. You will need to export from your workflow and set the environment variables accordingly. You can install the required packages for local development:
VariableDescriptionRequired
COMFY_URLEndpoint or connection string the server talks to.Yes
COMFY_WORKFLOW_JSON_FILEConfiguration value read at startup.Optional
PROMPT_NODE_IDConfiguration value read at startup.Optional
OUTPUT_NODE_IDConfiguration value read at startup.Optional
OUTPUT_MODEConfiguration value read at startup.Optional

Frequently asked questions

MCP Server for ComfyUI text to image Workflow Confirm the tools offered by your installed version in the connected client. Tool availability and permissions depend on the server and account configuration.