Image Upscale: Wan 2.2 Two-Stage - After
Image Upscale: Wan 2.2 Two-Stage - Before

This two-stage ComfyUI workflow turns a low- or mid-resolution image into a high-fidelity result using the Wan2.2 diffusion model in controlled image-to-image mode. After you LoadImage, GeminiNodeV3 analyzes the picture and generates a concise descriptive prompt that conditions Wan2.2 during upscaling. The pipeline then runs in two passes inside the Image Controlled Upscale group: a coarse first pass to establish structure at a larger size, followed by a fine second pass to restore and enhance details while keeping the original look.

Stage 1 and Stage 2 are implemented with the custom upscaler nodes (8c62a455-6744-43c8-9352-543905ed4db7 and 058e194e-5740-4f04-a9ca-7c741daecfcc), which accept your resize factor, denoise strength, and sampler steps. Author notes provide practical ranges: use 0.20–0.40 denoise for a more creative, coarse pass and 0.10–0.20 for detail-preserving refinement; 25 steps for quick results, or 50+ for maximum quality. PreviewAny gives you live feedback, ImageCompare shows side-by-side before/after in the Image Compare group, and SaveImage exports the final output. A MarkdownNote inside the workflow summarizes the guidance so you can quickly dial in the right settings for different images.

This iterative approach is especially effective for AI-generated images or stylized art that benefit from prompt-guided reconstruction. By pairing auto-prompting (GeminiNodeV3) with Wan2.2’s image-to-image strengths, the workflow preserves identity while recovering edges, textures, and fine details that simple pixel upscalers can miss.

API

Use this workflow from code

Every Comfy workflow is a JSON graph. The payload below is this workflow, exactly as ComfyUI runs it — fetch it from the URL, keep it in version control, or load it in ComfyUI and run it node by node.

aa0ea76f6bcd.json
Fetching workflow JSON…

Run it from TypeScript or Python with the Comfy SDK. The same code targets Comfy Cloud or a ComfyUI you host yourself — only the base URL changes.

// Install (beta)
npm i @comfyorg/sdk

// Run this workflow (TypeScript)
import { Comfy } from "@comfyorg/sdk";

const client = new Comfy({ apiKey: "comfyui-..." });
const wf = await client.workflows.fromFile("workflow_api.json");
const job = await client.run(wf);
await job.getOutputs("<output-node-id>")[0].toFile("output.png");

The SDK takes a workflow in API format: open this workflow in ComfyUI and use File → Export Workflow (API).

Comfy Cloud API access requires a plan with an API key.

FAQ

Frequently Asked Questions

View all workflows
Showing 30 of 30 templates