Save image with CivitAI-compatible metadata
A SaveImage replacement that actually gets your resources recognized
- image
- ui_widget
- file_names
- civitai_metadata
There's a recurring thread on r/civitai and r/comfyui: someone uploads an image generated in ComfyUI, and the "resources used" section on the model page comes up empty - no checkpoint, no LoRAs, nothing auto-detected. The default SaveImage node just doesn't write metadata in the shape CivitAI's parser looks for. LF_SaveImageForCivitAI exists specifically to close that gap - it's a save node built to embed CivitAI-compatible metadata alongside your image, not just a generic workflow dump.
It works like a normal save node with a few extra knobs. image is your input, filename_prefix sets the path and name (slashes work for subdirectories), add_timestamp (on by default) appends the execution time so repeated saves don't collide, embed_workflow (also on by default) bakes the full ComfyUI workflow into the file so it's drag-and-drop reproducible, and extension lets you pick png, jpeg, or webp - with quality controlling compression for the latter two. The part that makes this node worth reaching for over plain SaveImage is the optional civitai_metadata input: feed it the metadata_string output from LF_CivitAIMetadataSetup, and that's what gets embedded in a form CivitAI can actually read back out. Outputs come back as file_names (a list, since you can save a batch) and civitai_metadata, echoing what you fed in so you can chain it elsewhere - into LF_SaveJSON for an archival copy, say.
There's also a KUL_MASONRY gallery widget on the node showing what's been saved in a grid - display only, not something you configure.
Installing it. ComfyUI Manager: search "LF Nodes," install, restart. Manually: cd ComfyUI/custom_nodes && git clone https://github.com/lucafoscili/lf-nodes, restart. That's the actively maintained repo - comfy.icu's node listing links comfyui-lf, the pack's original home, but the author archived it after migrating everything to lf-nodes; same nodes, new address. Nothing to download beyond the pack itself - no models, no GPU-heavy dependencies.
Where people get tripped up. The single most important thing: this node only embeds what you actually wire into civitai_metadata. Leave that input empty and you've just got a fancier SaveImage with a gallery widget - none of the CivitAI-specific behavior kicks in without pairing it with LF_CivitAIMetadataSetup upstream. Second, even correctly embedded metadata isn't a 100% guarantee CivitAI's site parses it on upload - people report mixed results across various metadata nodes, and this one is specifically the kind that's held up where others didn't, but it's not magic. Third, png is the safe choice if you care about metadata fidelity above all else; if you switch to jpeg or webp for smaller files, verify the embedded data actually round-trips the way you expect for your use case before relying on it for a batch of real uploads.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | Input images to save. | |
| filename_prefix | STRING | Path and filename. Use slashes to specify directories. | |
| add_timestamp | BOOLEAN | true | Sets the execution time's timestamp as a suffix of the file name. |
| embed_workflow | BOOLEAN | true | Whether to embed inside the images the current workflow or not. |
| extension | COMBO | png | Supported file formats. |
| quality | INT | 1001–100 | Quality of saved images in jpeg or webp format. |
| civitai_metadataopt | STRING | String containing CivitAI compatible metadata (created by the node LF_CivitAIMetadataSetup). | |
| ui_widgetopt | KUL_MASONRY | [object Object] | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| file_names | STRING | — |
| civitai_metadata | STRING | — |