Mastering ComfyUI — Part 2: Core Node Reference
A reference for every node you'll use in nearly every ComfyUI workflow — checkpoints, prompts, the sampler, VAE encode/decode, and output — with what each does, why it exists, and what its inputs and outputs mean.
Goal for this part: a proper reference for every node you'll use in nearly every workflow — what it does, why it exists, and what its inputs/outputs actually mean. Come back to this part whenever you place a node and forget what one of its connections is for.
Previous: Part 1 — Interface & Node Paradigm
Loading things: checkpoints, images, LoRAs, upscale models
Load Checkpoint — the starting point of almost every workflow. Loads a
.safetensors checkpoint file and outputs three things: MODEL (the actual
diffusion model — this is what does the image generation), CLIP (the text
encoder — turns your prompt into something the model understands), and VAE
(the component that converts between pixel space and the compressed "latent
space" the model actually works in). Some checkpoints bundle all three into one
file (common for SDXL and Flux fp8 checkpoints); others ship the components
separately, which is what a split-component Flux template expects instead.
Load Image — loads an image file from disk as an IMAGE output, with a
MASK output alongside it (blank/unmasked by default unless the image has an
alpha channel or you've painted a mask on it via the Mask Editor). Used for
img2img workflows, inpainting, and as ControlNet input. Files loaded this way
come from ComfyUI's input folder specifically.
Load Image (from Outputs) — a variant (marked [BETA] in some versions)
that loads directly from ComfyUI's output folder instead — convenient for
feeding a previous generation back in without manually copying files between
folders. Worth knowing its limitation: the Mask Editor round-trip (painting a
mask and having it save back to the node) can behave unreliably on this beta
node — if you're doing serious inpainting work, prefer the standard Load Image
node with a file explicitly uploaded into the input folder.
Load LoRA (Model and CLIP) — applies a LoRA (Low-Rank Adaptation) on top of
your loaded checkpoint. Takes MODEL and CLIP in, and outputs modified
versions of both with the LoRA's influence blended in at whatever strength you
set. Full explanation of what LoRAs actually are and how to use them well is in
Part 4.
Load Upscale Model — loads a dedicated upscaling model (like ESRGAN
variants) as an UPSCALE_MODEL output, separate from your main checkpoint. Used
with an Upscale Image (using model) node — covered in Part 6.
Prompting: turning text into something the model understands
CLIP Text Encode (Prompt) — takes raw text and a CLIP input, and outputs
CONDITIONING — a numeric representation of your prompt that the sampler
actually uses. Every prompt you write, positive or negative, goes through one of
these. You'll typically have at least two in a workflow (positive and negative),
and more if you're doing per-region or per-subject prompting (Part 5).
FluxGuidance — Flux-specific. Takes a CONDITIONING input and applies a
guidance-strength value to it before it reaches the sampler. Flux models are
"guidance-distilled," meaning the usual cfg setting on KSampler doesn't apply
the same way it does for SDXL — this node is where that control actually lives
instead. In a working Flux workflow, cfg on KSampler gets set to 1.0, and
FluxGuidance's own guidance value (typically ~3.5) does the real work.
The generation core
Empty Latent Image — creates a blank canvas in latent space at whatever
width/height/batch_size you set. This is your starting point for a
from-scratch (txt2img) generation. Getting this resolution right relative to
your model's native training resolution is one of the single biggest quality
factors — covered in depth in Part 6.
KSampler — the actual diffusion sampling step, and the node with the most settings to understand:
model— from Load Checkpoint (or a LoRA-modified version of it)positive/negative— your twoCONDITIONINGinputslatent_image— where the generation starts from: an Empty Latent Image for txt2img, or an encoded existing image for img2img/inpaintingseed— the random seed; same seed + same everything else = same output, useful for isolating the effect of a single changed settingsteps— how many denoising iterations to run; more isn't always better past a point of diminishing returnscfg— how strongly to push the output toward your positive prompt and away from your negative (not used the same way for Flux — see FluxGuidance above)sampler_name/scheduler— which mathematical method and step-spacing strategy to usedenoise— how much of the input latent to actually change.1.0for a fresh txt2img generation; lower values (0.3–0.95) for img2img and inpainting, where you want to partially preserve what's already there
VAE Decode — converts the sampler's output (still in compressed latent
space) back into an actual viewable IMAGE, using the VAE from your
checkpoint. Every workflow that produces a visible image needs one of these as
the last step before saving.
VAE Encode — the reverse: converts a loaded IMAGE into latent space so it
can be fed into a sampler for img2img work. Needs the same VAE as whatever
checkpoint you're using downstream.
VAE Encode (for Inpainting) — a specialized version that also takes a MASK
input alongside pixels and vae. Produces a latent specifically set up so the
sampler only regenerates the masked region and leaves everything else
untouched. This is the node behind the two-pass inpainting compositing technique
from Part 5.
Output
Preview Image — displays an image directly in the workflow without saving it
to disk. Genuinely useful as a debugging tool: wire it to an intermediate output
(like a MASK, to visually confirm a mask isn't blank) without cluttering your
output folder with test renders.
Save Image — writes the final IMAGE to ComfyUI's output folder, with a
filename_prefix you control. This is what you'll use in almost every finished
workflow.
Save Image (Advanced) — the same job with more control: output format
(PNG, JPEG, WebP), bit_depth, color space, and compression settings (crf for
lossy formats). Worth switching to if you care about file size or need a
specific format for downstream use.
Quick mental model
For a bare minimum txt2img workflow, you need exactly six nodes: Load Checkpoint → CLIP Text Encode (×2) → Empty Latent Image → KSampler → VAE Decode → Save Image. Everything else in this reference — LoRAs, inpainting, upscaling, regional conditioning — is an addition layered onto that same core skeleton, not a replacement for it. Once that six-node shape is second nature, every more advanced workflow just looks like "the basic shape, plus a few extra nodes inserted at a specific point."
Next: Part 3 — Building Your First Workflow, a full hands-on walkthrough putting these nodes together from a blank canvas.
Previous: Part 1 — Interface & Node Paradigm