
Wan2.1 VACE Reference to Video turns a single image into a short video that preserves your reference’s style and subject while introducing motion guided by text prompts. The core of the workflow is the WanVaceToVideo node, which fuses a loaded reference image (LoadImage) with prompt text encoded by CLIPTextEncode. The diffusion backbone is provided by the Wan 2.1 VACE models—use UNETLoader and VAELoader in the “Load models here” group to select either Wan2.1-VACE-1.3B or Wan2.1-VACE-14B. A ModelSamplingSD3 node configures the sampler, and KSampler handles denoising with your chosen steps and cfg scale. If you need stylistic adapters, LoraLoader lets you apply a matching LoRA to the same diffusion model family.
After sampling, VAEDecode reconstructs frames from latents. TrimVideoLatent helps you set exact duration, and the “First Frame control” group (ImageToMask, SolidMask, MaskToImage, RepeatImageBatch) can lock or protect parts of the initial frame for stronger identity or composition retention. PreviewImage nodes allow quick QC during iteration. Finally, CreateVideo aggregates frames and you can export via SaveVideo (MP4) or SaveAnimatedWEBP for lightweight previews. Author guidance: default steps=20 and cfg=6.0 work well; with CausVid LoRA use fewer steps (2–4) and a low cfg (~1.0). For resolution, VACE-1.3B is suited to 480p, while VACE-14B delivers higher quality and supports 480p and 720p at the cost of longer render time.
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.
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 "Wan2.1 VACE Reference to Video" (TypeScript)
import { Comfy } from "@comfyorg/sdk";
const client = new Comfy({ apiKey: "comfyui-..." });
// This workflow, exported in API format (see note below)
const wf = await client.workflows.fromFile("video_wan_vace_14B_ref2v_api.json");
const asset = client.assets.fromFile("input.png");
wf.setInput("73", "image", asset); // LoadImage
wf.setInput("105", "text", "your prompt here"); // CLIPTextEncode
const job = await client.run(wf);
await job.getOutputs("70")[0].toFile("output.png"); // SaveAnimatedWEBPThe 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













