Dev builds a ComfyUI node that truly frees VRAM via the internal /api/free endpoint

JustLookingForNothin · reddit · 2026-08-27

The author hit system lockups after 2-3 generations when using large BF16 video models like Krea2 — a VRAM overflow, while smaller FP8/INT8 models ran fine. ComfyUI's toolbar "Free model and node cache" button unloads models from both VRAM and system RAM, but in-graph cache-clearing nodes go through Python-level model management objects and never fully release memory, so usage creeps up until a hard restart.

With Claude's help, the author built an open-source node that calls ComfyUI's own internal REST endpoint — POST /api/free with unloadmodels and freememory — the same path the toolbar button uses, reliably freeing VRAM/RAM. The node is a wildcard passthrough (like Reroute), so it can be inserted anywhere in a chain without breaking connections. Install:

cd ComfyUI/customnodes/

git clone https://github.com/VRAM-Hoarder/ComfyUI-Freemodelandnodecache.git

Submitted to ComfyUI Manager; for now install manually from GitHub.

Original post →

More from coding & agent

coding & agent channel →