Brekel Save Image (PNG/JPG)
Save as JPG, fill the number gaps, and stop polluting your output folder
- images
- images
- filename
The stock SaveImage node is fine - until you want a JPG, or a preview that doesn't dump 400 files into your output folder, or a sequence that reuses numbers when you delete one. Brekel Save Image (PNG/JPG) is the standard save node with exactly those annoyances made configurable. Its defaults are basically the stock behavior - PNG, workflow embedded, ComfyUI_00001_.png numbering - and every difference is an opt-in knob. If you've ever wished the save node had a settings panel, this is it.
What you actually set
images- feed it the IMAGE output from a VAE decode.file_format-pngorjpg. PNG is lossless and keeps the drag-onto-canvas workflow trick; JPG is much smaller and stores its metadata in EXIF.quality- JPG quality (default 95). Ignored for PNG, so you can leave it alone.save- the headline feature. On, it writes to the output folder. Off, the node behaves like a Preview Image: images go to thetempfolder with a random suffix and the output folder's numbering is left untouched. Iterate with it off, flip it on when you commit. Genuinely handy for saving disk space during a long session.start_number- the first number in the sequence. Numbers below it are never used, so a render set can start at, say, 100 to match an existing run.fill_gaps(default on) - scans the folder and reuses deleted numbers. Deleteimage_00003_while_00004_exists and the next save lands back on_00003_, keeping the range continuous. Numbering is shared across PNG, JPG and WebP, so the two formats never fight over the same number.filename_prefix- the same template language as stock, so%date:yyyy-MM-dd%and%NodeName.widget%all work.
There's also an optional caption input. Wire it up and your text is embedded in the image instead of the workflow/prompt - written as parameters + Description PNG text chunks, or EXIF fields in a JPG. That pairs neatly with the pack's own Brekel Load Image node, which reads exactly those fields back, so you can round-trip captions through an img2img or upscale pass. An empty caption (an unconnected wire or blank box) falls back to the workflow metadata, which is a nice safety net.
It outputs the images passed through, plus filename - the last file written, without its extension - for chaining into another node's prefix or logging.
Where people get burned
The metadata rules are the same physics as everywhere else in ComfyUI. PNG is your master - it round-trips the whole workflow on drag-and-drop. JPG re-encodes, so the graph won't come back; its EXIF block is capped around 64KB, and when a big workflow overflows, the node drops the metadata rather than failing the save. That's a deliberate choice, and it means a very complex workflow may silently not make it into your JPGs. Fine for sharing, never your archive copy - keep the PNG.
Two honest caveats. First, if you post to CivitAI and want model auto-linking, this node writes the workflow/prompt but not the flat A1111-style parameters block with resource hashes that CivitAI keys on - a dedicated "Image-Saver"-type node is still the better upload tool. Second, the global --disable-metadata flag suppresses metadata here just like everywhere, which is how you stop your seed and prompt riding along in every file.
Install
Via ComfyUI Manager, search "Brekel" and install the pack, then restart. Manually:
cd ComfyUI/custom_nodes/
git clone https://github.com/Brekel/ComfyUI-Brekel.git
Restart ComfyUI and it shows up. No extra dependencies for this node - the pack's only pip requirements (bitsandbytes, accelerate) belong to its LLM prompt-enhancer, not the save node. If you're tired of the stock node's one-way street, this is a low-friction swap.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | The images to save. | |
| save | BOOLEAN | true | Turn off to act like a Preview Image node, the images go to the temp folder and the output folder and its numbering are left untouched. |
| filename_prefix | STRING | ComfyUI | The prefix for the file to save. This may include formatting information such as %date:yyyy-MM-dd% or %Empty Latent Image.width% to include values from nodes. |
| file_format | COMBO | png | PNG is lossless and can be dragged onto the canvas to restore the workflow, JPG is smaller but stores its metadata in EXIF. |
| quality | INT | 951–100 | JPG quality, ignored when saving PNG. |
| start_number | INT | 10–99999 | The first number of the sequence, numbers below this are never used. |
| fill_gaps | BOOLEAN | true | Re-use missing numbers in the sequence on disk instead of always appending after the highest one. |
| captionopt | STRING | When connected this text is embedded into the image instead of the workflow/prompt. |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |
| filename | STRING | — |