Date Time Format
Put the current date and time in your filenames
- STRING
If you save images with any sort of system, you've hit the moment where every file is named 00001_00001_ and you can't tell which was made on Tuesday. Date Time Format exists to fix that: one input, one string output containing the current date and/or time, formatted however you like. Wire it into a filename prefix and your outputs start organizing themselves.
It's the smallest node in the pack, but it quietly depends on one of ComfyUI's more obscure mechanisms, so it's worth knowing how it earns its keep.
How it works
The node calls datetime.now().strftime(format) the instant it executes. One line of Python, but the clever part is the class marks IS_CHANGED to return NaN. In ComfyUI terms that means "never cache me" - the node re-runs on every queue, every single time. Without that, ComfyUI would look at the inputs, see nothing changed, and hand back the previous result, and you'd get the same timestamp baked into every file you ever made. The NaN IS_CHANGED is the whole node.
The one input
- format - a strftime format string. Same codes you'd use in Python or any Unix tool:
%Y-%m-%dfor date,%H:%M:%Sfor time,%Afor the weekday name. Leave it empty and you get an empty string, so don't.
Useful starter formats:
%Y-%m-%d_%H-%M-%S → 2026-08-11_14-05-33
%Y%m%d → 20260811
%H%M%S → 140533
Output is a single STRING, so it plugs into any text input - most commonly the filename prefix on a Save Image node, or a text-concat node to build richer names.
Gotchas
- It's local time, captured when the node runs, not when you type the format. The string is fixed at queue time, so re-queuing is how you get a fresh timestamp.
- It won't update live on the canvas as the clock ticks - you'll see the value from the last run until you queue again.
- It's a tiny stdlib-only node, so it's cheap and safe to leave in any workflow.
Install
Via ComfyUI Manager, search "hus' utils" (pack title: hus' utils for ComfyUI). Or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/hustille/ComfyUI_hus_utils
Restart ComfyUI. No requirements.txt, no pip step, no model downloads. The pack is pure Python standard library plus ComfyUI internals - about as dependency-light as custom nodes get.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| format | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | — |