Skip to content
,

How to Use SDXL in ComfyUI (2026): Base, Refiner, Resolutions and Settings

6–9 minutes
Smiling woman in a headscarf and blue hoodie on a neon city street at night holding a card reading SDXL, with the text SDXL Still Rules on 8GB GPUs

SDXL (Stable Diffusion XL) is still one of the most useful image models you can run at home. It makes sharp 1024 px images, runs on far less VRAM than the newest giants, and has the biggest library of LoRAs, fine-tuned checkpoints and ControlNets of any model family.

In ComfyUI, SDXL can run on its own like any checkpoint, or as a two-stage pipeline where the base model does most of the work and the refiner adds the final fine detail.

This guide shows how to download SDXL, where the files go, build the basic workflow and the base + refiner workflow step by step, the best resolutions and settings, prompt tips, low-VRAM options and fixes for common problems.

Facts come from the ComfyUI examples, Comfy’s model pages and the Hugging Face SDXL docs as of November 2026.

TL;DR

  • Files: sd_xl_base_1.0.safetensors and (optional) sd_xl_refiner_1.0.safetensors from Stability AI on Hugging Face, into ComfyUI/models/checkpoints/.
  • Basic use: load the base in Load Checkpoint and use it like any other checkpoint.
  • Resolution: 1024×1024 or the same pixel count in other shapes, such as 896×1152 or 1536×640.
  • Refiner handoff: base does the first ~80% of steps, refiner the last ~20% (e.g. 20 of 25 steps with KSamplerAdvanced).
  • Prompts: natural descriptions plus style words work well; keep a short negative prompt.
  • Fine-tuned SDXL checkpoints usually don’t need the refiner.

Why Use SDXL in 2026?

Strength Why it matters
Modest VRAM Runs well on 8 to 12 GB cards where newer models struggle
Speed Fast generations, great for trying many ideas
Huge ecosystem Thousands of LoRAs, styles, fine-tuned checkpoints and ControlNets
1024 px native Much sharper than SD 1.5
Two text encoders Uses CLIP ViT-L and OpenCLIP ViT-bigG for better prompt understanding than SD 1.5

Need top prompt following or text in images? Newer models like Flux or Qwen-Image do better. See how to use Flux or our Qwen-Image local guide.

Download the Model Files

File Source (Hugging Face) Folder Needed?
sd_xl_base_1.0.safetensors stabilityai/stable-diffusion-xl-base-1.0 ComfyUI/models/checkpoints/ Yes
sd_xl_refiner_1.0.safetensors stabilityai/stable-diffusion-xl-refiner-1.0 ComfyUI/models/checkpoints/ Optional

Both are all-in-one checkpoints that bundle the diffusion model, text encoders and VAE, so you don’t need separate VAE or CLIP files. After copying them, press R in ComfyUI or restart it so they show up in the dropdowns.

New to ComfyUI? Follow how to install ComfyUI first. Unsure about folders? Our model folders cheat sheet has them all.

Workflow 1: SDXL Base Only

The ComfyUI examples say the SDXL base checkpoint can be used like any regular checkpoint. So the default text-to-image workflow works with one change.

  1. Load the default workflow (Workflow > Browse Templates, or the default graph).
  2. In Load Checkpoint, choose sd_xl_base_1.0.safetensors.
  3. In Empty Latent Image, set width and height to 1024 x 1024 (or another SDXL size from the table below).
  4. Write your prompt in the positive CLIP Text Encode node and a short negative like “text, watermark, blurry”.
  5. In KSampler, set steps 25 to 30, cfg about 7, sampler dpmpp_2m, scheduler karras, denoise 1.0.
  6. Click Run.

Workflow 2: Base + Refiner

SDXL was designed as an “ensemble of experts”. The base model handles the noisy early steps (composition and shapes), then hands its unfinished latent to the refiner, which handles the last low-noise steps (fine texture and detail). Hugging Face’s SDXL docs use an 80/20 split: base stops at 0.8, refiner starts at 0.8.

The easiest start is the official example: open the SDXL page of the ComfyUI examples and drag the sdxl_simple_example.png image onto your canvas. To build it yourself:

  1. Add two Load Checkpoint nodes: one with the base, one with the refiner.
  2. Add prompts for each. The base and refiner each need their own positive and negative CLIP Text Encode nodes, connected to their own checkpoint’s CLIP. You can use the same text, or give the refiner a different prompt.
  3. Add Empty Latent Image at 1024 x 1024.
  4. Base sampler: add KSamplerAdvanced with the base model. Set add_noise enable, steps 25, start_at_step 0, end_at_step 20, return_with_leftover_noise enable.
  5. Refiner sampler: add a second KSamplerAdvanced with the refiner model. Feed it the base sampler’s LATENT. Set add_noise disable, steps 25, start_at_step 20, end_at_step 10000, return_with_leftover_noise disable.
  6. VAE Decode the refiner’s output using the refiner checkpoint’s VAE, then Save Image.
  7. Run. Compare with the base-only result to see the extra detail.
Total steps Base end_at_step Refiner start_at_step Split
20 16 16 80/20
25 20 20 80/20
30 24 24 80/20
40 32 32 80/20

Alternative: generate a full image with the base, then run it through the refiner as a light image-to-image pass with low denoise (around 0.2 to 0.3). See our ComfyUI img2img guide for how denoise works.

Best SDXL Resolutions

The ComfyUI examples recommend 1024×1024 or other sizes with about the same number of pixels. Hugging Face notes that going below 512×512 is unlikely to work.

Shape Width x Height Use
Square 1:1 1024 x 1024 Default, social posts
Portrait 896 x 1152 Portraits, posters
Tall portrait 832 x 1216 Phone wallpapers
Landscape 1152 x 896 Scenes
Wide 1216 x 832 Blog headers
Ultra-wide 1536 x 640 Banners

Need bigger images? Generate at these sizes, then upscale. Our ComfyUI upscale guide shows how.

Recommended Settings

Setting Starting value Notes
Steps 25 to 30 More rarely helps much
CFG 6 to 8 Too high looks over-cooked
Sampler / scheduler dpmpp_2m / karras, or euler / normal See our samplers and schedulers explained
Denoise 1.0 for text-to-image Lower only for img2img
Refiner share About 20% of steps Skip for fine-tuned checkpoints
Batch size 1 to 4 Higher uses more VRAM

Prompting SDXL

  • Describe the scene naturally, then add style and quality words: “Astronaut in a jungle, cold colour palette, muted colours, detailed, 8k” (an example from the Hugging Face docs).
  • Order matters: put the subject first, then setting, lighting, camera and style.
  • Keep the negative prompt short: “text, watermark, blurry, low quality”.
  • Name a medium for strong styles: “oil painting”, “35mm photo”, “watercolour”, “3D render”.
  • Use weights sparingly: (red scarf:1.2) to emphasise something.

LoRAs, Upscaling and More

Add-on What it does Guide
LoRA Adds a style, character or concept LoRA not working fix
Train your own LoRA Teach SDXL your own style or product Train a LoRA locally
Inpainting Repaint part of an image ComfyUI inpainting guide
Upscale Bigger, sharper final images ComfyUI upscale guide

Remember: SDXL LoRAs only work with SDXL-based checkpoints, not SD 1.5 or Flux.

Low VRAM Tips

  • Skip the refiner to keep only one model in memory.
  • Use batch size 1 and standard SDXL sizes.
  • Close other GPU apps such as games or browsers with heavy tabs.
  • Start ComfyUI with --lowvram if you still run out of memory.
  • See our CUDA out of memory fix for more options.

Quick Workflow Checklist

  1. Checkpoint: SDXL base (or an SDXL fine-tune) selected in Load Checkpoint.
  2. Size: an SDXL resolution from the table, never 512×512 for final images.
  3. Prompt: subject first, then setting, lighting and style; short negative prompt.
  4. Sampler: 25 to 30 steps, CFG 6 to 8, denoise 1.0.
  5. Refiner (optional): KSamplerAdvanced split at about 80%, add_noise off on the refiner.
  6. Finish: upscale the keepers and save the workflow so you can reuse it.

Save the finished graph with Workflow > Save. Next time you only need to change the prompt and seed.

Troubleshooting

Problem Likely cause Fix
Checkpoint not in dropdown Wrong folder or not refreshed Put it in models/checkpoints and press R or restart
Weird, duplicated or stretched subjects Resolution too small or wrong ratio Use 1024×1024 or a listed SDXL size
Noisy, grainy image after refiner Refiner got a finished image with add_noise on, or steps mismatch Use the KSamplerAdvanced settings above
Refiner makes little difference Normal for some prompts Skip it, or try 30+ steps
Over-saturated, harsh look CFG too high Lower CFG to 5 to 7
Black image VAE precision issue See our ComfyUI black image fix
LoRA has no effect SD 1.5 LoRA on SDXL Use an SDXL LoRA
Out of memory Two models loaded Skip the refiner or use –lowvram

FAQ

Do I need the SDXL refiner?

No. The base works on its own. The refiner can add fine detail, but most fine-tuned SDXL checkpoints are made to be used without it.

Where do SDXL files go in ComfyUI?

Both the base and refiner go in ComfyUI/models/checkpoints/.

What resolution should I use for SDXL?

1024×1024, or a size with the same pixel count such as 896×1152 or 1536×640.

How much VRAM does SDXL need?

It runs comfortably on 8 to 12 GB cards with the base alone. Using the refiner too needs more memory.

Can I use SD 1.5 LoRAs with SDXL?

No. You need LoRAs trained for SDXL.

Is SDXL free to use?

Yes, you can download it free. Check Stability AI’s licence on the model page for commercial use terms.

Sources

Free weekly email

Get new AI guides every week

One short weekly email with our newest local AI, ComfyUI and AI tool guides. No spam, no pop-ups, just the good stuff.

Free. Unsubscribe anytime in one click. We only use your email to send this newsletter. See our privacy policy.

Smiling woman in a headscarf and blue hoodie on a neon city street at night holding a card reading SDXL, with the text SDXL Still Rules on 8GB GPUs