Seed (rgthree)
Seed (rgthree)
- SEED
If you came to ComfyUI from Automatic1111, this is the node that makes the seed field feel like home again. That's the entire reason it exists, and it's a small, boring, load-bearing little box that ends up in a huge number of workflows.
Why you'd reach for it
The stock way to handle seeds in ComfyUI is the number widget baked into the KSampler, with a "control after generate" dropdown set to fixed, increment, or randomize. It works, but it's clumsy: the seed you actually used gets overwritten the instant you queue the next run, so if you got a great image and want to nail down its exact seed, you're scrambling to copy it before it changes. The Seed node fixes that workflow. You drop it on the canvas, wire its output into the KSampler's seed input, and now you've got a dedicated control that behaves the way you expect - set once, reuse deliberately, randomize on purpose.
It's the same instinct behind the whole rgthree pack: nothing here generates anything, it just makes a big graph pleasant to actually work in.
How it works
The value in the widget is what gets sent to the sampler. The convention rgthree borrowed from A1111 lives in a couple of magic numbers:
- Set it to -1 and every run rolls a fresh random seed.
- Set it to any real number and that's your fixed, static seed - the same one every time until you change it.
There are two lesser-known extras baked in, too: set the value to -2 or -3 and it'll increment or decrement the last seed each run, which is handy for walking through a neighborhood of nearby seeds. And because the seed gets written into your image's metadata, dragging a saved generation back into ComfyUI brings its seed along with it, already fixed - so reproducing an old result is drag-and-done.
The node also plays nicely with rgthree's Fast Actions Button, which can trigger "randomize each time" or "reuse last queued seed" on this node with a click, if you want a dashboard-style control panel over your seeds.
The one input and one output
There's really only one thing to set here:
- seed - an integer. Type a number to fix it, or
-1to randomize. The allowed range is enormous (roughly ±1.1 quadrillion), which is just there so you never collide with the ceiling; the specific number's magnitude doesn't matter, only that it's consistent.
The single output is SEED, an INT. Wire it into the seed slot of your KSampler - or anywhere else that wants an integer, since it's just a number. Feeding one Seed node into several samplers is a clean way to keep an entire multi-stage workflow (base pass, refiner, upscale) locked to the same seed.
Installing it
The node is part of rgthree-comfy. Grab the pack through ComfyUI Manager by searching rgthree's ComfyUI Nodes, or clone it directly:
cd ComfyUI/custom_nodes
git clone https://github.com/rgthree/rgthree-comfy.git
Restart ComfyUI afterward. No model files, no extra Python packages - it's a pure UI-and-graph pack, so there's nothing to download beyond the code itself.
Common issues
Honestly, this node barely has failure modes - it outputs an integer. The one thing people trip on is expecting the node to control randomization while also leaving the KSampler's own "control after generate" set to randomize; then you've got two things fighting over the seed. Wire the Seed node in and leave the sampler's built-in control on fixed, so this node is the single source of truth.
The other thing worth knowing: if this node ever renders oddly or its controls stop responding, check whether ComfyUI's Nodes 2.0 (the Vue frontend) is switched on. It broke rendering for a number of rgthree nodes and the community's standing fix is to keep it off until the compatibility work catches up. The Seed node itself is a simple widget and usually survives it, but it's the first thing to rule out.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| seed | INT | 0-1125899906842624–1125899906842624 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| SEED | INT | — |