Save Image Direct - Ostris
Save anywhere, caption as a sidecar
- image
Core ComfyUI's Save Image is happy to write into your output folder and nowhere else. Save Image Direct - Ostris is the "actually, put it here" node: you give it a full filesystem path and it writes the image exactly there, creating directories as needed, and if you want, drops a caption text file beside it. That's the whole pitch, and it's more useful than it sounds.
Three inputs, all worth knowing:
- image - what you're saving. The tooltip says "The images to save," and the plural is doing a lot of work, because it only actually saves one. Feed it a batch and it silently keeps the first frame. More on that below.
- caption - optional multiline text that gets written to a
.txtfile with the same name as the image. Leave it empty and no file is written. It's marked as a forced input, so you can wire it straight from a text or caption node rather than typing. - save_path - the full path to write to, defaulting to
output.pngin ComfyUI's output directory. This is the star of the show: point it anywhere on disk, including entirely outside ComfyUI, and the node creates the folders and writes there.
The mechanism is the standard ComfyUI save with the training wheels off. PNG output embeds the workflow prompt and metadata in the file (handy for sharing), JPEG/JPG saves at quality 95 with no chroma subsampling, WebP at quality 95. Anything else - say, .gif or no extension at all - raises a clear "Unsupported file type" error instead of silently producing garbage. The caption sidecar is written as plain text, one file per image, which is exactly the format folder-scanners and dataset pipelines expect.
Now the trap, because it's a real one: only the first image of a batch is saved. The node truncates to image[0] internally, so if you feed it a 4-image batch expecting four files, you get one file and no warning. Don't build a "save every frame" pipeline on this. Either loop your generation one image at a time or use a proper per-batch saver. For single-image output - which is most of what a save node does - it's a non-issue.
Where it shines: writing generation results into a dataset folder with captions attached, or routing output to a specific directory outside ComfyUI's output/ that some other tool watches. It pairs naturally with the Batch Image Loader from the same pack, which reads images one per run along with their .txt captions - load, process, save back, and the caption round-trips through the folder untouched. They were added to the pack in the same commit for exactly that reason.
Install with the rest of the Ostris Nodes pack: ComfyUI Manager, search for Ostris Nodes, restart, or:
cd <your_comfyui_folder>/custom_nodes
git clone https://github.com/ostris/ostris_nodes_comfyui.git
cd ostris_nodes_comfyui
pip install --upgrade -r requirements.txt
It's a small node from an experimental pack, and the batch-truncation behavior means it's not a universal saver. But for "save this one image to this exact path, caption attached," it's the simplest tool I've used, and that specific niche is harder to fill in core ComfyUI than you'd think.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | The images to save. | |
| caption | STRING | Caption to save with the image. Will be saved in a .txt file with the same name as the image. | |
| save_path | STRING | /tmp/ComfyUI/output/output.png | Full path to save image to. |
Outputs (0)
No outputs