ComfyUI Node

Easy Save Image

A save node that keeps your filenames (and your prompts)

By mengod-gh·Created 3 months ago·Updated 3 months ago· 0
Easy Save Image
  • images
  • mask
  • job
    filename
    extension_selectpng
    path_enabledfalse
    path
    exif_enabledtrue
    positive
    negative
    extension

    The stock Save Image has a one-track mind: dump the PNG in output/ with a timestamped prefix. Fine for generation. Wrong tool for dataset work, where the filename is the point - you need each processed image saved under the same name as its source, or under a controlled auto-increment scheme, with your prompt and settings riding along in the file. Easy Save Image is that tool, and it's the save half of ComfyUI-Easy-Image-Nodes' load-process-save loop.

    The filename behavior is the whole personality

    It flips based on whether the filename input is connected:

    • Connected: the value is treated as the exact output filename, and existing files are overwritten. Wire the loader's relative_path here and output/ mirrors your input folder, subfolders and all.
    • Not connected: the value becomes an auto-incrementing prefix. Empty prefix → 0001.png, 0002.png…; animaanima_0001.png…; and it never overwrites an existing file.

    That dual meaning catches people. Connected means "this is the name, clobber it"; unconnected means "this is the prefix, find the next free number". If you connect a stem expecting no-overwrite semantics, you'll be surprised the first time you overwrite.

    The prefix is also a small template language, like core SaveImage's: %date:yyyy-MM-dd%, %width%, %height%, and %Node Title.input_name% to pull a live widget value from any other node. Dated or sized subfolders become one-line prefixes.

    Inputs you'll actually set

    extension_select is png/jpg/webp (default png). path_enabled + path puts output in a subfolder under output/ (e.g. cleaned), stacked on top of any folders in the filename itself. The optional extension input overrides the format selector - connect a loader's extension output and the original format is preserved automatically. Optional positive/negative strings get stored as an A1111-style parameters block in the PNG metadata; exif_enabled (default on) controls whether prompt/workflow metadata is written at all - flip it off for clean files with nothing embedded. And mask feeds a mask in as alpha (mask 0 opaque, mask 1 transparent).

    Outputs: none. It's an output node; it returns the saved image to ComfyUI for preview and history, and its actual job is the file on disk.

    How it works

    It's stricter than the stock node about exactly one thing: one image per execution, enforced in code. Hand it a batch and it errors rather than silently writing a mess. PNGs get the prompt and workflow text chunks like ComfyUI's own save - the metadata that lets you drag a PNG back onto the canvas and rebuild the graph - plus the flat A1111 parameters block that CivitAI's uploader auto-detects, so your uploads get their model auto-linked. JPEG saves at quality 100, WebP lossless; both skip the graph metadata because those formats can't carry it. Only output/ is ever written; absolute paths and .. are rejected. And when job is connected (from the folder loader with auto_requeue on), a successful save automatically queues the next image.

    Where people get burned

    If you're feeding it batched output from a sampler, split the batch first - one image per run, period (which is why it pairs so naturally with the folder loader, which feeds one at a time). For dataset work, connect the loader's relative_pathfilename and use path=cleaned for a staging dir, keeping your originals untouched. And mind the format trade: PNG is the only one that keeps the workflow graph; treat JPEG/WebP as derivatives, never your master copy.

    Install

    ComfyUI Manager → "ComfyUI-Easy-Image-Nodes", or:

    cd /path/to/ComfyUI/custom_nodes
    git clone https://github.com/mengod-gh/ComfyUI-Easy-Image-Nodes.git
    

    Restart ComfyUI after. No models, no extra dependencies.

    If you generate one-offs, the stock node is fine. If you're grinding a dataset and want the filenames to mean something on the other side, this is the save node to reach for.

    CategoryEasy Image Nodes

    Inputs (11)

    NameTypeDefaultDescription
    imagesIMAGE
    filenameSTRING
    extension_selectCOMBOpng3 options: png, jpg, webp
    path_enabledBOOLEANfalse
    pathSTRING
    exif_enabledoptBOOLEANtrue
    positiveoptSTRING
    negativeoptSTRING
    extensionoptSTRING
    maskoptMASK
    joboptEASY_IMAGE_JOB

    Outputs (0)

    No outputs