Local AI9 min read· May 6, 2026

How to Install and Use ComfyUI for AI Image Generation (Beginner Guide)

Step-by-step guide to install ComfyUI on Windows and Mac. Run AI image generation workflows locally with Stable Diffusion, FLUX, and more. Includes beginner-friendly setup and real-world examples.

How to Install and Use ComfyUI for AI Image Generation (Beginner Guide)

ComfyUI is intimidating at first.

You open it, see a blank canvas with no buttons, and think: "What do I click?"

But once you figure it out, ComfyUI becomes the fastest way to generate AI images locally. No rate limits. No pay-per-image. Full control.

If you've been using ChatGPT or online Midjourney, ComfyUI feels like graduating from training wheels to a sports car.

This guide walks you through the entire setup — Windows and Mac — plus 3 real workflows you can use tonight.


What Is ComfyUI? (And Why Use It)

ComfyUI is a node-based interface for running AI image generation locally.

Instead of clicking "Generate" in a text box, you drag nodes together to build workflows. Each node = one step (load model, add prompt, sample image, save output).

Sounds complicated. But it's actually more flexible and visual than web interfaces.

Why ComfyUI > Online Tools

Feature ComfyUI Midjourney Stable Diffusion Web UI
Cost Free (hardware only) $10–96/month Free
Model choice 100+ models 1 model 10+ models
Speed 5–30 sec (local GPU) 60 sec (cloud) Variable
Workflow save Yes (reuse anytime) No Limited
Custom training Yes No Limited
Private (no server logs) Yes No Yes

Best for: Iterating fast on image workflows, batch generation, custom models, privacy.


System Requirements (Before You Start)

Windows

  • GPU: NVIDIA only (RTX 3060 or better, 8GB+ VRAM minimum)
    • RTX 4090? 16GB VRAM → exceptional. Run 2–3 images in parallel.
    • RTX 3060? 12GB VRAM → 1 image at a time, 10–15 sec per image.
    • RTX 2070? 8GB VRAM → possible, but slower (30+ seconds per image).
  • RAM: 16GB minimum (32GB recommended if running other apps)
  • Disk: 100GB free (for models)
  • OS: Windows 10 or later

Mac

  • GPU: Any Mac with Apple Silicon (M1, M2, M3, M4) or Intel Mac with dedicated GPU
  • RAM: 16GB minimum (32GB recommended)
  • Disk: 100GB free
  • OS: macOS 12 or later

Check Your VRAM

Windows (NVIDIA):

nvidia-smi

Look for "NVIDIA RTX" in the output. Note the VRAM line (e.g., "12GB").

Mac: System Settings → About → Memory. Example: "24GB unified memory".

Don't have enough VRAM? Use CPU mode (slow, but works). We'll cover this later.


Step 1: Install ComfyUI (5 minutes)

Windows + NVIDIA GPU

Option A: Automated Installer (Easiest)

  1. Go to ComfyUI GitHub Releases
  2. Download ComfyUI_windows_portable_nvidia.zip (latest version)
  3. Unzip to any folder (e.g., C:\ComfyUI)
  4. Double-click run_nvidia_gpu.bat
  5. Wait 2–3 minutes for first launch (model download in background)
  6. Open browser → http://localhost:8188

Option B: Manual Setup (More Control)

  1. Install Python 3.10 (from python.org) — add to PATH during install
  2. Open Command Prompt (Windows key + R, type cmd)
  3. Navigate to your ComfyUI folder:
    cd C:\ComfyUI
    
  4. Run setup:
    python -m venv venv
    venv\Scripts\activate
    pip install -r requirements.txt
    pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
    
  5. Start ComfyUI:
    python main.py
    
  6. Browser → http://localhost:8188

Mac + Apple Silicon

Automated Installer (Recommended)

  1. Go to ComfyUI GitHub Releases
  2. Download ComfyUI_macos_arm64.zip (for M1/M2/M3/M4)
  3. Unzip to any folder (e.g., ~/ComfyUI)
  4. Open Terminal, navigate to folder:
    cd ~/ComfyUI
    
  5. Run:
    chmod +x run_mac_cpu.sh
    ./run_mac_cpu.sh
    
    (First time: installs dependencies, ~5 min)
  6. Browser → http://localhost:8188

Manual Setup:

  1. Install Homebrew (if not already): brew install homebrew
  2. Install Python 3.10: brew install python@3.10
  3. Follow Windows manual setup (same commands)

Step 2: Load Your First Model (3 minutes)

Once ComfyUI loads, you'll see:

  • Left panel: Nodes list (input, output, sampler, etc.)
  • Center canvas: Blank workflow
  • Right panel: Output images

Load Stable Diffusion (Default Model)

  1. Right-click on canvas → "Add Node" → "loaders" → "Load Checkpoint"
  2. A node appears. Click the dropdown showing "none"
  3. Select "sd15_model.safetensors" (or any .safetensors file)
  4. If no models appear: Models are downloading. Wait 5 minutes, refresh.

Not seeing any models?


Step 3: Build Your First Workflow (10 minutes)

Here's the simplest workflow to generate an image:

The 5-Node Setup

  1. Load Checkpoint (already added)
  2. Right-click → "Add Node" → "conditioning" → "CLIPTextEncode (Prompt)"
    • Add two of these (one for positive prompt, one for negative)
  3. Right-click → "Add Node" → "sampling" → "KSampler"
  4. Right-click → "Add Node" → "latent" → "VAE Decode"
  5. Right-click → "Add Node" → "image" → "Save Image"

Connect Nodes (Wire Them Together)

  • Drag from Load Checkpoint CLIP output → both CLIPTextEncode clip input
  • Drag from Load Checkpoint MODEL output → KSampler model input
  • Drag from both CLIPTextEncode outputs → KSampler positive and negative
  • Drag from Load Checkpoint VAE output → KSampler latent_image...

Wait, this is getting complex. Here's a shortcut:

Faster: Use a Template

ComfyUI comes with starter workflows. Download one:

  • Go to ComfyUI Examples
  • Download basic_workflow.json
  • Open ComfyUI → Load (bottom left) → select basic_workflow.json
  • Done. You're ready to generate.

Step 4: Generate Your First Image (2 minutes)

  1. Find the CLIPTextEncode nodes (they have text input boxes)
  2. Positive prompt box: Type a description
    • Example: "A serene mountain landscape at sunset, professional photography, high detail"
  3. Negative prompt box: Type what you DON'T want
    • Example: "blurry, low quality, text, watermark"
  4. Click "Queue Prompt" (bottom right) or press Shift+Enter
  5. Wait 10–30 seconds (depending on GPU)
  6. Image appears in the right panel

Popular Workflows (Copy-Paste Ready)

Workflow 1: Simple Text-to-Image

  • Load any Stable Diffusion model
  • Add positive + negative CLIPTextEncode
  • Connect to KSampler
  • Sample → VAE Decode → Save

Workflow 2: Upscaling (Make Images Bigger)

  • Text-to-image workflow (above)
  • Add latent → "Upscale Latent" node
  • Add upscale → "Upscale Model Loader" + "ImageUpscaleWithModel"
  • Upscale after VAE Decode

Workflow 3: LoRA + Base Model (Custom Styles)

  • Load checkpoint (base model)
  • Add loaders → "Load LoRA"
  • Connect between Load Checkpoint and KSampler
  • Use LoRA for consistent art style (anime, oil painting, etc.)

Workflow 4: Batch Generation (10 Images at Once)

  • Build basic workflow
  • Find KSampler node → Change seed to a range
    • Example: 1-10 generates 10 variations
  • Click "Queue Prompt"
  • ComfyUI queues all 10 and renders them

Model Downloads (Where to Get Them)

ComfyUI uses .safetensors files (models). Where to find them:

Official Sources (Recommended)

Popular Models for Beginners

  • Stable Diffusion 1.5 — Fast, versatile
  • Stable Diffusion XL (SDXL) — Better quality, needs 12GB+ VRAM
  • FLUX.1 — Newest (May 2024), best quality but slowest
  • Dreamshaper (CivitAI) — Great for photorealistic images
  • Realistic Vision (CivitAI) — Photorealistic people

Installation:

  1. Download .safetensors file
  2. Save to ComfyUI/models/checkpoints/
  3. Restart ComfyUI or refresh browser
  4. Model appears in dropdowns

Troubleshooting

"CUDA Out of Memory"

  • You ran out of VRAM
  • Fix: Reduce image size (512×512 instead of 1024×1024)
  • Or lower step count (15 instead of 20)
  • Or use CPU mode (much slower)

"Model not found" (after download)

  • Model file is corrupted or incomplete
  • Fix: Delete the file, re-download, verify file size matches source

"ComfyUI won't start"

  • Python version mismatch
  • Fix: Reinstall Python 3.10 exactly, not 3.11 or 3.12

"GPU not detected"

  • NVIDIA driver is outdated or CUDA not installed
  • Fix: Update GPU driver from NVIDIA website
  • Or use CPU mode: python main.py --cpu

Real Examples (What Can You Make?)

  1. Blog article hero images (1-click batch generation)

    • Prompt: "Minimalist tech blog header, [topic], professional design, 2026"
    • Batch: 10 variations, pick the best
    • Time: 2 minutes for 10 images
  2. Product mockups (for indie products)

    • Prompt: "MacBook Pro 16 displaying [your product], wooden desk, coffee cup, natural lighting"
    • Batch: 5 variations
    • Result: Professional-looking promo images, free
  3. YouTube thumbnails (consistency + speed)

    • Save workflow → Reuse for each video
    • Change only the text prompt
    • Generate 3 variations per video thumbnail
  4. Social media content calendar (bulk generation)

    • Build 1 workflow, generate 30 images in one batch
    • Theme: "Motivational quote about [topic], minimalist design, social media post"

Next Steps: Advanced (After Week 1)

Once you're comfortable with the basics:

  1. Custom models — Train your own LoRA (personal style, face, brand)
  2. Node extensions — Add community nodes for extra features
  3. API mode — Automate image generation from Python scripts
  4. Video generation — Extend ComfyUI for Stable Video or frame-by-frame animation

Related Guides


FAQ

Q: Is ComfyUI free?
A: Yes. The software is free. You only pay for your hardware (GPU). No cloud costs.

Q: Can I use ComfyUI on CPU only (no GPU)?
A: Yes, but it's 50–100× slower. Images take 5–15 minutes instead of 10 seconds. Not recommended for regular use.

Q: What if I have an AMD GPU (not NVIDIA)?
A: ComfyUI supports AMD via HIP. Installation is slightly different — follow AMD HIP instructions on GitHub.

Q: Can I use ComfyUI on Mac without GPU?
A: Mac M1/M2/M3 has unified memory, so yes, it works well even without a dedicated GPU. Macs are actually great for ComfyUI.

Q: How do I save my workflows?
A: Click Save (bottom left) → name it → it saves as .json. Load it anytime with Load.

Q: Can I make videos with ComfyUI?
A: Yes (with extensions). Search "Stable Video Diffusion" or "AnimateDiff" for frame-to-video workflows.

Q: Where can I find good prompts?
A: Prompt library on CivitAI. Copy-paste prompts other users shared.

Q: How do I get LoRAs (custom styles)?
A: Download from CivitAI, save to models/loras/, load in workflow.


You're ready. Open ComfyUI, load a model, and generate your first image. Welcome to local AI image generation.

Alex the Engineer

Alex the Engineer

Founder & AI Architect

Senior software engineer turned AI Agency owner. I build massive, scalable AI workflows and share the exact blueprints, financial models, and code I use to generate automated revenue in 2026.

Related Articles