Wan models on AI Gateway

Published: (February 19, 2026 at 08:00 AM EST)
3 min read

Source: Vercel Blog

Overview

Generate stylized videos and transform existing footage with Alibaba’s Wan models, now available through AI Gateway. Try them out now via AI SDK 6 or by selecting the models in the AI Gateway playground.

Wan produces artistic videos with smooth motion and can use existing content to keep videos consistent:

  • Character Reference (R2V) – Extract character appearance and voice from reference videos/images to generate new scenes
  • Flash Variants – Faster generation times for quick iterations
  • Flexible Resolutions – Support for 480p, 720p, and 1080p output

Two ways to get started

AI SDK 6

Generate videos programmatically with AI SDK 6’s generateVideo.

import { experimental_generateVideo as generateVideo } from 'ai';

const { videos } = await generateVideo({
  model: 'alibaba/wan-v2.6-t2v',
  prompt: 'Watercolor painting of a koi pond coming to life.',
});

Gateway Playground

Experiment with video models without code in the configurable AI Gateway playground embedded in each model page. Compare providers, tweak prompts, and download results. Access it by clicking any video‑gen model in the model list.

Available Models

ModelTypeDescription
alibaba/wan-v2.6-t2vText‑to‑VideoGenerate videos from text prompts
alibaba/wan-v2.6-i2vImage‑to‑VideoAnimate still images
alibaba/wan-v2.6-i2v-flashImage‑to‑VideoFast image animation
alibaba/wan-v2.6-r2vReference‑to‑VideoCharacter transfer from references
alibaba/wan-v2.6-r2v-flashReference‑to‑VideoFast style transfer
alibaba/wan-v2.5-t2v-previewText‑to‑VideoPrevious version

Simple: Text‑to‑Video with Audio

Generate a stylized video from a text description. The example uses alibaba/wan-v2.6-t2v.

import { experimental_generateVideo as generateVideo } from 'ai';

const { videos } = await generateVideo({
  model: 'alibaba/wan-v2.6-t2v',
  prompt: `Animated rainy Tokyo street at night, anime style,
    neon signs reflecting on wet pavement, people with umbrellas
    walking past, red and blue lights glowing through the rain.`,
  resolution: '1280x720',
  duration: 5,
});

Advanced: Reference‑to‑Video

Generate new scenes using characters extracted from reference images or videos. In this example, two reference images of dogs are used.

Reference example

Wan suggests using character1, character2, etc., in the prompt for multi‑reference to video to achieve the best results.

import { experimental_generateVideo as generateVideo } from 'ai';

const { videos } = await generateVideo({
  model: 'alibaba/wan-v2.6-r2v-flash',
  prompt: `character1 and character2 are playing together on the beach in San Francisco
    with the Golden Gate Bridge in the background, sunny day, waves crashing`,
  resolution: '1280x720',
  duration: 5,
  providerOptions: {
    alibaba: {
      referenceUrls: [shibaImage, yorkieImage],
    },
  },
});

Learn More

For more examples and detailed configuration options for Wan models, see the Video Generation Documentation. You can also find simple getting‑started scripts in the Video Generation Quick Start.

0 views
Back to Blog

Related posts

Read more »

Grok Imagine Video on AI Gateway

Generate high-quality videos with natural motion and audio using xAI's Grok Imagine Video, now in AI Gateway. Try it out via the v0 Grok Creative Studiohttps://...

Kling video models on AI Gateway

Overview Kling video models are now available in AI Gateway, including the newest Kling 3.0 models. These state‑of‑the‑art models can generate cinematic videos...