Run SDXL Locally With ComfyUI (2024 Stable Diffusion Guide)

Matt Wolfe
17 Jan 202422:27

TLDRThis video tutorial offers a comprehensive guide on setting up and using Comfy UI with Stable Diffusion, highlighting its ease of use, customization, and the ability to generate uncensored images. The creator walks through the installation process, model setup, and the utilization of various nodes for advanced image generation. The tutorial also touches on integrating custom models and leveraging Comfy UI Manager for additional functionality, ultimately showcasing the powerful capabilities of Comfy UI in creating AI art.


  • ๐ŸŒŸ Stable diffusion has evolved significantly in the past 10 months, with better tools and processes emerging.
  • ๐Ÿ› ๏ธ Comfy UI is a user-friendly interface for stable diffusion that many find easier to use than previous tools like Automatic 1111.
  • ๐ŸŽจ Stable diffusion is chosen over other AI art tools for its freedom (open source, uncensored), privacy (runs locally), and customizability.
  • ๐Ÿ’ก Comfy UI provides a visual workflow for image generation, giving users more control over each step.
  • ๐Ÿš€ Installation of Comfy UI is quick and doesn't require prior installation of Python or other tools.
  • ๐Ÿ–ฅ๏ธ Comfy UI works best on a PC with an Nvidia GPU for optimal performance, but it can also run on a CPU.
  • ๐Ÿ”— Users can save and reload their entire workflows in Comfy UI for consistent image generation.
  • ๐Ÿ“š Comfy UI allows users to add custom nodes and models to enhance its capabilities, such as control net for pose detection.
  • ๐ŸŒ There are thousands of custom-trained models available on platforms like Civid AI for use in Comfy UI.
  • ๐Ÿ”„ Users can also import and use other people's workflows in Comfy UI by downloading JSON files.
  • ๐ŸŽ“ The tutorial provides a comprehensive guide on installing and using Comfy UI, including troubleshooting for Mac users.

Q & A

  • What has changed in the world of AI since the last stable diffusion tutorial?

    -In the last 10 months, there have been significant changes in AI, with better tools and processes emerging for running stable diffusion, making it easier to use.

  • Why might someone choose to use stable diffusion over other AI art tools?

    -People might choose stable diffusion because it is free, open source, uncensored, and can be installed locally, which addresses privacy concerns. It is also highly customizable with add-ons like control net.

  • What is Comfy UI and why is it preferred by many users?

    -Comfy UI is a user interface that provides a visual workflow for using stable diffusion. It is preferred because it offers a clearer overview of the process and allows users to save and reload entire workflows for convenience.

  • What are the system requirements for using Comfy UI effectively?

    -For optimal use of Comfy UI, a PC with Windows or Linux and an Nvidia GPU is recommended. While it can run on a CPU, the processing will be significantly slower.

  • What are the steps to install Comfy UI on a PC?

    -To install Comfy UI on a PC, users need to download the installation files from the GitHub page, extract the files using a tool like 7-Zip, and run the Nvidia GPU version of the application. The installation process also includes downloading and placing stable diffusion models in the correct folder.

  • How can Mac users install Comfy UI despite potential issues?

    -Mac users can refer to a YouTube video by AI Animation that demonstrates the installation of Comfy UI on Mac OS M1 or M2 using a tool called Homebrew.

  • What is the purpose of the Comfy UI Manager and how is it installed?

    -The Comfy UI Manager allows users to install custom nodes, enhancing the capabilities of Comfy UI. It is installed by cloning the repository from GitHub and following the instructions provided in the terminal.

  • How can users add more functionality to Comfy UI?

    -Users can add more functionality to Comfy UI by installing additional nodes through the Comfy UI Manager, which can introduce new features and processes to the image generation workflow.

  • What is Control Net and how is it used in Comfy UI?

    -Control Net is a feature that allows users to input an image for pose estimation and apply that pose to the generated image. It is used by installing the Control Net node and the corresponding model through the Comfy UI Manager.

  • How can users utilize custom models in Comfy UI?

    -Custom models can be used in Comfy UI by downloading the model files from platforms like Civit AI and placing them in the correct folder within the Comfy UI setup. Users can then select these models from the load checkpoint option.

  • What is the significance of Civit AI in relation to Comfy UI?

    -Civit AI is a platform that hosts a variety of custom-trained models for stable diffusion. Users can download these models and use them within Comfy UI to create images with different styles and characteristics.



๐ŸŒŸ Introduction to Stable Diffusion and Comfy UI

The speaker discusses the significant changes in the AI world since their last stable diffusion tutorial, highlighting the emergence of better tools and processes. They introduce Comfy UI as a user-friendly interface for stable diffusion, explaining its benefits such as being free, open-source, uncensored, private, and customizable. The speaker also compares Comfy UI to the previously used Automatic 1111 tool and outlines the advantages of the former.


๐Ÿ’ป Comfy UI Installation and Setup

The speaker provides a step-by-step guide on installing Comfy UI, starting with downloading the necessary files from the GitHub page. They explain the process of unzipping the files and running the program, emphasizing the importance of having an Nvidia GPU for optimal performance. The speaker also addresses potential issues for Mac users and provides a solution via a YouTube video link. Additionally, they discuss the need for specific hardware specifications and the process of downloading and installing stable diffusion models from Hugging Face.


๐ŸŽจ Customizing Comfy UI with Nodes and Models

The speaker delves into the customization options available in Comfy UI, demonstrating how to add nodes to the workflow for enhanced image generation. They install and use the Control Net and Open Pose nodes to incorporate pose detection into the image creation process. The speaker also shows how to add custom models into Comfy UI and adjust settings for different outcomes, such as changing the CFG scale and sampler for better image quality.


๐Ÿ“š Utilizing Pre-built Workflows and Models

The speaker explores the use of pre-built workflows and models available on Civit AI, showcasing how to import and use them in Comfy UI. They highlight the popularity of the Juggernaut XL model and guide the user on how to download and integrate it into their setup. The speaker also mentions the potential for using personal models trained in other AI applications within Comfy UI.


๐Ÿš€ Wrapping Up and Future Tutorials

The speaker concludes the tutorial by summarizing the key points covered and encourages viewers to explore Comfy UI further. They express willingness to create more advanced tutorials based on viewer feedback and promote their YouTube channel and newsletter for the latest AI news and tools. The speaker emphasizes the rapid pace of AI development and hopes that the tutorial remains relevant and helpful for viewers.



๐Ÿ’กStable Diffusion

Stable Diffusion is an AI model used for generating images from text prompts. It is notable for being free, open-source, and uncensored, allowing users to create a wide range of images without privacy concerns. In the video, the creator discusses the evolution of tools for using Stable Diffusion and introduces Comfy UI as a more user-friendly interface for this purpose.

๐Ÿ’กComfy UI

Comfy UI is a user interface designed to simplify the process of using Stable Diffusion. It provides a visual workflow that allows users to see each step of the image generation process and offers more control over the parameters. The video tutorial focuses on installing and using Comfy UI to enhance the experience of working with Stable Diffusion.

๐Ÿ’กAI Art Tools

AI Art Tools refer to various artificial intelligence-based applications and platforms that enable users to create digital art by generating images from textual descriptions or other inputs. These tools, including Stable Diffusion, MidJourney, Dolly 3, and Google's Imagin, are becoming increasingly popular due to their ability to produce high-quality, customizable images.

๐Ÿ’กOpen Source

Open source refers to software or tools whose source code is made publicly available, allowing users to view, use, modify, and distribute the software freely. In the context of the video, Stable Diffusion is described as an open-source AI model, which means that it can be freely accessed, used, and customized by the community.

๐Ÿ’กControl Net

Control Net is an add-on or feature in AI image generation tools that enables users to control specific aspects of the generated images, such as pose, by providing additional input or reference images. It enhances the customization capabilities of the AI, allowing for more precise control over the output.

๐Ÿ’กHugging Face

Hugging Face is a platform that provides a wide range of AI models, including Stable Diffusion models. It allows users to download and use these models for various purposes, such as image generation. In the video, the creator directs viewers to Hugging Face to download the latest and most powerful Stable Diffusion models for use with Comfy UI.

๐Ÿ’กNvidia GPU

Nvidia GPU refers to graphics processing units (GPUs) manufactured by Nvidia, which are specialized hardware components designed to accelerate graphical processing tasks. In the context of AI and image generation, an Nvidia GPU can significantly speed up the process of generating images with Stable Diffusion when compared to processing through a CPU.


Customization in the context of AI image generation refers to the ability of users to modify and adjust the settings and parameters of the AI model to create images that meet their specific requirements. This includes controlling the pose, style, and other elements of the generated images.


Workflows in the context of AI image generation are the sequences of steps or processes that lead to the creation of an image. They can include text prompts, model selections, and other settings that dictate the output. Comfy UI allows users to save their workflows for future use or to utilize workflows created by others.

๐Ÿ’กCivit AI

Civit AI is a platform that hosts a variety of AI models, including those trained by users. It provides a space for sharing and using custom-trained models within tools like Comfy UI, thus expanding the range of available options for AI-generated images.

๐Ÿ’กInstallation Process

The installation process refers to the steps taken to set up a software or tool on a device. In the video, the creator provides a detailed guide on how to install Comfy UI, including downloading files, extracting them, and running the application to use with Stable Diffusion.


It has been 10 months since the last stable diffusion tutorial, indicating significant changes in the AI landscape.

Stable diffusion has become easier to use with better tools and processes.

Comfy UI is introduced as a better user interface for stable diffusion.

Stable diffusion is preferred for being free, open source, and uncensored.

Privacy concerns are mitigated as stable diffusion can be used offline.

Stable diffusion is highly customizable with add-ons like control net.

Automatic 1111 was the previous tool used for stable diffusion but has downsides.

Comfy UI offers a visual workflow and easier installation process.

Comfy UI allows saving and reloading entire workflows for consistency.

Users can download and use custom workflows from platforms like Civid AI.

Comfy UI is best used on a PC with an Nvidia GPU for optimal results.

Instructions for installing Comfy UI on Apple Mac silicon are available but may have issues.

The installation process for Comfy UI is straightforward and quick.

Downloading and installing stable diffusion models like SDXL is necessary for image generation.

Comfy UI Manager can be installed to add more nodes and enhance the workflow.

Control net can be used to incorporate specific poses into the generated images.

Custom models can be loaded into Comfy UI for personalized image generation.

Comfy UI enables the use of thousands of available models trained by others.

Workflows created by others can be imported into Comfy UI for ease of use.