Getting Started with ComfyUI: A Guide to Workflows, Models, and Setup
ComfyUI is a free application that allows you to generate AI images and videos locally on your own machine. Designed for users seeking greater control than standard prompt-and-generate tools, it offers visibility and adjustability over every stage of the generation process. While this flexibility introduces a learning curve, this guide aims to assist you from initial installation through to running and customising your first workflow.
Prerequisites Before You Begin
To use ComfyUI effectively, your computer must possess sufficient GPU resources to handle the specific models and workflows you intend to execute. Generally, larger models and more complex workflows demand higher amounts of VRAM.
You will also require the specific model files referenced by your workflow. Depending on the model type, this may include checkpoints, diffusion models, VAEs, text encoders, LoRAs, or other components. These files are typically stored within the ComfyUI/models directory.
If you do not have an appropriate local GPU, you have the option to run ComfyUI on a remote GPU-powered desktop. This approach offloads the generation workload to the remote GPU while allowing you to access the desktop from your usual computer.
Installing ComfyUI
For Windows and macOS users, ComfyUI recommends using its desktop application for a smoother onboarding experience. Alternative installation methods, such as manual installation or via the ComfyUI command-line tool, are available, with the best choice depending on your operating system and existing setup.
Once installed, launch the application to open the interface. You will find the workflow canvas and the tools necessary to create and manage your workflows.
The Importance of ComfyUI Workflows
A ComfyUI workflow dictates how an image or video is generated, governing the models, settings, and processing steps that lead to the final output.
This method offers significantly more control than a simple prompt box. You can switch models, apply LoRAs, use input images, tweak generation settings, upscale results, or integrate additional processing steps.
Furthermore, workflows can be saved for future reuse. Instead of reconstructing the same setup repeatedly, you can retain a workflow that yields satisfactory results and modify individual settings as required. You can also download workflows created by the community and adapt them to your own environment.
Understanding a ComfyUI Workflow
Workflows consist of connected nodes. Each node manages a specific aspect of the generation process, while the connections dictate how information flows between them.
A standard text-to-image workflow typically includes nodes for loading the model, entering the prompt, generating initial image data, producing the image, decoding the result, and saving the file.
- Model loader: Loads the model used for generation.
- Text encoder: Converts your prompt into a format the model can process.
- Sampler: Executes the generation process using the selected settings.
- VAE: Translates between latent data and a visual image.
- Save Image: Writes the generated image to disk.
There is no need to build every workflow from scratch. ComfyUI provides workflow templates, and a vast number of community-created workflows are available for download and direct use.
Loading an Existing Workflow
Utilising an existing workflow is often the simplest way to begin. ComfyUI offers example workflows for various models and tasks, while community websites provide an extensive selection.
Many workflow images embed the workflow data within their metadata. You can drag the image directly into ComfyUI or use the Workflows → Open function to load it. The workflow will then appear on the canvas with all nodes and settings already configured.
Once loaded, verify which models the workflow expects. If files are missing, ComfyUI can identify missing models for supported templates. For other workflows, you may need to locate and install the required models manually.
Finding Models for ComfyUI
Models can be found on repositories such as Hugging Face and Civitai, as well as on the project pages for specific models. The key is to find a model compatible with your chosen workflow.
Do not assume that any model file will work in any workflow. Different model architectures may require distinct loaders and supporting files.
Before downloading a model, consider the following:
- The model architecture and version
- The required ComfyUI workflow
- The model file format
- The recommended VRAM and hardware specifications
- Any required VAE, text encoder, LoRA, or other supporting files
- The model's license and usage restrictions
ComfyUI supports various model file types, each requiring placement in a specific folder. For instance, checkpoints belong in models/checkpoints, LoRAs in models/loras, and VAEs in models/vae. Some newer models utilise folders such as models/diffusion_models and models/text_encoders.
Installing a Model
After downloading 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.
Installing Custom Nodes
Many advanced ComfyUI workflows rely on custom nodes that are not part of the standard installation. You may notice missing nodes in a workflow if these dependencies have not been installed.
ComfyUI includes a Manager to facilitate the installation of custom nodes. Alternatively, nodes can be installed manually by placing their repositories in the custom_nodes directory and installing their required dependencies.
Only install custom nodes from trusted sources. As they may contain executable code, they can have their own dependencies and security implications.
Running and Modifying Your Workflow
Once the necessary models and custom nodes are installed, review the key settings in the workflow. Begin by checking the model, prompt, image dimensions, and sampling settings.
When everything is prepared, use the Queue button to execute the workflow. ComfyUI will process each step and generate the output defined by the workflow.
You can subsequently 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 alter the result.
Saving Your Workflows
Save workflows that you intend to reuse. While a workflow contains the node graph and its settings, it does not necessarily include the model files themselves. It is essential to keep track of which models and custom nodes the workflow requires.
This is particularly 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 function correctly.
Trying ComfyUI on DaDesktop
You do not need to purchase a new GPU solely to run ComfyUI. If your current computer lacks sufficient GPU resources, you can run ComfyUI on a cloud desktop and access it whenever needed.
DaDesktop offers cloud desktops with dedicated GPU resources, ideal for workloads such as AI image and video generation. You can install ComfyUI, download your desired models, 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 plan to run.
Start Your Free Trial Today
Run seamless virtual IT training with cloud-based labs, no downtime, just scalable learning that works.