Skip to content
Dashboard

Build your own AI app builder with the v0 Platform API

, Alli Pope

Learn how to build, extend, and automate AI-generated apps with programmatic access to v0โ€™s app generation pipeline

The v0 Platform API is a text-to-app API that gives developers direct access to the same infrastructure powering v0.dev.

Currently in beta, the platform API exposes a composable interface for developers to automate building web apps, integrate code generation into existing features, and build new products on top of LLM-generated UIs.

Copy link to headingWhat is the v0 Platform API?

The Platform API is a REST interface that wraps v0โ€™s full code generation lifecycle: prompt โ†’ project โ†’ code files โ†’ deployment. Every app built with the platform API is backed by a v0.dev chat link.

It includes endpoints for almost all functionality on v0.dev:

  • Natural language app generation: Generate full-stack web apps from natural language prompts and get back parsed code files and a live demo URL

  • Bring your own context: Start chats with your own files, from source code, git, or shadcn registry, or include attachments in individual messages

  • Projects and deployments: Create new Vercel projects, link Vercel projects to a chat, and trigger deploys

Copy link to headingHow to use the v0 Platform API

The v0 SDK is a TypeScript library that makes it simple to interact with the v0 Platform API.

pnpm install v0-sdk

Get your API key from your v0 account settings and set it as an environment variable:

.env
V0_API_KEY=your_api_key_here

Now, you can integrate v0's AI-powered code generation into your application. Learn more in our complete Quickstart Guide.

import { v0 } from "v0-sdk"
export default async function V0Chat() {
// No initialization needed - uses V0_API_KEY automatically
const chat = await v0.chats.create({
message: "Build a todo app with React and TypeScript"
})
// Access the generated files
chat.files?.forEach((file) => {
console.log(`File: ${file.name}`)
console.log(`Content: ${file.content}`)
})
// Use the Demo URL in an iframe
return (
<iframe
src={chat.demo}
width="100%"
height="600">
</iframe>
)
}

Copy link to headingWhat can you build with the Platform API?

The Platform API turns v0 into a headless app builder. Developers are already using it to power:

  • Website builders where users can describe a site and get production-ready code

  • Slack and Discord bots that return deployed web applications

  • VSCode plugins and CLIs that build around the prompt-to-app workflow

  • Embedded flows in analytics or CRM tools that generate UI components from natural language

  • Custom dev environments and agents that read user intent and return live apps with demo links

ok < 24 hrs later i got @v0 x @chatprd working locally โœ… generate a PRD โœ… send to v0 โœ… preview prototype in ChatPRD โœ… banger pop punk anthem + demo props to @vercel and @ctatedev who are delightfully responsive to SDK and docs questions

Guillermo Rauch
Guillermo Rauch
Vercel
@rauchg

Headless @v0 is here: ๐š’๐š–๐š™๐š˜๐š›๐š { ๐šŸ๐Ÿถ } ๐š๐š›๐š˜๐š– '๐šŸ๐Ÿถ-๐šœ๐š๐š”' ๐šŠ๐š ๐šŠ๐š’๐š ๐šŸ๐Ÿถ.๐šŒ๐š‘๐šŠ๐š๐šœ.๐šŒ๐š›๐šŽ๐šŠ๐š๐šŽ({ ๐š–๐šŽ๐šœ๐šœ๐šŠ๐š๐šŽ: '๐™ฑ๐šž๐š’๐š•๐š ๐š–๐šŽ ๐šŠ ๐š•๐šŠ๐š—๐š๐š’๐š—๐š ๐š™๐šŠ๐š๐šŽ', ๐šœ๐šข๐šœ๐š๐šŽ๐š–: '๐šˆ๐š˜๐šžโ€™๐š›๐šŽ ๐šŠ ๐š๐šŽ๐šŠ๐šŒ๐š ๐šŽ๐šก๐š™๐šŽ๐š›๐š' }) vercel.com/changelog/v0-pโ€ฆ

236
Reply
ChatPRD generates product requirements, then uses the v0 API to create a live prototype that teams can preview directly in the appโ€™s canvas.

Copy link to headingGet started

Check out the v0 Platform API template, a Next.js application demonstrating the v0 Platform API and features like project management, chat history, and real-time app generation with live previews.

Ready to deploy?