Save Image (Dir + Name)
Save any image to any folder under a filename you actually chose
- images
ComfyUI's built-in SaveImage is fine until it isn't. It dumps every generation into output/ under a ComfyUI_00042_.png-style name, and the only control you get is a prefix plus an auto-incrementing counter. That's fine for casual runs. It's a pain the moment you want a file called client_revision_3.png sitting in a project folder instead of a wall of numbered PNGs.
This is where SaveImageCustom comes in. Displayed in the node menu as "Save Image (Dir + Name)", it's a single-node pack from a Chinese hobbyist dev (No22) that does exactly what the title says: save to a directory you choose, under a filename you choose, as png or jpg. The name is not a lie - that's the whole feature list, and that's the appeal.
Why you'd reach for it
The default save node gives you two knobs and a counter. This one gives you save_dir and filename, full stop. The classic use is delivery: you're producing images for a client, a dataset folder, or a directory structure some other tool expects, and you want them there with sensible names, not in the output pile. It also ends the "which of these 400 PNGs was the good one" hunt - each run produces a single, predictably named file.
It's a terminal node: no output sockets, nothing wires out of it. Think of it as a drop-in replacement for SaveImage at the end of a pipeline. And because it passes prompt and extra_pnginfo through as PNG text chunks, running from the UI still embeds the workflow - drag the PNG back onto the canvas and your graph reconstructs, exactly like the core node.
How it works
Under the hood it's a straightforward tensor-to-PIL save: it takes the IMAGE input, converts it to a PIL image (it tolerates both (C,H,W) and (H,W,C) layouts), auto-creates the target folder, and writes save_dir/filename.ext. Two behaviors are worth knowing before they bite you:
- No auto-counter on single images. Run it once and you get
filename.png. Run it again and the second run overwrites the first. Only batches get disambiguated, with_0000,_0001… suffixes. This node is for "I want this exact file in this exact place," not versioning - if you want timestamped archives, stick with core SaveImage or a heavier saver. - The preview wrinkle. If
save_diris inside ComfyUI's standard output directory, the saved file shows up in the UI as a normal output. Point it anywhere else - like a project folder - and ComfyUI can't show you that as an output, so the node copies a preview intotemp/instead. The real file is still where you told it to go, which is why people panic looking inoutput/and not finding it.
Inputs you'll actually set
- images - the IMAGE you'd normally feed to SaveImage.
- save_dir - any path; default
./outputs. Relative paths resolve from wherever you launched ComfyUI, so the default lands in anoutputs/folder next to your ComfyUI install, not inoutput/. Give an absolute path if you want it somewhere specific. - filename - the stem only, no extension; the node appends
.pngor.jpg. - format - png or jpg.
- quality - 10–100, default 90; only affects jpg.
- preview - toggle for the on-screen preview.
Installing it
The README is literally empty - zero bytes; docs are not this author's strength - but the install is the standard dance and there are no dependencies beyond ComfyUI's bundled numpy/torch/PIL. Easiest: ComfyUI Manager → Custom Nodes Manager → search "Save Image Custom" → Install → Restart. Or by hand:
cd ComfyUI/custom_nodes
git clone https://github.com/No-22-Github/ComfyUI_SaveImageCustom
Then restart ComfyUI. It's MIT-licensed, one Python file, nothing to download.
Gotchas
- JPG drops the workflow. The node embeds the graph as PNG text chunks, and JPEG can't carry them. A jpg is fine for sharing, but keep a PNG as your archive copy or drag-back-in dies.
- Feeding a latent gives you a Chinese error. Wire a LATENT in instead of an IMAGE and
_tensor_to_pilraises a ValueError - in Chinese - telling you to VAE Decode first. If you see a wall of Chinese text in the console, that's what it means. - Overwrite surprise. Single image plus a re-run equals a silently replaced file. Choose filenames carefully, or treat this as a delivery node rather than a history.
For a one-job utility it does its one job cleanly and without bloat. If you just need "put this image here, with this name," this is the one I'd reach for.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| save_dir | STRING | ./outputs | — |
| filename | STRING | output | — |
| format | COMBO | 2 options: png, jpg | |
| quality | INT | 9010–100 | — |
| preview | BOOLEAN | true | — |
Outputs (0)
No outputs