Skip to content
Dashboard

Veo 3.0 Fast Generate

Veo 3.0 Fast Generate is Google's rapid-iteration video generation model, the fast tier of Veo 3.0, built for high-velocity prompt exploration, batch generation, and concept validation before committing to full-quality renders. Your use is subject to Google's Terms & Privacy Policies.

Video Gen
import { experimental_generateVideo as generateVideo } from 'ai';
const result = await generateVideo({
model: 'google/veo-3.0-fast-generate-001',
prompt: 'A serene mountain lake at sunrise.'
});
Read docs

Getting started

Generate videos with Veo 3.0 Fast Generate using the experimental_generateVideo function from AI SDK 6 or later. AI Gateway handles routing and polls until the video is ready.

Install the AI SDK (pnpm add ai dotenv), create an API key from the API Keys page, and set it as AI_GATEWAY_API_KEY in your environment. Full setup is covered in the video generation quickstart.

index.ts
import { experimental_generateVideo as generateVideo } from 'ai';
import fs from 'node:fs';
import 'dotenv/config';
async function main() {
const result = await generateVideo({
model: 'google/veo-3.0-fast-generate-001',
prompt:
'A pangolin curled on a mossy stone in a glowing bioluminescent forest',
});
// Save the generated video
fs.writeFileSync('output.mp4', result.videos[0].uint8Array);
console.log('Video saved to output.mp4');
}
main().catch(console.error);

Top-level parameters

Load the supported top-level parameters: prompt, aspectRatio, duration, and resolution.

top-level-params.ts
import { experimental_generateVideo as generateVideo } from 'ai';
import fs from 'node:fs';
import 'dotenv/config';
async function main() {
const result = await generateVideo({
model: 'google/veo-3.0-fast-generate-001',
prompt:
'A pangolin curled on a mossy stone in a glowing bioluminescent forest',
aspectRatio: '16:9',
duration: 6,
resolution: '720p',
});
// Save the generated video
fs.writeFileSync('output.mp4', result.videos[0].uint8Array);
console.log('Video saved to output.mp4');
}
main().catch(console.error);
ParameterTypeRequiredDescription
promptstringNoText description of the video to generate.
duration4 | 6 | 8NoVideo length in seconds. 4 or 6 or 8 seconds.
resolutionstringNoResolution ('1280x720', '1920x1080').
aspectRatiostringNoAspect ratio ('16:9', '9:16').
generateAudiobooleanNoGenerate synchronized audio with the video.
frameImagesArray<{ image: string; frameType: 'first_frame' }>NoOpening frame of the clip, as a single first_frame entry. Replaces prompt.image and wins when both are set.

Input limits

InputFormatsSourcesMax countMax sizeLimits
Imagejpg, jpeg, pngurl, base64120 MB

Provider options

Pass Veo-specific options under providerOptions.vertex. This call loads every text-to-video option that combines in a single request.

provider-options.ts
import { experimental_generateVideo as generateVideo } from 'ai';
import fs from 'node:fs';
import 'dotenv/config';
async function main() {
const result = await generateVideo({
model: 'google/veo-3.0-fast-generate-001',
prompt:
'A pangolin curled on a mossy stone in a glowing bioluminescent forest',
duration: 8,
resolution: '1080p',
providerOptions: {
vertex: {
enhancePrompt: true,
negativePrompt: 'blurry, low quality, distorted',
personGeneration: 'allow_adult',
compressionQuality: 'optimized',
sampleCount: 1,
seed: 42,
pollIntervalMs: 5000,
pollTimeoutMs: 600000,
},
},
});
// Save the generated video
fs.writeFileSync('output.mp4', result.videos[0].uint8Array);
console.log('Video saved to output.mp4');
}
main().catch(console.error);

Pass Veo-specific options under providerOptions.vertex in your generateVideo call. Veo 3.0 Fast always generates audio.

ParameterTypeRequiredDescription
enhancePromptbooleanNoUse Gemini to enhance prompts. Defaults to true.
negativePromptstringNoWhat to discourage in the generated video.
personGeneration'dont_allow' | 'allow_adult' | 'allow_all'NoWhether to allow person generation. Text-to-video: 'allow_all' only. Image-to-video: 'allow_adult' only.
compressionQuality'optimized' | 'lossless'NoCompression quality. Defaults to 'optimized'.
sampleCount1NoNumber of output videos. Fixed at 1.
seednumberNoSeed for deterministic generation (0-4,294,967,295).
gcsOutputDirectorystringNoCloud Storage URI to store the generated videos.
referenceImagesarrayNoReference images for style or asset guidance. Legacy alternative to the top-level inputReferences, used only when inputReferences is omitted.
resizeMode'pad' | 'crop'NoImage-to-video only: how to resize the input image to fit video dimensions. Defaults to 'pad'.
pollIntervalMsnumberNoHow often to check task status. Defaults to 5000.
pollTimeoutMsnumberNoMaximum wait time. Defaults to 600000 (10 minutes).

Duration constraints

Veo 3.0 Fast supports duration values of 4, 6, or 8 seconds.

duration must be 8 when using 1080p or 4K resolution, providerOptions.vertex.referenceImages, or video extension.

Image to video

Animate a starting image by passing prompt as an object with image and an optional text field.

image-to-video.ts
import { experimental_generateVideo as generateVideo } from 'ai';
import fs from 'node:fs';
import 'dotenv/config';
async function main() {
const result = await generateVideo({
model: 'google/veo-3.0-fast-generate-001',
prompt: {
image: 'https://example.com/landscape.png',
text: 'Camera slowly pans across the scene as clouds drift by',
},
duration: 8,
resolution: '1080p',
generateAudio: true,
providerOptions: {
vertex: {
resizeMode: 'crop',
},
},
});
// Save the generated video
fs.writeFileSync('output.mp4', result.videos[0].uint8Array);
console.log('Video saved to output.mp4');
}
main().catch(console.error);