Model
Trends
.ai
Model
Trends
.ai
the best open source ai models

Automatic1111 (Stable Diffusion WebUI) errors and fixes

Topic: Errors & fixes
By Captain
Published 2026-05-14
Share

Overview

AUTOMATIC1111's Stable Diffusion WebUI is still the most installed interface for
SD 1.5
and
SDXL
, and its error messages are well known by now. Most of them come from four causes: the Python or torch install, a card that is too small for the settings, a model file that does not match the settings (VAE, half precision, SDXL versus 1.5), and extensions that broke after an update.
The WebUI reads its start-up options from webui-user.bat (Windows) or webui-user.sh (Linux and Mac) in the COMMANDLINE_ARGS line. Most fixes below are a flag added to that line. After a change, close the console window and start the WebUI again; a browser refresh is not enough.
If the WebUI is the bottleneck rather than the model, the newer
Forge
fork is a drop-in replacement with much lower memory use (its own guide is linked below), and the same SD 1.5 and SDXL checkpoints run on the cloud through
PirateDiffusion
's /render command or
BitVector
's web app without any install.

Reference

Name
Type
What it is
Torch is not able to use GPU
error
torch was installed without CUDA, the driver is too old, or the card is AMD/Intel. Reinstall torch with CUDA or add the right flags for your hardware.
NansException: A tensor with all NaNs was produced
error
Half precision overflow in the VAE or the Unet, typical with SDXL and with some merged checkpoints. Use --no-half-vae, then --no-half, or the fp16-fix VAE.
RuntimeError:
CUDA out of memory
error
Resolution, batch, hires fix or
ControlNet
exceed
VRAM
. Add --medvram (or --medvram-sdxl) and lower the hires upscale.
Couldn't install torch / No matching distribution
error
The wrong Python version (the WebUI wants 3.10.x) or a blocked network. Install Python 3.10.6, add it to PATH, delete the venv folder and start again.
Stable diffusion model failed to load
error
A corrupt or incomplete
checkpoint
, a
LoRA
in the checkpoint folder, or a config mismatch. Re-download, and keep LoRAs in models/Lora.
AttributeError: 'NoneType' object has no attribute ...
error
An extension that no longer matches the WebUI version. Disable extensions, update them one by one.
xformers: WARNING ... / version mismatch
warning
xformers compiled against another torch. Remove --xformers and use --opt-sdp-attention, or reinstall xformers with --reinstall-xformers once.
DefaultCPUAllocator: not enough memory
error
System RAM ran out while loading a 6 GB SDXL checkpoint. Close other apps, enlarge the page file, or convert the checkpoint to fp16.
Connection errored out / Gradio timeout
symptom
The Python process crashed or stalled. Read the console; a crash during VAE decode is memory.
Images are black or green
symptom
Half precision VAE on cards that cannot do it (GTX 16xx, some 10xx). Add --no-half-vae or --precision full --no-half.
AD
No install required - run AI models on the cloud
BitVector Prism is the easiest way to start: pick a model, type a prompt and generate in a clean web app, with nothing to configure. BitVector is also available on Discord and on the web (SpyGlass).

Step by step

  1. Confirm Python 3.10.x and a recent NVIDIA driver (the console prints the torch and CUDA versions at start-up; CUDA should not be "cpu").
  2. Edit webui-user.bat and set COMMANDLINE_ARGS. Start with: --xformers or --opt-sdp-attention, plus --medvram for 8 GB cards, --lowvram for 4 to 6 GB, --no-half-vae for SDXL.
  3. Put files where the WebUI expects them: checkpoints in models/Stable-diffusion, LoRAs in models/Lora, embeddings in the embeddings folder, VAEs in models/VAE, ControlNet models in extensions/sd-webui-controlnet/models or models/ControlNet.
  4. For a NansException, first add --no-half-vae; if it persists add --no-half; with SDXL use the sdxl-vae-fp16-fix VAE instead of the baked one. Do not tick "Upcast cross attention" unless the message asks for it.
  5. For a memory error, reduce before you upgrade: batch size 1, no hires fix above 1.5x, 512x768 for SD 1.5 and 1024x1024 for SDXL, Tiled VAE from the multidiffusion extension for big outputs.
  6. After an update that broke things, start with --disable-all-extensions. If it runs, re-enable in Settings > Extensions in halves, Apply and restart UI each time, until you find the offender; update or remove it.
  7. If the install is damaged, delete the venv folder (only that folder) and start webui-user.bat again; it rebuilds the environment in a few minutes and keeps your models and outputs.
  8. When a card is simply too small for SDXL or ControlNet, use the same checkpoint hosted: PirateDiffusion renders SD 1.5 and SDXL models with /render and the model's trigger word from this site, and BitVector runs them in the browser.

Examples

webui-user.bat for an 8 GB card with SDXL

set COMMANDLINE_ARGS=--opt-sdp-attention --medvram-sdxl --no-half-vae --api

GTX 1660 / 1650 (black images)

set COMMANDLINE_ARGS=--lowvram --precision full --no-half --opt-sdp-attention

Rebuild the environment

rmdir /s /q venv
webui-user.bat

Tips

  • A1111 is maintained slowly; Forge (its fork) has most fixes built in and uses half the memory. The Forge guide on this site covers the differences.
  • Keep the Settings > Stable Diffusion > SD VAE on Automatic and give each checkpoint its own VAE by file name (model.safetensors next to model.vae.pt) so a bad VAE never applies globally.
  • Never put --lowvram and --medvram together; the later one wins and the console warns.
  • The console line "Applying attention optimization: sdp" confirms the fast attention is active; if it says "Doggettx", add --opt-sdp-attention.
  • An SDXL checkpoint with a 1.5 LoRA produces a silent no-op or a size error; this site names the family on every model page, check it before you download.
  • Clear the browser cache (or open an incognito window) after an update; stale JavaScript produces strange UI errors that look like server faults.

Troubleshooting

Torch is not able to use GPU

Why it happens
CPU-only torch, old driver, or non-NVIDIA card.

How to fix it
Update the driver, delete venv and relaunch to reinstall torch with CUDA. AMD on Windows: use the DirectML fork or ZLUDA; on Linux use ROCm.

NansException with SDXL

Why it happens
fp16 VAE overflow.

How to fix it
Download sdxl-vae-fp16-fix, select it in SD VAE, or add --no-half-vae.

CUDA out of memory with hires fix

Why it happens
The upscaled pass needs several times the memory.

How to fix it
Lower the upscale factor, use a latent
upscaler
, switch Tiled VAE on, or run the hires pass as
img2img
afterwards.

Couldn't install torch

Why it happens
Python 3.11 or 3.12 instead of 3.10.

How to fix it
Install Python 3.10.6, point webui-user.bat at it with set PYTHON=path\python.exe, delete venv, relaunch.

Stable diffusion model failed to load

Why it happens
Half-downloaded or renamed file.

How to fix it
Re-download, check size against the model page, keep the original extension.

Extensions tab shows errors after git pull

Why it happens
Extensions written for an older WebUI.

How to fix it
Update each extension from its tab; remove the ones no longer maintained (the Manager-style list shows last commit dates).

Model loads but every image is noise

Why it happens
Wrong VAE applied globally, or a merged model needing a specific config.

How to fix it
Set SD VAE to Automatic, remove a global VAE, and put the checkpoint's .yaml next to it if the author provides one.

AD
PirateDiffusion
No install required - run AI models on the cloud
PirateDiffusion is Telegram only and built for pros: thousands of models, LoRAs and workflows driven by chat commands, with unlimited generation on a fixed price plan.

Questions

Should I switch to Forge?

If you have 12 GB or less, yes; Forge runs SDXL and
Flux
where A1111 struggles, and your models and most extensions carry over. The Forge guide on this site lists the differences.

Can A1111 run Flux?

Not well. Flux support lives in Forge and
ComfyUI
. The Flux models on this site name the UIs they work with.

Where are my images?

In outputs/txt2img-images and outputs/img2img-images, dated folders. The Settings > Saving tab changes the pattern.

What do the model pages on this site give me for A1111?

The exact family (SD 1.5 or SDXL), trigger words, the file hash to check a download, and the Civitai source. LoRAs are called in the prompt as <lora:filename:0.8>.

Is there a way to try a model before downloading 6 GB?

Yes: the Run box on each model page runs it hosted on PirateDiffusion or BitVector with the trigger word shown.

Links and sources

Models in this guide

Written by
Captain

Related guides

Errors & fixes
Stable Diffusion WebUI Forge errors and fixes (Flux, SDXL, low VRAM)
Forge-specific problems and their fixes: Flux not loading or producing noise, the UI type switch (sd / xl / flux), "GPU Weights" slider and out-of-memory errors, missing text encoders and VAE for Flux, ControlNet and extension breakage, and the differences from Automatic1111 that trip people up.
By Captain
2026-05-16
Errors & fixes
ComfyUI errors and how to fix them: red nodes, missing models, CUDA out of memory
The ComfyUI error messages people hit first, what each one means and the fix that works: missing custom nodes (red boxes), "Prompt outputs failed validation", CUDA out of memory, wrong model type in a loader, mat1 and mat2 shape errors, header deserialization, torch and xformers mismatches.
By Captain
2026-05-12
Errors & fixes
CUDA out of memory: how much VRAM each AI model needs and how to fit it
A VRAM table for SD 1.5, SDXL, Flux, FLUX.2, Qwen-Image, Z-Image, Wan 2.2 and HunyuanVideo, and the techniques that make a model fit: fp8 and GGUF quantisation, CPU offload, tiled VAE, resolution and frame limits, and when to stop fighting and run it hosted.
By Captain
2026-05-18
Models
What is a LoRA and how to use one in ComfyUI, Forge, Automatic1111 and on the cloud
LoRAs explained for people who want results, not maths: what a LoRA file changes, why it must match the base model's family, trigger words, weights, stacking several LoRAs, the folder and syntax for each UI, and how to try a LoRA on the cloud before downloading anything.
By Captain
2026-05-20

More guides

Cloud services
Flat fee vs tokens: why unlimited plans like Graydient.ai are the best value for AI creators in 2026
A ranked cost comparison, with prices checked on 8 October 2026, of flat-fee unlimited plans like Graydient.ai against token and credit pricing from Midjourney, Leonardo, fal.ai, Replicate, Runway and Kling: what 1,000 images and 1,000 videos a month really cost on each, and why one fixed fee for unlimited images, video, audio, Grok LLM chat and web apps is the best value for creators who iterate.
By Captain
2026-10-08
Models
FLUX.1 Dev: how to prompt it, best settings and creative ideas
A practical guide to FLUX.1 Dev by Black Forest Labs: natural-language prompting, guidance and step settings, LoRA stacking, text rendering and prompt ideas that play to its strengths.
By Captain
2026-09-30
Models
Stable Diffusion XL 1.0: prompts, settings and what it still does best
How to get the most out of the official SDXL 1.0 base model: native resolutions, CFG and sampler settings, the refiner, negative prompts and ideas for styles where SDXL still shines.
By Captain
2026-10-01
Models
Stable Diffusion 1.5: the classic model, prompted properly
Stable Diffusion 1.5 is still worth knowing: the right resolution, CFG and sampler, how to use its huge library of LoRAs and embeddings, and creative prompt ideas suited to a 512-pixel model.
By Captain
2026-10-02
Models
FLUX.2 Dev: prompting the newest Black Forest Labs model
FLUX.2 Dev brings larger prompts, better text, stronger realism and multi-reference editing. This guide covers the turbo workflow, guidance and resolution settings, prompt structure and ideas that use its new strengths.
By Captain
2026-10-03
Models
Qwen-Image: long prompts, perfect text and bilingual posters
Qwen-Image is the model to reach for when the words in the picture matter. Learn how to write its long descriptive prompts, render English and Chinese text accurately, set CFG and steps, and explore layout-heavy creative ideas.
By Captain
2026-09-29