Get DateTime
Stamp a real timestamp into your outputs before the cache lies to you
- STRING
A node that just tells you what time it is sounds pointless, right up until you're 400 renders into a folder full of image_001.png and can't tell which batch came from today. Get DateTime outputs the current date and time as a string you can wire anywhere, most usefully into a Save Image filename so every run lands with its own timestamp instead of clobbering the last one.
It's a one-input, one-output utility from drupsys/comfy-utils - which, as packs go, is about as minimal as it gets: the whole pack is this single node in a single Python file. No models, no weights, nothing to download.
The trick that makes it actually work
Here's the thing most people don't realize about date nodes: a naive one doesn't work. ComfyUI caches aggressively. It only re-executes nodes whose inputs changed, and a date node's inputs never change, so a careless implementation stamps the time you loaded the workflow and then sits frozen for the rest of the session. Run the queue at 3pm and get the timestamp from 9am. Infuriating.
The author sidesteps this with the classic IS_CHANGED trick: the node returns float("NaN") as its change signal. NaN isn't equal to anything, not even itself, so ComfyUI always sees the node as changed and re-runs it every execution. That's the same idiom the ComfyUI docs describe for any node that must fire each run - a clock, a counter, a random picker. It's cheap here because the node has no inputs and does nothing heavy. Many homebrew date nodes get this wrong; this one got it right, which is exactly what you want in a tool whose whole job is being fresh.
Inputs and outputs
Only one input matters:
format- a strftime format string, default%Y-%m-%d.%Yis the four-digit year,%mthe month,%dthe day; add%H%M%Sfor a time (%Y%m%d-%H%M%S→20260827-143022), or use%Afor the weekday name. Whatever Python'sstrftimeunderstands, this node passes through.
The single output is a STRING: the formatted timestamp. Wire it into the filename_prefix of a Save Image node for timestamped files, or into any other string socket - a text node, a logging node, whatever wants it.
Install
Via ComfyUI Manager, search the pack title comfy-utils, or clone it directly:
cd ComfyUI/custom_nodes
git clone https://github.com/drupsys/comfy-utils
Then restart ComfyUI. No requirements.txt, no pip install, no model downloads - the node is pure Python stdlib (datetime), so it works on any OS and every ComfyUI version. Fair warning: the pack's README is empty, so this description is straight from the shipped source, and the author's public footprint is close to zero. If it doesn't show up in Manager yet (new pack, zero traffic), the manual clone above is the reliable route.
Where people get burned
Two real gotchas, both about filenames, both easy to avoid. First: a format like %H:%M:%S contains colons, and Windows refuses to create filenames with them - you'll get a "directory name is invalid" error the moment Save Image tries. Use %H-%M-%S or drop the colons. Second: the node always reports now in your machine's local time, not UTC, so a shared workflow produces different filenames for people in different timezones. Harmless, but surprising the first time.
And one expectation to set: it re-stamps on every run, on purpose. If you wanted one fixed label for an entire batch session, that's a different tool - this one is for keeping every output distinct, which is exactly what it does.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| format | STRING | %Y-%m-%d | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | — |