ComfyUI Node

Save As

The output node when PNG-only starts to hurt

By AnimationOverhual·Created 2 years ago·Updated 2 years ago· 8
Save As
  • images
  • IMAGE
  • STRING
filename_prefiximage
file_type
raster_format
vector_format
quality100
ico_size_presetLarge (128, 256, 512)

ComfyUI's built-in Save Image node has exactly one job: write a PNG. That's great most of the time, and then one day you're generating app icons, or your output folder is eating your SSD, or a client wants a JPG, and you're stuck. Save As (class ComfyUISaveAs, from the SEkINVR/ComfyUI-SaveAs pack) is the fix: a drop-in output node that lets you pick the format - PNG, JPG, WEBP, ICO, GIF, BMP, or TIFF - with a quality slider on top. It's a small, single-purpose node, and for the one or two workflows where you need it, it does the job without drama.

How it works

It's a plain OUTPUT_NODE in the image/io category. You feed it an IMAGE tensor, and it converts each frame to a PIL image and writes it to ComfyUI's standard output directory using Pillow. That's the whole mechanism - no API, no models, no extra services. Under the hood the per-format details are handled by Pillow: JPG and WEBP get your quality setting, TIFF saves LZW-compressed, PNG saves with optimize=True, and ICO writes a real multi-size icon.

A couple of honest caveats before you get excited. First, the "Vector" file type is a packaging trick, not real vector output. SVG mode embeds your image as a base64 PNG inside an SVG envelope, and "AI" and "DRW" are literally SVGs renamed. The files are bigger than the source PNG, not smaller. Keep it on Raster for anything real. Second - and this is the one that burns people - unlike the built-in Save Image node, Save As does not embed the workflow JSON into the PNG metadata. ComfyUI's whole sharing culture runs on "drag my output PNG back in and the graph reconstructs." If you plan to share your images, keep using the core node for those; use this one for deliverables.

The inputs that matter

Most of the required fields are self-explanatory, but two are easy to misread:

  • quality (default 100) only affects JPG and WEBP. PNG, GIF, BMP, and TIFF ignore it entirely - they're lossless, so don't expect a lower quality setting to shrink them.
  • ico_size_preset (optional) only matters if raster_format is ICO. It picks the icon sizes to bake in: Small (32/48/64), Medium (64/128/256), or Large (128/256/512). This is the node's party trick - the included example workflow is literally a PC icon creator, and it's the reason you'd install this pack over a generic save node.

filename_prefix defaults to "image", and there's automatic dedup so you never overwrite an existing file. The two outputs are worth wiring up: it returns an IMAGE preview (a 512×512 white card with your image thumbnailed onto it and the format/filename printed underneath) and a STRING of the comma-joined filenames that got written - handy if you want to log what actually saved.

Installing it

Via ComfyUI Manager: search for ComfyUI SaveAS (or the repo name) and install. Or do it by hand:

cd ComfyUI/custom_nodes
git clone https://github.com/SEkINVR/ComfyUI-SaveAs

Then restart ComfyUI. The only real dependency is Pillow>=9.5.0, which ComfyUI already ships - the included install_requirements.sh just makes sure it's current, and you can safely skip it. One genuine gotcha: the vector formats need svgwrite, which is not in requirements.txt. If you flip to Vector without it, you'll get an ImportError. Since vector mode isn't worth much anyway, just don't.

Where people get burned

  • Animated output doesn't exist here. Batch frames save as separate files, and the GIF/WEBP save is single-frame. There's a real r/comfyui thread of someone discovering this the hard way - if you want animated WebP, use SaveAnimatedWebp.
  • Quality slider feels like a no-op on PNG. It is one, by design.
  • Missing workflow metadata when you share a Save As PNG. Again, keep the core node for shareable outputs.

It's a niche pack with essentially zero reputation footprint, and that's fine - for app icons, JPG exports, or WEBP to save disk space, it's the right tool. Just know what it's not: not a vector exporter, not animated, not metadata-aware.

Categoryimage/io

Inputs (7)

NameTypeDefaultDescription
imagesIMAGE
filename_prefixSTRINGimage
file_typeCOMBO2 options: Raster, Vector
raster_formatCOMBO7 options: PNG, JPG, WEBP, ICO, GIF, BMP, +1
vector_formatCOMBO4 options: SVG, AI, SVGZ, DRW
qualityCOMBO1009 options: 100, 95, 90, 85, 80, 75, +3
ico_size_presetoptCOMBOLarge (128, 256, 512)3 options: Small (32, 48, 64), Medium (64, 128, 256), Large (128, 256, 512)

Outputs (2)

NameTypeDescription
IMAGEIMAGE
STRINGSTRING