Integer to String
The two-second conversion that fixes filenames
- STRING
Integer to String converts a whole number into text, full stop. Feed it the integer 42 and it outputs the string "42". No formatting, no padding, no locale tricks - it's a straight str() cast wearing a node costume. Which sounds too trivial to deserve an article, until you've spent an hour wondering why your filename comes out empty and the answer turns out to be that the filename builder wanted text and you handed it a number.
That's the actual use case, and it's a genuinely common one. ComfyUI's save-image and filename nodes are picky about types - many of them take a STRING prefix and quietly do nothing useful with an INT. If you're building a filename from a seed (a very normal thing to do so your output files are reproducible), you need the seed's number as text first. Same story for batch indexes, loop counters, and any other integer you want visible in a label, a metadata field, or a filename. This node is the adapter that makes those integer values speak string.
It also quietly helps with the pack's own pipe-and-settings style: when you're assembling strings out of mixed data (see the Merge Strings nodes in the same pack, which only join text), every number you want included has to become text somewhere. This is that somewhere.
Inputs and outputs
- int_ (INT, required) - the number to convert. It's marked
forceInput, so you connect an integer source (a seed node, a counter, a math output) rather than typing it in. - Output STRING - the number as text, ready for a filename builder, a Display Text node, or string merging.
There is genuinely nothing else on this node. One port in, one port out.
Installing it
Ships in ComfyUI-RvTools_v2:
cd ComfyUI/custom_nodes
git clone https://github.com/r-vage/ComfyUI-RvTools_v2
Restart ComfyUI, or install via ComfyUI Manager by searching "RvTools". No model downloads; dependencies are the standard torch/numpy/Pillow plus opencv-python, pilgram, pynvml and piexif, handled automatically.
Gotchas
The pack README flags it as no longer maintained, pointing to ComfyUI_Eclipse (same author) as the successor. The node still works; just know it's on the legacy line.
The one thing that trips people up is the forceInput design. You can't just double-click and type a number - you have to wire one in. That's intentional (this is a converter, not a number box), but if you're mid-flow and want a manual number, grab a plain integer widget and connect it here. Also note the input is clamped to non-negative values (0 to a very large max), so negative numbers aren't in its vocabulary. For those you'd convert a float, or handle the sign upstream.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| int_ | INT | 00–18446744073709550000 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | — |