Stable diffusion model failed to load (model can’t be loaded — the real cause is above)
AUTOMATIC1111 couldn’t load the selected checkpoint; this line is just the summary, the real reason is before it.
The message
loading stable diffusion model: OutOfMemoryError … Stable diffusion model failed to load
Affects: AUTOMATIC1111 Stable Diffusion WebUI
Why is this happening?
If loading a model fails, the WebUI first writes “loading stable diffusion model:” with the error type and the progress, then “Stable diffusion model failed to load”. Common reasons: not enough VRAM (OutOfMemoryError), a broken or incomplete model file, a model type AUTOMATIC1111 doesn’t know (for example, Flux), or damaged PyTorch after an update.
How to fix it
- Scroll up in the console window to the line “loading stable diffusion model:”. The error type after it and the last line of the progress tell you what’s really going on.
- If it says
OutOfMemoryError: Put the option--medvraminwebui-user.batatset COMMANDLINE_ARGS=(for SDXL only:--medvram-sdxl, with 4 GB VRAM--lowvram). Close programs that use VRAM, for example the browser with many tabs. Under Settings > Stable Diffusion, “Maximum number of checkpoints loaded at the same time” should be set to 1. - If it says
SafetensorErroror “Error while deserializing header”: The file is broken or incomplete. Download it again. - If it’s a Flux model: AUTOMATIC1111 doesn’t support Flux. Use Forge or ComfyUI for that. SD3 is only supported starting with AUTOMATIC1111 1.10.0.
- If the error happens after an update with all models: Add
--reinstall-torchonce toCOMMANDLINE_ARGSand start it. If that doesn’t help, delete thevenvandrepositoriesfolders and let the WebUI reinstall everything. - If you have little RAM (8 GB): The WebUI needs about 16 GB RAM. Increase Windows’ paging file.
Better not: Use --disable-safe-unpickle only if you trust the model file for sure: This option turns off the malware check in .ckpt files.
Terms for this
Similar errors
- ControlNet: Error(s) in loading state_dict … size mismatch (ControlNet does not match the base model)
- No checkpoints found (No model found in the model folder)
- SafetensorError: incomplete metadata / MetadataIncompleteBuffer
- A1111/Forge: A tensor with NaNs was produced (black image)
- A1111/Forge: Torch is not able to use GPU
Sources
- https://github.com/AUTOMATIC1111/stable-diffusion-webui/blob/master/modules/sd_models.py
- https://raw.githubusercontent.com/wiki/AUTOMATIC1111/stable-diffusion-webui/Troubleshooting.md
- https://github.com/AUTOMATIC1111/stable-diffusion-webui/issues/12992
- https://github.com/AUTOMATIC1111/stable-diffusion-webui/issues/9991
Checked on Oct 27, 2026. Didn't help? Ask in the forum and name the graphics card, program, and the full message.