Nodes for loading and saving images with metadata in ComfyUI.
Version: 1.0.1
Author: Light-x02
If you find this project useful, you can support my work on Ko-fi:
https://ko-fi.com/light_x02
This project provides two complementary nodes for ComfyUI, allowing you to load and save images while preserving their metadata intact. These nodes are particularly useful for workflows that require image adjustments, such as upscaling, without altering the original metadata.
The Image Metadata Loader node imports an image while extracting its original metadata, which can then be passed to other nodes.
The Image Metadata Saver node saves an image with its original, unchanged metadata embedded directly in the generated PNG file.
By connecting these two nodes through the METADATA
output/input, you can import a previously generated image with correct metadata, modify it (e.g., using upscaling), and save it while preserving the metadata intact.
git clone https://github.com/Light-x02/ComfyUI-Image-Metadata-Nodes.git
Download or Clone the Project
https://github.com/Light-x02/ComfyUI-Image-Metadata-Nodes
Move the Folder to Your ComfyUI Directory
Copy the folder ComfyUI_Image_Metadata
into the custom_nodes
directory of your ComfyUI installation.
Restart ComfyUI
Once the files are in place, restart ComfyUI to load the nodes.
IMAGE
: The loaded image.METADATA
: The raw metadata.IMAGE
: The image to save.METADATA
: The metadata to include.%date:yyyy-MM-dd%
).METADATA
output of the loader to the METADATA
input of the saver.To save metadata in my PNG files when generating images with txt2img workflows, I use the extension "ComfyUI-ImageMetadataExtension", which is available here. This ensures that platforms like Civitai automatically detect the metadata.
Contributions are welcome! If you want to report a bug or suggest an improvement, open an issue or submit a pull request on the GitHub repository.