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

# Kling 4.0 Image to Video - ComfyUI Built-in Node Documentation

> Generates a video from a set of keyframes with the Kling 4.0 model, including audio.

Generates a video from a set of keyframes with the Kling 4.0 model, including audio. The first frame, up to eight middle frames, and the last frame are sent in order, the middle frames are spaced evenly across the clip, and the output takes the aspect ratio of the first keyframe. Use it to animate one image or to steer a shot through a sequence of key moments.

## Inputs

### Common Inputs

| Parameter | Description | Data Type | Required | Range |
| - | - | - | - | - |
| `model` | Model selector. Only `"kling-4.0"` is available; selecting it reveals the inputs below. | DYNAMIC\_COMBO | Yes | `"kling-4.0"` |

### kling-4.0 Inputs

These inputs appear when `model` is set to `"kling-4.0"`. At least one of the frame inputs must be connected.

| Parameter | Description | Data Type | Required | Range |
| - | - | - | - | - |
| `first_frame` | Optional frame the video starts on. | IMAGE | No | - |
| `middle_frames` | Optional growable slots for frames between the first and the last one, up to 8. They are spaced evenly through the clip. | AUTOGROW | No | 0 to 8 images |
| `last_frame` | Optional frame the video ends on. | IMAGE | No | - |
| `prompt` | Optional description of the motion. Refer to the connected frames as `@Image1`, `@Image2` and so on, in the order first frame, middle frames, last frame. Default: empty string. | STRING | Yes | Multiline text |
| `resolution` | Resolution of the output video. Default: `"720p"`. | COMBO | Yes | `"720p"` `"1080p"` |
| `duration` | Length of the generated video in seconds. Default: 5. | INT | Yes | 3 to 30 |
| `seed` | Seed controls whether the node should re-run; results are non-deterministic regardless of seed. Default: 42. | INT | Yes | 0 to 2147483647 |

**Constraints and behavior:**

* At most 10 frames can be connected in total, counting the first frame, every middle frame and the last frame.
* The video takes the aspect ratio of the first keyframe, so no aspect ratio input is needed.
* Every frame must be at least 300x300 pixels with an aspect ratio between 2:5 and 5:2.
* A prompt that mentions `@ImageN` raises an error when fewer than N frames are connected.

## Outputs

| Output Name | Description | Data Type |
| - | - | - |
| `video` | The generated video, downloaded from the provider once the task completes. | VIDEO |

> 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/Kling4ImageToVideoNode/en.md)

***

**Source fingerprint (SHA-256):** `762c350abd4a881b96355a7ce5b9e346d5c3ff22e9f11db820584d02aee12885`


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.