> ## Documentation Index
> Fetch the complete documentation index at: https://dripart-comfy-docs-comfyapi-search.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# WanImageToVideo - ComfyUI Built-in Node Documentation

> The WanImageToVideo node prepares conditioning and latent representations for video generation.

The WanImageToVideo node prepares conditioning and latent representations for video generation. It creates an empty latent space for the video and can optionally incorporate a starting image and CLIP vision output to guide the generation. Both the positive and negative conditioning inputs are updated with the provided image and vision data.

## Inputs

| Parameter            | Description                                                                                                                                                                                                                                                                         | Data Type            | Required | Range                 |
| -------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------- | -------- | --------------------- |
| `positive`           | Positive conditioning input used to guide the generation                                                                                                                                                                                                                            | CONDITIONING         | Yes      | -                     |
| `negative`           | Negative conditioning input used to guide the generation                                                                                                                                                                                                                            | CONDITIONING         | Yes      | -                     |
| `vae`                | VAE model used to encode images into latent space                                                                                                                                                                                                                                   | VAE                  | Yes      | -                     |
| `width`              | Width of the generated video (default: 832, step: 16)                                                                                                                                                                                                                               | INT                  | Yes      | 16 to MAX\_RESOLUTION |
| `height`             | Height of the generated video (default: 480, step: 16)                                                                                                                                                                                                                              | INT                  | Yes      | 16 to MAX\_RESOLUTION |
| `length`             | Number of frames in the video (default: 81, step: 4)                                                                                                                                                                                                                                | INT                  | Yes      | 1 to MAX\_RESOLUTION  |
| `batch_size`         | Number of videos to generate in one batch (default: 1)                                                                                                                                                                                                                              | INT                  | Yes      | 1 to 4096             |
| `clip_vision_output` | Optional CLIP vision output added as extra conditioning to both the positive and negative inputs                                                                                                                                                                                    | CLIP\_VISION\_OUTPUT | No       | -                     |
| `start_image`        | Optional starting image used to initialize the video. When provided, it is resized to the specified `width` and `height` and placed at the beginning of the frame sequence; any frames beyond `length` are ignored. The remaining frames are filled with neutral gray (0.5) values. | IMAGE                | No       | -                     |

**Note:** When `start_image` is provided, the frame sequence is encoded with the VAE and a mask is applied to the conditioning. The mask is set to 0 for the frames covered by the starting image and 1 for the remaining frames, so generation continues from the provided image. Only the first three color channels (RGB) of the image are used during encoding. Both positive and negative conditioning receive the same concatenated latent image, mask, and (if supplied) CLIP vision output.

## Outputs

| Output Name | Description                                                                                                           | Data Type    |
| ----------- | --------------------------------------------------------------------------------------------------------------------- | ------------ |
| `positive`  | Positive conditioning, updated with the image and vision data                                                         | CONDITIONING |
| `negative`  | Negative conditioning, updated with the image and vision data                                                         | CONDITIONING |
| `latent`    | Empty latent tensor ready for video generation, with shape \[batch\_size, 16, ((length-1)//4)+1, height//8, width//8] | LATENT       |

> This documentation was AI-generated. If you find any errors or have suggestions for improvement, please feel free to contribute! [Edit on GitHub](https://github.com/Comfy-Org/embedded-docs/blob/main/comfyui_embedded_docs/docs/WanImageToVideo/en.md)

***

**Source fingerprint (SHA-256):** `46779f9f2f3da16826b7b547761a96597a3b6b43ce51a9c13367987642f3d5b7`
