Skip to content
Dashboard

Grok Imagine Video 1.5

Grok Imagine Video 1.5 is SpaceXAI's image-to-video generation model. It animates a starting image and generates synchronized audio in a single pass, available through Vercel AI Gateway. Your use is subject to SpaceXAI's Terms & Privacy Policies.

View API reference
Price
$0.08, Per second
Lowest available configuration
import { experimental_generateVideo as generateVideo } from 'ai';
const result = await generateVideo({
model: 'spacexai/grok-imagine-video-1.5',
prompt: 'A serene mountain lake at sunrise.'
});
Read docs

Copy link to headingPlayground

Try out Grok Imagine Video 1.5 by SpaceXAI. Usage is billed to your team at API rates. Free users (those who haven't made a payment) get $5 of credits every 30 days.

spacexai logo
Images
Add up to 7 images
Prompt

Duration8s
1s15s
Resolution
Aspect ratio
Videos to generate
spacexai logo

Your generated video will appear here.

Copy link to headingProviders

Route requests across multiple providers. Copy a provider slug to set your preference. Visit the docs for more info. Using a provider means you agree to their terms, listed under Legal.

Checking availability for your team
Provider
Input
Output
Capabilities
ZDR
No Training
Free AI Gateway Credit
Release Date
$0.01/img
$0.08/sec+2 more
06/22/2026

Getting started

Generate videos with Grok Imagine Video 1.5 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: 'spacexai/grok-imagine-video-1.5',
prompt: {
image: 'https://example.com/cat.png',
text: 'The cat slowly turns its head and blinks',
},
});
// 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.image, prompt.text, duration, and aspectRatio.

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: 'spacexai/grok-imagine-video-1.5',
prompt: {
image: 'https://example.com/cat.png',
text: 'The cat slowly turns its head and blinks',
},
duration: 5,
aspectRatio: '16:9',
});
// 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.
durationnumberNoVideo length in seconds. 1-15 seconds.
resolutionstringNoResolution ('854x480', '1280x720', '1920x1080').
aspectRatiostringNoAspect ratio ('1:1', '16:9', '9:16', '4:3', '3:4', '3:2', '2:3').
frameImagesArray<{ image: string | Buffer; frameType: 'first_frame' }>NoOpening frame of the clip, as a single first_frame entry. Replaces prompt.image and wins when both are set. Grok does not interpolate to an ending image, so a last_frame entry is ignored with a warning.
inputReferencesArray<string | Buffer>NoOne to seven reference images that Grok builds a new scene from rather than animating. Passing them selects reference-to-video mode automatically. Images only — a video reference is ignored with a warning, so use mode: 'extend-video' to continue from a video.

Input limits

InputFormatsSourcesMax countMax sizeLimits
Image—url, base647——
Audio—url———

Provider options

Pass every Grok image-to-video option under providerOptions.xai.

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: 'spacexai/grok-imagine-video-1.5',
prompt: {
image: 'https://example.com/cat.png',
text: 'The cat slowly turns its head and blinks',
},
duration: 5,
providerOptions: {
xai: {
resolution: '720p',
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 Grok-specific options under providerOptions.xai in your generateVideo call.

ParameterTypeRequiredDescription
referenceImageUrlsstring[]NoOne to seven reference image URLs for reference-to-video, which generates a new scene from the references rather than animating them. Legacy alternative to the top-level inputReferences, used only when inputReferences is omitted.
resolution'480p' | '720p'NoVideo resolution. Defaults to 480p.
pollIntervalMsnumberNoHow often to check task status. Defaults to 5000.
pollTimeoutMsnumberNoMaximum wait time. Defaults to 600000 (10 minutes).

Mode selection and frames

Editing, extension, and reference-to-video are mutually exclusive. Passing providerOptions.xai.videoUrl selects editing, and passing inputReferences selects reference-to-video; set providerOptions.xai.mode to choose explicitly.

The top-level parameters win over their provider-option equivalents: a first_frame in frameImages overrides prompt.image, and inputReferences overrides providerOptions.xai.referenceImageUrls.

Grok does not interpolate between a first and last frame. A last_frame entry in frameImages is ignored with a warning — use mode: 'extend-video' to continue from the end of an existing clip instead.

frameImages takes priority over references: when it is set, reference-to-video is not auto-selected.

Image to video

Animate a static image by passing prompt.image (a URL) with an optional prompt.text describing the motion. The output defaults to the input image’s aspect ratio; setting aspectRatio overrides it and stretches the image.

grok-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: 'spacexai/grok-imagine-video-1.5',
prompt: {
image: 'https://example.com/cat.png',
text: 'The cat slowly turns its head and blinks',
},
duration: 5,
providerOptions: {
xai: {
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);

Reference to video

Generate a new scene from reference images passed through the top-level inputReferences. The references guide visual elements in the output rather than becoming the first frame, and passing them selects reference-to-video mode automatically. Refer to each one in the prompt with <IMAGE_1>, <IMAGE_2>, and so on.

reference-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: 'spacexai/grok-imagine-video-1.5',
prompt:
'The comic cat from <IMAGE_1> and the comic dog from <IMAGE_2> ' +
'are having a playful chase through a sunlit park. ' +
'Cinematic slow-motion, warm afternoon light.',
inputReferences: [
'https://example.com/comic-cat.png',
'https://example.com/comic-dog.png',
],
duration: 8,
aspectRatio: '16:9',
providerOptions: {
xai: {
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);

Copy link to headingMore models by SpaceXAI

Model
Context
Latency
Throughput
Input
Output
Cache
Search
Capabilities
Providers
ZDR
No Training
Free AI Gateway Credit
Release Date
500K3.7 s102 tps
$2/M+1 more
$6/M+1 more
Read$0.50/M
$5/K+2 more
+2
xai logo
09/21/2026
500K2.8 s64 tps
$2/M+1 more
$6/M+1 more
Read$0.50/M
$5/K+2 more
+2
xai logo
08/12/2026
500K2.7 s63 tps
$2/M+1 more
$6/M+1 more
Read$0.30/M
$5/K+2 more
+4
xai logo
07/08/2026
256K1.2 s163 tps
$1/M+1 more
$2/M+1 more
Read$0.20/M
$5/K+2 more
+3
xai logo
05/20/2026
1M1.7 s109 tps
$1.25/M+1 more
$2.50/M+1 more
Read$0.20/M
$5/K+2 more
+4
vertex logo
xai logo
04/30/2026
1M0.4 s141 tps
$0.20/M
$0.50/M
Read$0.05/M
—
+2
vertex logo
11/19/2025

Copy link to headingAbout Grok Imagine Video 1.5

Grok Imagine Video 1.5 is SpaceXAI's image-to-video model, released June 22, 2026 and available through AI Gateway. You provide a starting image and describe the motion you want. Grok Imagine Video 1.5 animates the scene and generates synchronized audio, including sound effects, ambience, and speech, in the same pass. Compared with the earlier Grok Imagine Video model, the 1.5 generation improves audio quality, prompt following, and photorealism. Face accuracy and character consistency hold across longer sequences, with better lighting and physical realism. Expanded reference image support gives more control over visual style and subject. Grok Imagine Video 1.5 debuted at the top of crowd-sourced image-to-video arena rankings.

Integration runs through the AI SDK's generateVideo function, imported as experimental_generateVideo from AI SDK 6 or later. Pass a prompt object with an image and a text motion description. You control duration, aspect ratio, and resolution through parameters, with output available at 480p, 720p, and 1080p. Billing is per second of generated video, with rates by resolution shown on this page.

Grok Imagine Video 1.5 pairs well with grok-imagine-image: generate a still with generateImage, then animate that frame in the same flow. If you built against the preview, grok-imagine-video-1.5-preview remains in the catalog, and Grok Imagine Video 1.5 is the variant to target for production.

Copy link to headingWhat To Consider When Choosing a Provider

  • Configuration: Video generation through AI Gateway requires AI SDK 6 or later and uses experimental_generateVideo, an experimental API that may change between releases. Generation can take minutes for longer or higher-resolution clips. In Node.js, extend fetch timeouts so requests don't fail before the video finishes.
  • Configuration: Output is billed per second of generated video, and rates vary by resolution. Estimate clip length and resolution before scaling a workload, and iterate at lower resolutions before rendering final assets at 1080p.
  • Zero Data Retention: Zero Data Retention is offered on a per-provider and model basis. See the documentation for details.
  • Authentication: AI Gateway authenticates requests using an API key or OIDC token. You do not need to manage provider credentials directly.

Copy link to headingWhen to Use Grok Imagine Video 1.5

Best for

  • Animating Product and Brand Stills: Turn existing key art or product shots into short clips with motion and sound
  • Social and Marketing Video: Produce short-form clips with synchronized audio and no separate sound pass
  • Character-Driven Scenes: Face accuracy and character consistency hold across longer sequences
  • Image-First Creative Pipelines: Chain grok-imagine-image stills into video inside one AI SDK flow
  • Style-Controlled Generation: Reference image support steers visual style and subject

Consider alternatives when

  • Existing Preview Integrations: Workloads validated on grok-imagine-video-1.5-preview can stay pinned while you migrate
  • Text-Only Prompting: grok-imagine-video generates clips straight from text descriptions without a source image
  • Static Visuals: grok-imagine-image or grok-imagine-image-pro covers stills without video cost
  • Long-Form Production: Traditional editing tools give more control over extended content

Grok Imagine Video 1.5 is the production release of SpaceXAI's Imagine Video 1.5 line. You send a starting image and a motion prompt, and receive a finished clip with synchronized audio at up to 1080p. Wire Grok Imagine Video 1.5 up through the AI SDK's generateVideo function.

Copy link to headingFrequently Asked Questions

  • What inputs does Grok Imagine Video 1.5 take?

    Grok Imagine Video 1.5 is an image-to-video model. Pass a prompt object with an image and a text motion description to the AI SDK's generateVideo function. Expanded reference image support gives extra control over style and subject.

  • Does Grok Imagine Video 1.5 generate audio?

    Yes. Sound effects, ambience, and speech render in the same pass as the video, synchronized to the action.

  • What resolutions does Grok Imagine Video 1.5 support?

    Output is available at 480p, 720p, and 1080p. Billing is per second of generated video, with rates by resolution listed on this page.

  • How does Grok Imagine Video 1.5 differ from grok-imagine-video-1.5-preview?

    Grok Imagine Video 1.5 is the stable release of the Imagine Video 1.5 generation. The preview variant reached AI Gateway first and remains in the catalog; target the stable model for production work.

  • How do I integrate Grok Imagine Video 1.5 with the AI SDK?

    Use experimental_generateVideo from AI SDK 6 or later. Generation can take minutes, so extend fetch timeouts in Node.js and save the returned video bytes from result.videos.

  • How do I authenticate with Grok Imagine Video 1.5 through Vercel AI Gateway?

    Use your Vercel AI Gateway API key with spacexai/grok-imagine-video-1.5 as the model identifier.

  • Does Vercel AI Gateway support Zero Data Retention for Grok Imagine Video 1.5?

    Zero Data Retention is not currently available for this model. Zero Data Retention is offered on a per-provider basis. See https://vercel.com/docs/ai-gateway/capabilities/zdr for details.