Datetime String
Stamp the current date and time into a workflow
- STRING
JWDatetimeString outputs the current date and time as text, formatted however you tell it. The obvious use is filenames: stamp a render with the moment it was made so every output is unique and sorts chronologically, no counter to manage. Instead of overwriting output.png every run, you get 2026-08-02T14-33-10.png and a folder that reads like a timeline.
It's a small quality-of-life node, but "unique, sortable output names for free" is the kind of thing that saves you from accidentally clobbering a good result. Wire it into a save path and forget about it.
How it works
Every time the node runs it reads the current clock and formats it with a Python strftime string. The default %Y-%m-%dT%H:%M:%S gives you an ISO-style timestamp like 2026-08-02T14:33:10. The format codes are the standard ones:
%Yfour-digit year,%mmonth,%dday%Hhour (24h),%Mminute,%Ssecond
So %Y%m%d → 20260802, and %Y-%m-%d_%H-%M-%S → 2026-08-02_14-33-10. Mix in literal text freely: render_%Y%m%d works fine.
The inputs and outputs that matter
format(STRING) - the strftime format, default%Y-%m-%dT%H:%M:%S. This is the only input, and it's the knob that matters - shape the timestamp to whatever your filenames or labels need.- Output:
STRING- the formatted date/time text.
How to install it
Part of jamesWalker55/comfyui-various, a pack of small utility nodes.
- ComfyUI Manager: search "Various ComfyUI Nodes by Type", install, restart. Red node from a downloaded workflow? Install Missing Custom Nodes.
- Manually:
Restart afterward. No models, no dependencies.cd ComfyUI/custom_nodes git clone https://github.com/jamesWalker55/comfyui-various
Under the jamesWalker55 category after restart.
Common issues
- Colons in a filename cause trouble. The default format uses
:for the time, and Windows (and some tools) won't allow colons in filenames. If you're building a save path, swap to something like%Y-%m-%d_%H-%M-%Swith dashes and underscores instead. This is the single most common gotcha with this node. - Which clock is it? The timestamp reflects the machine ComfyUI is running on, in that machine's timezone. On a cloud or serverless host, that's the server's clock, which may be UTC rather than your local time - expect a possible offset.
- The value looked cached. It's evaluated when the node runs. If a run is served entirely from cache and nothing re-executes, you may see a stale value; a fresh execution updates it.
- Node is red / missing. The pack isn't installed. Install via Manager or clone the repo, then restart.
Pair it with JWStringConcat to sandwich the timestamp between a prefix and an extension, and you've got tidy, collision-proof output names with zero bookkeeping.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| format | STRING | %Y-%m-%dT%H:%M:%S | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | — |