Save Images
The filename-obsessive's file saver
- images
- pipe_opt
- images
- files
ComfyUI's built-in Save Image works fine, but it doesn't care about your filing system. Save Images is the node that does: it names files from a template of placeholders, routes them into dated, model-named folders, and can embed workflow plus Civitai-style generation metadata so your output is as organized as your prompts are long. If you save a lot of generations and ever squint at a folder of ComfyUI_00042_.png files wondering which is which, this is aimed at you.
How it works
You feed it images, and it writes them out to ComfyUI's output folder using a filename template. The template supports placeholders the node resolves at save time - %today, %time, %basemodel, %seed, %sampler_name, %scheduler, %steps, %cfg, %denoise (plus %model and %clip_skip). The defaults are already sensible:
- output_path defaults to
%today/%basemodel- so files land inoutput/<date>/<model-name>/. - filename_prefix defaults to a template like
%today, %time, %basemodel, %seed, %sampler_name, %scheduler, %steps, %cfg, %denoise.
You also get the usual knobs: filename_delimiter (default _), filename_number_padding (default 4), a toggle for starting numbering, extension (png/jpg/jpeg/gif/tiff/webp/bmp), dpi, quality, optimize_image, lossless_webp, embed_workflow, and save_workflow_as_json. In short: everything a power user wants and the core node doesn't offer.
The input that makes the metadata work
There's one optional input worth understanding: pipe_opt. It accepts an RvTools pipe, and if you wire one in, the node pulls real generation data - model, seed, sampler, scheduler, steps, cfg, denoise, LoRA names - out of it instead of guessing. That's what makes %basemodel and %seed in your filenames actually resolve to something. The save_generation_data toggle then writes an A1111-style parameters block (with model/embedding/LoRA hashes computed the Civitai way) into the image metadata, and add_loras_to_prompt folds LoRA references into the saved prompt. If you ever upload to Civitai, this is the workflow: the site can read that metadata and rebuild your generation settings.
Outputs: images (passthrough, so you can keep processing after saving) and files, a list of the paths you just wrote - handy if you want to feed filenames into another node.
The inputs that matter
- images - what you're saving.
- output_path / filename_prefix - the templates; this is where the node's personality lives.
- pipe_opt - wire a pipe in if you want accurate generation metadata in names and EXIF.
Installing it
Part of the RvTools v2 pack - no model files. ComfyUI Manager → search RvTools → install ComfyUI-RvTools_v2, restart. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/r-vage/ComfyUI-RvTools_v2
Restart and confirm RvTools v2: Version 2.5.x in the console. Note the pack's requirements include piexif (EXIF writing) and Pillow (already in ComfyUI) - Manager handles these.
Troubleshooting
- Placeholders come out empty. If
%basemodelor%seedrenders blank, the node couldn't get generation data - connectpipe_opt(or ensure the upstream is an RvTools pipe carrying that info). No pipe, no metadata. - WebP isn't lossy by accident.
lossless_webpdefaults to true; if you want smaller webp files, turn it off. - Old v1 RvTools workflows fail to install because the original repo was deleted; v2 renamed all nodes. And the author has since moved on to ComfyUI_Eclipse, the successor pack.
Inputs (18)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| output_path | STRING | %today/%basemodel | — |
| filename_prefix | STRING | %today, %time, %basemodel, %seed, %sampler_name, %scheduler, %steps, %cfg, %denoise | — |
| filename_delimiter | STRING | _ | — |
| filename_number_padding | INT | 41–9 | — |
| filename_number_start | BOOLEAN | false | — |
| extension | COMBO | 7 options: png, jpg, jpeg, gif, tiff, webp, +1 | |
| dpi | INT | 3001–2400 | — |
| quality | INT | 1001–100 | — |
| optimize_image | BOOLEAN | false | — |
| lossless_webp | BOOLEAN | true | — |
| embed_workflow | BOOLEAN | true | — |
| save_generation_data | BOOLEAN | false | — |
| remove_prompts | BOOLEAN | false | — |
| save_workflow_as_json | BOOLEAN | false | — |
| add_loras_to_prompt | BOOLEAN | false | — |
| show_previews | BOOLEAN | false | — |
| pipe_optopt | pipe | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |
| files | STRING | — |