Image Format Converter (Creepybits)
Batch-convert that image folder to webp in one click
- status
If you've ever stared at a folder with 2,000 PNGs eating your disk space, Image Format Converter is the node you wish you'd had an hour ago. It walks a directory (and every subdirectory under it), finds every image matching your target formats, and converts them to the format you pick. PNG to webp at quality 85 is the classic use - often half the file size for visually identical output. But it works in any direction the dropdown allows: webp, png, jpg, jpeg, or bmp.
The key safety feature is that it copies by default. delete_original is a boolean that defaults to false, so a run just drops new converted files next to the originals. You verify the results, and only then flip delete_original on if you want the old files gone.
How it works
The node uses os.walk, so unlike the pack's File Sorter (top-level only), this one is fully recursive - it will process every image in the tree under source_folder. For each file whose extension is in source_formats, it opens it with Pillow and saves a new file with the target extension in the same directory. So render.png becomes render.webp, sitting right beside it.
Two details in the conversion logic worth knowing:
- Converting to jpg/jpeg from a PNG with transparency flattens the alpha by converting to RGB - expected, but don't be surprised when your transparent logo becomes a black-background rectangle.
- The
qualityslider (1-100, default 85) only actually applies to jpg, jpeg, and webp, the formats that support it. PNG and bmp saves ignore it.
It also skips any file that's already in the target format - converting png→png just counts as "skipped," not an error.
Inputs and outputs
source_folder- root of the conversion.source_formats- comma-separated list of extensions to look for, e.g.png, jpg, jpeg.target_format- the dropdown destination.quality- compression quality for jpg/webp.delete_original- the dangerous one. False by default. Leave it false until you've checked the output.
The single output is a status string that reports converted / skipped / error counts. It's a report, not data - you're not meant to wire it anywhere, just read it.
Installing it
It ships in ComfyUI-Creepy_nodes:
- ComfyUI Manager: search "Creepy_nodes" and install.
- Manual:
cd ComfyUI/custom_nodes git clone https://github.com/Creepybits/ComfyUI-Creepy_nodes.git
Restart ComfyUI. Pillow is a dependency, but ComfyUI already requires it, so there's nothing extra to install for this node.
Troubleshooting
Two things to keep in mind. First, path errors return a plain status message ("Source folder ... does not exist") rather than a graph error - read the status output if a run "does nothing." Second, the "errors" count in the status string is the only sign of individual file failures, and the node logs those to the console. If a handful of images aren't converting, check the terminal for the per-file reason. And seriously: keep delete_original false on the first run. It's called "safety first" in the code, and that habit will save you at least once.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| source_folder | STRING | C:\path\to\your\images | — |
| source_formats | STRING | png, jpg, jpeg | — |
| target_format | COMBO | 5 options: webp, png, jpg, jpeg, bmp | |
| quality | INT | 851–100 | — |
| delete_original | BOOLEAN | false | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| status | STRING | — |