Free | No tracking | Every fact with a source|German and English

Error / Memory

Allocation on device (ComfyUI reports too little VRAM)

ComfyUI ran out of graphics memory while executing a node and aborted the run.

The message

torch.OutOfMemoryError: Allocation on device … This error means you ran out of memory on your GPU. TIPS: If the workflow worked before you might have accidentally set the batch_size to a large number.

Affects: ComfyUI

Why is this happening?

This is ComfyUI’s version of “CUDA out of memory.” ComfyUI also adds the note that an accidentally too-large batch size is often the cause. After the error, ComfyUI unloads all models, so a second try can sometimes work. According to the ComfyUI developers, the message “Allocation on device 0 would exceed allowed memory” usually means the model barely fits in VRAM.

How to fix it

  1. Click “Show report” in the error dialog and see which node is affected (for example, KSampler or VAE Decode).
  2. Check batch_size in the “Empty Latent Image” node and in image-loading nodes. Set it to 1.
  3. Reduce the resolution or, for video models, the number of frames.
  4. Update ComfyUI (Portable: update\update_comfyui.bat, Desktop: Manage → Update → Check for update). Newer versions manage memory better.
  5. If that doesn’t help, go through the steps in the “CUDA out of memory” entry (--lowvram, --novram, --reserve-vram).

Set up from scratch again

If it still doesn’t work after that, a fresh setup step by step often helps:

Terms for this

Similar errors

Sources

Checked on Oct 21, 2026. Didn't help? Ask in the forum and name the graphics card, program, and the full message.