Quickstart
Next.js Quickstart
Get started with Rivet Actors in Next.js
Add Rivet Skill to Coding Agent (Optional)
If you’re using an AI coding assistant (like Claude Code, Cursor, Windsurf, etc.), add Rivet skills for enhanced development assistance:
Command Line
Create a Next.js App
Command Line
Install RivetKit
npm
pnpm
yarn
bun
Create an Actor
Create a file at src/rivet/registry.ts with a simple counter actor:
src/rivet/registry.ts
Setup Rivet API route
Create a file at src/app/api/rivet/[...all]/route.ts to setup the API routes:
TypeScript
Use the Actor in a component
Create a Counter component and add it to your page:
For information about the Next.js client API, see the React Client API Reference.
Deploy to Vercel
See the Vercel deployment guide for detailed instructions on deploying your Rivet app to Vercel.