Kling 4.0 Image to Video API

klingai/video-v4-image-to-video
Kling 4.0 image-to-video animates a first frame, optionally toward a last frame, into 3–30 second videos at 720p or 1080p.
Output
$0.157 / sec (variable)
Released
Oct 15, 2026

Overview

What is Kling 4.0 Image to Video API?

Kling 4.0 image-to-video animates a first frame, optionally toward a last frame, into 3–30 second videos at 720p or 1080p. It is part of Kling AI's new-generation Kling 4.0 video model family and is available on AI/ML API through the video generation endpoint.

Technical specifications

  • Supported inputs: first-frame image, optional last frame, optional text prompt
  • Output: video, 3–30 seconds
  • Resolution: 720p or 1080p; aspect ratio follows the input frames
  • Model ID: klingai/video-v4-image-to-video
  • Release date: October 15, 2026

Kling 4.0 Image to Video API pricing

  • 720p: $0.157 / sec
  • 1080p: $0.235 / sec

Where to use Kling 4.0 Image to Video

Product and e-commerce visuals
Bring product photos to life for listings, ads and launch pages.

Scene transitions
Set a first and last frame and let the model animate the transition between them.

Character and portrait animation
Animate illustrations, portraits or concept art into motion video.

Use cases

Kling 4.0 Image to Video turns a still image into a 3–30 second clip, suited to product shots, portraits and concept art.

Setting both a first and a last frame gives control over where the shot starts and ends, which fits scene transitions and before/after reveals.

An optional prompt directs camera movement and action within the frame.

The output keeps the aspect ratio of the input frames, so vertical and horizontal formats work without cropping.

How to use Kling 4.0 Image to Video API

Install any OpenAI-compatible SDK, point it at api.aimlapi.com/v1, and set the model to klingai/video-v4-image-to-video.
import requests, time

headers = {"Authorization": "Bearer " + AIMLAPI_KEY}
job = requests.post(
    "https://api.aimlapi.com/v2/video/generations",
    headers=headers,
    json={
      "model": "klingai/video-v4-image-to-video",
      "prompt": "The camera slowly pushes in as the scene comes to life",
      "image_url": "https://example.com/first-frame.jpg",
      "duration": 5
    },
).json()
gid = job["id"]

while True:
    res = requests.get(f"https://api.aimlapi.com/v2/video/generations?generation_id={gid}", headers=headers).json()
    if res.get("status") in ("completed", "error"):
        break
    time.sleep(15)
print(res["video"]["url"])
const headers = {
  Authorization: `Bearer ${process.env.AIMLAPI_KEY}`,
  "Content-Type": "application/json",
};
const job = await (await fetch("https://api.aimlapi.com/v2/video/generations", {
  method: "POST",
  headers,
  body: JSON.stringify({
    "model": "klingai/video-v4-image-to-video",
    "prompt": "The camera slowly pushes in as the scene comes to life",
    "image_url": "https://example.com/first-frame.jpg",
    "duration": 5
  }),
})).json();

let res;
do {
  await new Promise((r) => setTimeout(r, 15000));
  res = await (await fetch(`https://api.aimlapi.com/v2/video/generations?generation_id=${job.id}`, { headers })).json();
} while (!["completed", "error"].includes(res.status));
console.log(res.video.url);
# submit the generation — the response contains the job "id"
curl -X POST https://api.aimlapi.com/v2/video/generations \
  -H "Authorization: Bearer $AIMLAPI_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "klingai/video-v4-image-to-video", "prompt": "The camera slowly pushes in as the scene comes to life", "image_url": "https://example.com/first-frame.jpg", "duration": 5}'

# then poll until status is "completed" — video.url holds the result
curl "https://api.aimlapi.com/v2/video/generations?generation_id={id}" -H "Authorization: Bearer $AIMLAPI_KEY"

OpenAI-compatible — swap the base URL and it works with your existing SDK.

Kling 4.0 Image to Video API Pricing

TypePrice
Output
$0.157 / sec (variable)

Billed per second of video: 720p — $0.157 / sec, 1080p — $0.235 / sec. Clips from 3 to 30 seconds.

Kling 4.0 Image to Video vs other models

ModelInputOutputContextBest for
$0.157 / sec (variable)
Video generation
$0.2 / sec (variable)
Video generation
$1.95 / 1M tokens
$0.10136 / sec
Video generation
$0.0711 / sec
Cinematic video + native audio

Frequently asked questions

Kling 4.0 Image to Video animates a first frame, optionally toward a last frame, into a 3–30 second video at 720p or 1080p.

It takes a first-frame image (image_url), an optional last frame (tail_image_url) and an optional text prompt, and returns a video. The output aspect ratio follows the input frames.

Clips can be 3 to 30 seconds long at 720p or 1080p. Input images can be up to 30MB, at least 300px per side, with an aspect ratio between 0.4 and 2.5.

Kling 4.0 Image to Video is billed per second of generated video: $0.157 per second at 720p and $0.235 per second at 1080p.

Yes. Pass the first frame as image_url and the last frame as tail_image_url, and the model animates the transition between them.

Submit a POST request to https://api.aimlapi.com/v2/video/generations with the model ID klingai/video-v4-image-to-video and an image_url, then poll with the returned generation_id until the status is completed.

Start building with Kling 4.0 Image to Video

Get API Key
1000+ models, one API.