ComfyUI inpainting with folder batch reading, way more efficient for editing a batch of images.

I used this setup when demoing a batch processing workflow for students, figured it’s worth organizing. The key is pairing those crop-and-stitch inpainting nodes together—only process the area you mask out, leaving the rest of the image untouched. Workflow is: first draw a mask on the region, tweak the context range and edge softness, then use color matching to improve blending.

Swapping backgrounds, using transparent PNGs, or alpha masks all give cleaner edges. On the other end, pair it with a node that loads images from a folder in batch—whole folder gets processed automatically: resize, crop, change background, save with matching filenames, the whole pipeline.

Super handy for people who need to handle tons of images without manually loading each one. During the demo, students pretty much got it after watching once.

Yeah, the crop and stitch nodes are absolute lifesavers for fine-tuning.

Reading folders in bulk saves a ton of repetitive work.

Color matching really helps with blending, the edges don’t look off anymore.

You gotta tweak the context range and softness, the defaults aren’t always the right call.

The students really picked up on this workflow when I demoed it in class.

It’s a nice touch that it saves them with matching filenames.