Empty Image
A solid-color canvas in pixel space
- IMAGE
Every workflow has a moment where you need a plain, solid-color image of a specific size - a canvas to composite onto, a backdrop to blend into, a colored base to run through img2img. Empty Image is that node: it generates a solid-color IMAGE tensor at whatever dimensions you ask for. Simple, but it sits underneath more tricks than you'd expect.
What it is
Four inputs, one output. width and height (defaults 512, up to 16384), batch_size (default 1, up to 4096), and color - an integer from 0 to 16777215, which is just 0xRRGGBB written as a decimal. color = 0 is black, 16777215 is white, and anything in between is the usual hex math (0xFF0000 = red = 16711680). The output is a [batch, height, width, 3] float tensor filled with that color. That's the whole mechanism - it allocates the tensor, fills it, hands it out.
The one input that always needs explaining: color is a big integer, not a hex string with #. If you type #FF0000 the node will either reject it or silently produce something you didn't mean - the field wants the raw number. It's worth remembering because it's the single most common beginner stumble on an otherwise trivial node.
Why you'd reach for it
The big sibling, Empty Latent Image, gets all the attention because it's the canvas the sampler paints on. Empty Image is the pixel-space equivalent, and it shows up in a very different set of places:
- Outpainting padding. The current community trick for extending a canvas with instruction models is to pad with a solid color and prompt "remove the red padding." Empty Image set to a loud color like pure red is how you make that pad, and its dimensions are what define how much canvas you're adding.
- Compositing bases. Feed it into ImageCompositeMasked or JoinImageWithAlpha to build a background before pasting a subject on top.
- img2img starts. Run a solid color through a sampler with a prompt and you get a cheap "anything" generation - people do this for texture tiles and test patterns.
- Batch testing.
batch_sizegives you N identical copies, which is handy when you want to test a downstream node's batch handling without generating N images.
What wires out of it
One output, IMAGE, typed like any other image tensor - so it plugs into anything that accepts an IMAGE: compositors, resizers, img2img chains, preview nodes. There's no mask output; if you need a full-white or full-black mask to go with it, Load Image (as Mask) with a matching color image or a mask-from-image node is the normal route.
Getting it and the gotchas
This is a founding-era node - it's been in ComfyUI's nodes.py since basically the beginning, no install, no model files. The gotchas are the color-format one above, plus a pair of easy confusions: it's easy to grab Empty Latent Image instead when you meant Empty Image (and vice versa) because the names are one word apart, and the outputs are entirely different types - one is a latent the sampler needs, the other is pixels you can already see. If a node downstream is complaining about a type mismatch, check which "Empty" you actually dragged in.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| width | INT | 5121–16384 | — |
| height | INT | 5121–16384 | — |
| batch_size | INT | 11–4096 | — |
| color | INT | 00–16777215 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |