⚡ Quick Answer
Latent space is a compressed, numerical version of an image — much smaller than the actual pixel grid — that KSampler works in while generating. A VAE converts the finished latent back into a normal, viewable image.
Running the entire denoising process on full-resolution pixels would be extremely slow and memory-heavy. Instead, models like Stable Diffusion and Flux compress the image into a smaller grid of numbers first — the latent — do all the actual generation work there, then expand it back to pixels only at the very end.
Where You'll See It
Empty Latent Image creates a blank latent to start a text-to-image generation, sized by width and height. VAE Encode converts an existing picture into a latent for image-to-image work, and VAE Decode converts KSampler's finished latent back into a real image at the end of the workflow.
Quick Example
For SD1.5 and SDXL, a 512×512 or 1024×1024 image is represented by a latent roughly 1/8th the size in each dimension — for example, a 1024×1024 image becomes a 128×128 latent with 4 channels, which is dramatically cheaper to process than the full pixel grid.
Common Mix-Up
Frequently Asked Questions
See It In Action
Ready to see the full pipeline?
Our text-to-image tutorial shows exactly where latents enter and leave the workflow.
Published: 2026-09-04 · Last updated: 2026-09-04
Join the discussion
Sign in to leave a comment or reply
No comments yet
Be the first to share your thoughts!
