How to Use ComfyUI: Workflows, Models, and Setup

ComfyUI is a free application for generating AI images and videos locally on your own machine. It is for users who want more control than what a typical prompt-and-generate tool provides, allowing you to see and adjust each part of the generation process. That flexibility comes with a learning curve, so this guide will help you get started, from installation to running and modifying your first workflow.

What You Need Before Starting

ComfyUI needs a computer with enough GPU resources for the models and workflows you want to run. Larger models and more demanding workflows generally require more VRAM.

You will also need the model files used by your workflow. Depending on the model, this can include checkpoints, diffusion models, VAEs, text encoders, LoRAs, or other components. These files are normally stored under the ComfyUI/models directory.

If you do not have a suitable GPU locally, you can also run ComfyUI on a remote GPU-powered desktop. This moves the generation workload to the remote GPU while allowing you to access the desktop from your normal computer.

Install ComfyUI

For Windows and macOS, ComfyUI recommends its desktop application for new users. There are other installation methods, including manual installation and the ComfyUI command-line tool. The appropriate method depends on your operating system and setup.

After installing ComfyUI, start the application and open the interface. You will see the workflow canvas and the tools used to create and manage your workflows.

Why ComfyUI Workflows Matter

A ComfyUI workflow defines how an image or video is generated. It controls the models, settings, and processing steps used to produce the final result.

This gives you much more control than a simple prompt box. You can change the model, add a LoRA, use an input image, adjust generation settings, upscale the result, or add other processing steps.

Workflows can also be saved and reused. Instead of rebuilding the same setup every time, you can keep a workflow that produces results you like and change individual settings when needed. You can also download workflows created by other users and adapt them to your own setup.

Understand a ComfyUI Workflow

A workflow is made up of connected nodes. Each node handles a particular part of the generation process, and the connections determine how information moves between them.

A basic text-to-image workflow might contain nodes for loading a model, entering a prompt, creating the initial image data, generating the image, decoding the result, and saving it.

  • Model loader: Loads the model used for generation.
  • Text encoder: Converts your prompt into information the model can use.
  • Sampler: Runs the generation process using the selected settings.
  • VAE: Converts between latent data and an image.
  • Save Image: Writes the generated image to disk.

You do not need to build every workflow from scratch. ComfyUI provides workflow templates, and many community workflows can be downloaded and opened directly.

Load an Existing Workflow

Using an existing workflow is usually the easiest way to start. ComfyUI provides example workflows for different models and tasks, while community sites offer many more.

Many workflow images contain the workflow data in their metadata. You can drag the image into ComfyUI or use Workflows → Open to load it. The workflow will appear on the canvas with its nodes and settings already configured.

Once the workflow is loaded, check which models it expects. If required files are missing, ComfyUI can identify missing models for supported workflow templates. Other workflows may require you to find and install the models yourself.

Find Models for ComfyUI

Models can be found on repositories such as Hugging Face and Civitai, as well as on the project page for the model itself. The important part is finding a model that is compatible with the workflow you want to use.

Do not assume that any model file can be loaded into any workflow. Different model architectures can require different loaders and supporting files.

Before downloading a model, check:

  • The model architecture and version
  • The required ComfyUI workflow
  • The model file format
  • The recommended VRAM and hardware
  • Any required VAE, text encoder, LoRA, or other supporting files
  • The model's license and usage restrictions

ComfyUI supports several types of model files. The folder depends on the type of model being installed. For example, checkpoints can go in models/checkpoints, LoRAs in models/loras, and VAEs in models/vae. Some newer models use folders such as models/diffusion_models and models/text_encoders.

Install a Model

Once you have downloaded a model, place it in the directory expected by the workflow. You can then select it in the corresponding model loader.

For example, a checkpoint might be stored in:

ComfyUI/models/checkpoints/

A LoRA might instead be stored in:

ComfyUI/models/loras/

If the new model does not appear in the model list, refresh the interface or restart ComfyUI.

Install Custom Nodes

Many advanced ComfyUI workflows use custom nodes that are not included in the standard installation. A workflow may show missing nodes if these dependencies have not been installed.

ComfyUI provides a Manager for installing custom nodes. Nodes can also be installed manually by placing their repositories in the custom_nodes directory and installing their required dependencies.

Only install custom nodes from sources you trust. Custom nodes can contain executable code and may have their own dependencies and security considerations.

Run and Modify Your Workflow

Once the required models and custom nodes are installed, check the important settings in the workflow. Start with the model, prompt, image dimensions, and sampling settings.

When everything is ready, use the Queue button to run the workflow. ComfyUI processes each step and produces the output defined by the workflow.

You can then modify individual parts of the workflow without rebuilding it. Add a LoRA, connect an input image, change the sampler, add an upscaler, or adjust other settings to change the result.

Save Your Workflows

Save workflows that you intend to reuse. A workflow contains the node graph and its settings, but it does not necessarily contain the model files themselves. Keep track of which models and custom nodes the workflow requires.

This becomes especially important when moving a workflow to another computer or cloud desktop. You may need to install the same models and custom nodes before the workflow will run correctly.

Try ComfyUI on DaDesktop

You do not need to buy a new GPU just to run ComfyUI. If your current computer does not have enough GPU resources, you can run ComfyUI on a cloud desktop instead and use it when you need it.

DaDesktop provides cloud desktops with dedicated GPU resources for workloads such as AI image and video generation. You can install ComfyUI, download the models you want, and build your own workflows without adding a dedicated GPU to your local computer.

Learn more about AI image and video generation on DaDesktop. You can also view the available GPUs and choose a configuration based on the models and workflows you want to run.

立即开始免费试用

通过云实验室运行流畅的虚拟IT培训,零停机,实现可扩展学习。