Coding

Vercel AI SDK

The Vercel AI SDK is a free, open-source TypeScript toolkit for building AI apps and agents with a unified API across model providers and UI hooks for chat.

Visit website

About this tool

The AI SDK, created by Vercel, the company behind Next.js, is an open-source TypeScript library for building AI-powered applications. Its core idea is a single API for many model providers: switching from one provider to another usually means changing one line. It handles streaming responses, structured objects, tool calls and agent loops, so developers avoid writing provider-specific parsing code.

AI SDK UI adds framework-agnostic hooks for chat and generative interfaces in React, Next.js, Vue, Svelte and other frameworks. By default it can route requests through Vercel’s AI Gateway to reach major providers with one key, or connect to providers directly through their packages. A newer harness abstraction runs established coding agents such as Claude Code and Codex through a uniform interface.

What you can do

Unified provider API

Generate text, objects and tool calls across OpenAI, Anthropic, Google and others with one interface.

Streaming and fallbacks

Real-time streaming and built-in fallbacks make production behaviour more resilient.

UI hooks

Ready-made hooks build chat and generative interfaces in React, Vue, Svelte and more.

Agent harnesses

HarnessAgent runs existing agent harnesses like Claude Code or Codex through a consistent API.

Who is it for?

  • A Next.js developer adds a streaming chat assistant to a web app in an afternoon.
  • A team switches its summarisation feature to a cheaper model by changing one line.
  • A startup builds an agent that calls internal tools and renders results in the UI.

Before you choose

The SDK is free, but model calls are billed by the providers or the AI Gateway you use.

It is a TypeScript library that requires Node.js 22 or later, so it suits JavaScript stacks rather than Python ones.

Frequently asked questions

Is the AI SDK free?

Yes. The library costs nothing and its code is open source. You only pay for the model providers or gateway you call through it.

Do I have to deploy on Vercel to use the AI SDK?

No. It is a general TypeScript library that works with Node.js and popular frameworks, wherever you host them.

Which model providers does it support?

It supports many providers, including OpenAI, Anthropic and Google, either directly through provider packages or via Vercel AI Gateway.

Check the official website for current features, pricing, and terms.

toolnorthAI.
WritingImage & DesignVideoCodingProductivityMarketingAudioResearchAutomationBusinessEducationAI CompanionsAdult AIOther