How to Install ComfyUI: A Complete Setup Guide
ComfyUI has become one of the most powerful interfaces for running Stable Diffusion models locally. Unlike simpler frontends, it uses a node-based workflow system — meaning you connect inputs, models, samplers, and outputs visually, like wiring a circuit. That flexibility attracts advanced users, but it also means installation involves more moving parts than a typical app install.
Here's what you need to know before you start.
What ComfyUI Actually Is
ComfyUI is an open-source, locally run graphical interface for AI image generation. It runs entirely on your machine — no subscription, no cloud dependency — using models you download and store yourself. The interface runs through your browser, but the processing happens on your GPU (or CPU, as a slower fallback).
Because it's open-source and community-driven, there's no single installer that handles everything. You're assembling a small local stack: Python, the ComfyUI application itself, your model files, and optionally a set of custom nodes that extend functionality.
What You Need Before Installing
Hardware requirements
ComfyUI is GPU-intensive. A dedicated NVIDIA GPU with at least 4GB VRAM is the standard starting point for running common Stable Diffusion models at reasonable speeds. AMD GPU support exists but requires additional configuration through ROCm (Linux) or DirectML (Windows). Apple Silicon Macs (M1/M2/M3) can run ComfyUI using the MPS backend, with performance varying by chip generation and model size.
CPU-only mode works but is significantly slower — expect generation times measured in minutes per image rather than seconds.
Software dependencies
- Python 3.10 or 3.11 (3.12 has compatibility issues with some packages as of recent stable builds)
- Git (for cloning the repository and later installing custom nodes)
- PyTorch with the correct CUDA version matched to your GPU driver
Getting the PyTorch version right is one of the most common points of failure. CUDA 11.8 and CUDA 12.1 are the two most common targets — which one you need depends on your GPU driver version, not your GPU model itself.
Step-by-Step Installation Overview
1. Install Python and Git
Download Python from python.org and Git from git-scm.com. During Python installation on Windows, check the box to add Python to PATH — skipping this causes problems later. Verify both are working by running python --version and git --version in a terminal.
2. Clone the ComfyUI repository
Open a terminal in the folder where you want ComfyUI to live, then run:
This downloads the application files. No installer, no wizard — just a folder of Python scripts.
3. Install PyTorch
Navigate into the ComfyUI folder and install PyTorch with the correct CUDA flag. The PyTorch installation selector at pytorch.org generates the exact command for your OS and CUDA version. Using the wrong version here will cause ComfyUI to fall back to CPU mode silently, which is a frustrating debugging situation.
4. Install remaining dependencies
Run:
This installs the Python libraries ComfyUI needs to function.
5. Add your models
ComfyUI doesn't come with any AI models. You need to download checkpoint files (typically .safetensors or .ckpt format) from sources like Hugging Face or Civitai and place them in the correct subfolder:
Other model types (VAEs, LoRAs, ControlNet models, upscalers) each have their own designated subfolders within ComfyUI/models/.
6. Launch ComfyUI
Run:
ComfyUI will start a local server, and your terminal will show a URL — typically http://127.0.0.1:8188 — that you open in any browser. The node graph interface loads there.
Windows vs. macOS vs. Linux: Key Differences 🖥️
| Platform | GPU Backend | Notable Considerations |
|---|---|---|
| Windows | CUDA (NVIDIA) / DirectML (AMD) | Most straightforward CUDA setup; AMD support is limited |
| Linux | CUDA / ROCm (AMD) | Best AMD GPU support via ROCm; more flexibility overall |
| macOS (Apple Silicon) | MPS | No CUDA; uses Metal Performance Shaders; generally usable |
| macOS (Intel) | CPU only | Slow; not recommended for regular use |
The Portable Package Option
For Windows users who want to skip the manual Python setup, the ComfyUI GitHub releases page offers a portable standalone build — a pre-packaged folder that includes a bundled Python environment. You unzip it, drop your models in, and run a .bat file. It's faster to get started but offers less flexibility for installing custom nodes or troubleshooting dependency conflicts.
Custom Nodes: What They Are and When to Add Them
One of ComfyUI's biggest draws is its ecosystem of custom nodes — community-built extensions that add new capabilities like image upscaling workflows, face restoration, video generation pipelines, and more. The most common way to manage them is through ComfyUI Manager, itself a custom node that adds an in-app install interface.
Custom nodes are installed into ComfyUI/custom_nodes/ via Git clone or through ComfyUI Manager. Each node set has its own Python dependencies, and occasional conflicts between node packages are a real part of maintaining a ComfyUI installation over time.
Variables That Shape Your Experience ⚙️
How smoothly installation goes — and how well ComfyUI performs afterward — depends on a combination of factors that vary significantly from user to user:
- GPU brand and VRAM amount determine which models run comfortably and at what speed
- Operating system affects which GPU backends are available and how complex the setup is
- Python and driver version alignment is the most common source of installation errors
- Technical comfort level with terminals, virtual environments, and dependency management changes how steep the learning curve feels
- Intended workflow — simple image generation vs. complex multi-model pipelines — determines whether the base install is enough or whether custom nodes and additional models are necessary
Someone with an NVIDIA RTX GPU on Windows following current documentation will have a meaningfully different experience than someone setting up on an older AMD card on Linux, or running on an M2 MacBook. The core process is the same; the friction at each step is not.