Add Filename Prefix
Add a timestamped prefix to every saved file, without touching your prompt
- string
If you've ever run a batch, gone to look at the output folder, and found twenty files called image_00001_.png, you already know why this node exists. Add Filename Prefix from ComfyUI_Eclipse is pure string glue: it takes a filename prefix, optionally stamps it with the current date and time, and joins it onto a base path. The result is a string you can feed straight into a save node, so every run lands in its own uniquely-named file instead of clobbering the last one.
ComfyUI's save nodes already write the full workflow into the PNG as metadata - drag a file back onto the canvas and the whole graph reconstructs. That's exactly why unique filenames matter: the image is the project file, and a timestamp in the name is your cheap archaeology layer when you're hunting for "the good one from Tuesday."
How it works
It's an os.path.join under the hood, with a datetime formatter bolted on. You give it a file_name_prefix (default "image"), and it decides what to do with a date/time stamp based on the add_date_time combo - disable, prefix, or postfix:
prefixβ2026-08-25_14-03-22_imagepostfixβimage_2026-08-25_14-03-22disableβ justimage
The date_time_format field is a Python strftime string, so the default %Y-%m-%d_%H-%M-%S gives you the sortable format above, and you can swap in whatever you like. If you pass a garbage format string, it silently falls back to %Y-%m-%d-%H%M%S rather than erroring - a nice touch.
The inputs and output that matter
file_name_prefix- the name part you control. Defaults to"image".add_date_time- the combo that turns the stamp on, and where it goes.date_time_format- the strftime pattern; leave it alone unless you have opinions.path_opt- optional base path the prefix gets joined onto. Wire this from a Folder Path or Add Folder node and you've built a full output path in one place.- Output: a single
string. Wire it into a Save Images path input, a filename builder, or another string node.
The stamp is captured with datetime.now() at execution time, so it reflects the run that actually produced the file - not when you saved the workflow. That's the behavior you want for batch logging.
Installing it
It ships in the ComfyUI_Eclipse pack, so you install the whole pack once:
cd ComfyUI/custom_nodes
git clone https://github.com/r-vage/ComfyUI_Eclipse
then restart ComfyUI. ComfyUI Manager also finds it if you search for "ComfyUI Eclipse". The declared dependencies (torch, numpy, Pillow, opencv-python, and friends) are almost all already in a base ComfyUI install - this node only really needs the standard library and os.path, so you won't hit a missing-import wall here.
Gotchas
The big one is pack-wide: ComfyUI_Eclipse used to be called RvTools, and v4.0.0 deleted every legacy node. If you're pulling an old workflow that used the Eclipse folder nodes, load it and run the Workflow Migration Tool node (or python tools/migrate_workflow.py <workflow.json> from the pack folder) to rewrite the old IDs with a backup.
And one expectations check: this node only builds the string. It doesn't create folders or write files - pair it with Add Folder for directory structure and let your save node do the actual disk work.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| file_name_prefix | STRING | image | Filename prefix to join to the base path. |
| add_date_time | COMBO | Add date/time to the filename prefix. | |
| date_time_format | STRING | %Y-%m-%d_%H-%M-%S | Date/time format for prefix/postfix. |
| path_optopt | STRING | Optional base path to which the filename prefix will be added. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| string | STRING | β |