A1111 Metadata Writer
The A1111 Metadata Writer doesn't call any A1111 — it just makes your images readable by the whole ecosystem
- image
- parameters
- path
Here's the situation this node solves. You generate in ComfyUI, which embeds your whole workflow as a JSON blob in the PNG. Then you upload that image to Civitai, or drag it into a tool that grew up in the A1111 era, and the info pane shrugs: it's looking for a parameters field - that classic one-liner with the prompt, Negative prompt:, Steps:, Sampler:, CFG scale:, Seed: - and ComfyUI never wrote one. A1111 Metadata Writer is a save node that writes exactly that field into your output images, so the rest of the world can read what you made and how.
The name is a bit of a lie in the good direction: it doesn't talk to an A1111 server and needs no API key. It reproduces the metadata format, which is what matters.
How it works
ComfyUI always hands every node a hidden prompt input containing the workflow graph. This node walks it to find the KSampler, pulls out the positive and negative prompt strings, steps, sampler name, CFG, seed, latent size, model, scheduler, denoise, and hashes, then appends any LoRA tags from sibling nodes like Load LoRAs With Tags and assembles an A1111-style parameters string. It maps ComfyUI sampler names to A1111 spellings (dpmpp_2m → DPM++ 2M, euler_a → Euler a), which is exactly the kind of detail people get wrong by hand.
Then it saves the image to the output directory with the metadata embedded:
- PNG - writes
parametersplus the workflowpromptand anyextra_pnginfoas PNG text chunks (ComfyUI-style viewers still work, A1111-style viewers now work too). - WebP - writes only
parametersinto the EXIFUserComment, the spot A1111-style tools read for WebP.
It's an output node, so it runs even if you leave its outputs unconnected.
Inputs and outputs that matter
image- the image to save.format-png/webptoggle (defaultpng). Decides both the extension and where the metadata goes.overwrite- when on, it finds theSaveImagenode's filename prefix in your workflow and overwrites the latest matching file instead of creating a new one. When off (default), it writes a fresh file.suffix- used whenoverwriteis off. Default_a1111gives files likeComfyUI_a1111_00001_.png.
Outputs are parameters (the exact string it built - handy for checking what's about to be embedded) and path (the full saved file path).
Install
Search craftgear in ComfyUI Manager and install a numbered version (the README's nightly choice fails on security restrictions), or:
cd ComfyUI/custom_nodes
git clone https://github.com/craftgear/comfyui-craftgear-nodes
Restart ComfyUI. No model files, no extra pip dependencies.
Where people get burned
- Nothing saved, empty outputs. If the workflow has no KSampler, or
promptparsing fails, the node returns empty strings and writes no file. The classic cause: a workflow that skips KSampler and decodes from a latent it loaded directly. There has to be a KSampler in the graph for it to build parameters from. - Don't expect round-trips on WebP. WebP output carries only
parameters, not the workflow JSON, so you can't drag a.webpback into ComfyUI and reconstruct the graph. That's the cost of A1111 compatibility. If you want both, save PNG. overwritefeels like it does nothing. It only overwrites the latest file that matches the current format extension and the SaveImage prefix - if yourformattoggle doesn't match what you originally saved, it creates a new file instead.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | — | |
| overwrite | BOOLEAN | false | — |
| suffix | STRING | _a1111 | — |
| format | COMBO | png | 2 options: png, webp |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| parameters | STRING | — |
| path | STRING | — |