For the complete documentation index, see llms.txt. Prefer markdown by appending.mdto documentation URLs or sendingAccept: text/markdown.
Get started
Get started with AI Kit. Explore template apps, provider integrations, and the architecture behind the AI starter kit.
TurboStarter AI Kit provides ready-to-use AI templates for Next.js and Expo. Start with chat, RAG, images, or voice, then configure the providers your product needs.
Whether you're launching a small side project or a full-scale product, it gives you the structure you need to start building immediately.
Use the kit selector to explore Core Kit for a full SaaS foundation or Edge Kit for TanStack Start on Cloudflare. If you are comparing them, choose a kit walks through the requirements that decide it.
Features
AI Kit comes packed with features designed to accelerate your development process:
Core framework
Monorepo setup
Powered by Turborepo for efficient code sharing and dependency management across web and mobile applications.
Next.js web app
Built with Next.js and the App Router (RSC by default), plus an opinionated structure for AI templates.
Hono API
Fast, TypeScript-first API layer shared by the web and mobile apps.
React Native + Expo
Foundation for cross-platform mobile apps that share business logic with your web application.
AI
AI SDK
Complete toolkit for implementing advanced AI features like streaming responses and interactive chat interfaces.
LangChain
Utilities for building RAG workflows like document loading, chunking, and retrieval.
Multiple AI providers
Seamless integration with OpenAI, Anthropic, Google AI, xAI, DeepSeek, Replicate, Fireworks, Eleven Labs, and more through a unified strategy.
Specialized models
Full support for text generation, structured output, image generation, embeddings (RAG), transcription, and voice synthesis.
One-line model switching
Effortlessly switch between AI models or providers with minimal code changes.
LiveKit
Real-time audio, video, and data streaming capabilities for collaborative AI and communication features.
Data storage
Drizzle ORM
Type-safe ORM for efficient interaction with PostgreSQL (default) or other supported databases (MySQL, SQLite).
PostgreSQL database
Reliable storage for chat history, user data, and vector embeddings with optimized performance.
Vector embeddings
Built-in support for storing and retrieving vector embeddings for advanced retrieval-augmented generation.
Blob storage
Integrated S3-compatible storage for managing user uploads, AI-generated content, and documents.
Authentication
Better Auth integration
Secure authentication system starting with anonymous sessions, extensible to email/password, magic links, and OAuth providers.
Rate limiting
Intelligent protection for API endpoints against abuse and overuse.
Credits-based access
Flexible system to manage and control AI feature usage with customizable credit allocation.
Backend API key management
Security-first approach ensuring sensitive API keys remain protected on the server side.
User interface
Tailwind CSS & shadcn/ui
Utility-first CSS framework and pre-designed components for rapid UI development.
Base UI
Accessible, unstyled components that provide the foundation for beautiful, functional interfaces.
Shared UI package
Centralized UI component library ensuring consistency across all applications in the monorepo.
Templates
AI Kit includes several production-ready template applications that showcase diverse AI capabilities. Use these examples to understand implementation patterns and jumpstart your own projects.
Chat
Build intelligent conversations with an AI chatbot featuring contextual reasoning, web search, and shareable chats.
Voice
Build real-time voice experiences, including streaming audio, transcription, and voice agents.
Image playground
Create visuals with a versatile AI image generator for multiple models, styles, and resolutions.
Retrieval-augmented generation
Extract insights from documents by having conversations with your files using AI.
Text to speech
Convert text into lifelike speech with thousands of voices and languages.
Agents (coming soon)
Follow the planned agent workflows. The current app contains a roadmap preview.
Scope of this documentation
Use these guides for AI Kit's templates and its own authentication, credits, database, and API. To add full account flows, subscriptions, organizations, or admin, follow Integrate Core Kit.
For a TanStack Start app on Cloudflare Workers with D1 and an AI foundation, explore Edge Kit. Its AI building blocks connect model calls, streaming, and message rendering. Edge uses different routing, authentication, and binding infrastructure from the AI Kit templates.
Setup
The fastest start is the AI Kit CLI. If you already cloned the repo or are combining with Core, use the guides below:
AI Kit CLI
Create a new AI Kit project and configure providers, models, tools, voice, and storage from the terminal.
Extras
Template conventions, ChatGPT prompt pack, editor rules, and Discord channels that ship with the kit.
Combine AI Kit with Core Kit
Choose the repository that owns your app, then port features without replacing shared packages.
Web app setup
Use the shared Next.js development workflow while keeping AI Kit as your repository.
Mobile app setup
Use the shared Expo development workflow while keeping AI Kit as your repository.
Configure specific AI providers and demo apps from the sidebar after bootstrap. If you have not created the project yet, start with the AI Kit CLI (npx @turbostarter/cli@latest new -k ai).
When AI Kit is your application base, use the ai repository for Git commands. If Core Kit is already your base, keep working in core and port the selected AI feature by following the Core-first recipe.
Deployment
Deploying AI Kit follows the same process as deploying the core web application. Ensure you configure all necessary environment variables, including those for your selected AI providers (like OpenAI, Anthropic, etc.), in your deployment environment.
For comprehensive deployment instructions across various platforms, consult our core deployment guides:
Deployment checklist
General checklist before deploying the web app.
Vercel
Streamlined deployment process for Vercel hosting.
Railway
Step-by-step guide for deploying to Railway.
Docker
Container-based deployment using Docker.
Other Providers
Additional guides for Netlify, Render, AWS Amplify, Fly.io and more.
For mobile app store deployment, refer to our mobile publishing guides:
Publishing checklist
Comprehensive pre-publishing verification for mobile applications.
iOS App Store
Publish your iOS app to the Apple App Store.
Google Play Store
Publish your Android app to the Google Play Store.
Updates
Best practices for managing updates to published mobile apps.
Each AI demo app may have specific deployment considerations, so check their dedicated documentation sections for additional guidance.
AI-assisted development
AI Kit ships editor rules, skills, a code-reviewer subagent, and a new-feature command so agents follow this monorepo. The extras page covers template conventions, what is on disk, and the ChatGPT prompt pack that comes with the license.
Major AI coding assistants - such as Cursor, Claude, ChatGPT Codex, Antigravity, and others - work with this setup when you open the cloned project.
Use /llms.txt for LLM-optimized docs. For the shared symlink layout and editor knobs, see the AI-assisted development guide.
Let's build amazing AI SaaS!
We're excited to help you create innovative AI-powered applications quickly and efficiently. If you have questions, encounter issues, or want to showcase your creations, connect with our community:
Happy building!
Tech stack
See the libraries, frameworks, and services that power AI Kit, from Next.js and Expo to AI SDK providers and billing.
CLI
Create an AI Kit project with @turbostarter/cli. Optional mobile, local or cloud Postgres, then AI Gateway, models, tools, voice, and S3 from one flow.
Extras
Conventions in the templates, the ChatGPT prompt pack, and editor extras that ship with AI Kit.
Architecture
See how AI Kit is organized across apps, packages, and AI capabilities. A map of the monorepo before you customize providers, routes, or UI.
Integrate Core Kit
Add Core Kit authentication, billing, organizations, admin, email, and product infrastructure without replacing AI Kit's templates.
How is this guide?
Last updated on





