Image Stitcher
The Image Stitcher for comparison grids without the GIMP detour
- image1
- image2
- image3
- image4
- IMAGE
You've got four generations you want side by side - a seed comparison, a "which upscaler won" showdown, a row of reference poses for an image-edit model. In most tools that means an afternoon in GIMP. This node does it inside ComfyUI in one shot: feed up to four images in, get one canvas out, horizontal, vertical, or 2x2 grid, with a configurable gap between tiles. It's a tiny single-file pack from one author (ISK, published as vagr on the Comfy Registry), MIT-licensed, no models, no API, nothing to download beyond the node itself. It's also brand new and barely on anyone's radar - which means the rough edges are visible, and you should know them before you build a workflow around it.
How it actually works
The mechanism is the interesting part, because it has two personalities. In stitch_images the node collects image1 plus whichever of image2/image3/image4 you wired up, then picks a code path based on preserve_dimensions:
- enabled (the default) - the "smart canvas" path. It computes the exact canvas size from each image's native dimensions, centers shorter images inside each row or column, and pastes everything at native scale. No resizing, so no Lanczos blur, no pixel loss. This is the path you want.
- disabled - the legacy path, which resizes everything to a common height or width (via
comfy.utils.common_upscale, Lanczos) before concatenating. Handy if you want every tile forced to the same size.
The 2x2 grid is worth a warning: it pads to four slots, so if you only feed two or three images the missing tiles come back as solid black - or solid white if spacing_color is white. No empty slot logic beyond that.
The inputs that matter
Most of them are self-explanatory, so here's the short list you'll actually touch:
- image1 (required) plus image2/3/4 (optional) - the IMAGE tensors to combine.
- layout -
horizontal,vertical, or2x2_grid. - spacing - gap between tiles, 0–100 px.
- spacing_color -
white,black, ortransparentfor the gap and any padding. - preserve_dimensions - the enabled/disabled toggle above.
- grid_mode -
original_sizevsadjusted_size. Here's the trap: it only does anything whenpreserve_dimensionsis disabled. On the default path it's silently ignored. Don't fiddle with it expecting a change.
The single output is an IMAGE tensor, which wires straight into a Save/Preview node or onward into an img2img or image-edit pipeline - the author's own example workflow stitches four Greek statues into one canvas and feeds it to Seedream as a "fuse these into one new statue" reference. That's a genuinely good use for it.
Installing it
ComfyUI Manager → "Install Custom Nodes" → search "Image Combiner" → install, then restart. Or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/ISK-VAGR/ComfyUI-Image-Combiner
then restart ComfyUI. Dependencies are torch, Pillow, and numpy - all already present in any ComfyUI install, so there's nothing else to fetch. It registers under the ISK category as Image Stitcher.
The gotchas
Three things jump out when you read the source (__init__.py):
- It always writes a PNG, whether you ask for one or not. The node saves
{filename_prefix}_stitched.pngto your ComfyUIoutput/folder and then reloads it to produce its IMAGE output. No counter, no subfolder - every run overwrites the previous file. If you want to keep earlier stitches, rename or copy between runs. - The saved PNG has no workflow embedded. It's written with plain PIL, not ComfyUI's SaveImage, so it skips the PNG metadata that lets you drag an image back onto the canvas and recover the graph. The output tensor is also rounded through 8-bit PNG on its way out, so you're getting 0–255 precision, not full float.
- "Transparent" spacing is effectively black. The gap gets filled with zeros, the file's saved, and then the reload forces RGBA → RGB - which flattens alpha onto black. If you need real transparency in the output, this isn't the node for it; use white or black and composite downstream.
One more: it only takes the first frame of any batched input, so don't try to run it as a batch contact-sheet generator. For that, native concat nodes or a dedicated batch-to-grid pack serve better.
Bottom line
For its niche - a quick comparison grid or a multi-image reference sheet without leaving the graph - ImageStitcher works and costs nothing to install. It's a young, one-commit pack with a README that still has a yourusername placeholder in its clone URL, so treat it as a utility, not infrastructure. You'll know within one run whether it does the job.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| image1 | IMAGE | — | |
| layout | COMBO | horizontal | 3 options: horizontal, vertical, 2x2_grid |
| spacing | INT | 00–100 | — |
| spacing_color | COMBO | white | 3 options: white, black, transparent |
| preserve_dimensions | COMBO | enabled | 2 options: enabled, disabled |
| grid_mode | COMBO | original_size | 2 options: original_size, adjusted_size |
| filename_prefix | STRING | stitched_image | — |
| image2opt | IMAGE | — | |
| image3opt | IMAGE | — | |
| image4opt | IMAGE | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |