Skip to main content
Featured

SaaSForge AI

Next.js AI SaaS boilerplate with RAG, credits, and Stripe

Streaming chat against Claude and OpenAI APIs, uploads for PDF and text, embeddings in Postgres with pgvector, credits tied to token use, Stripe checkout and webhooks, Supabase sign-in, plus a small dashboard that sanity-checks env and DB wiring after clone.

$259$379
Launch pricing · One-time purchase · Full source code

Secure checkout by Polar (Merchant of Record) · Taxes calculated at checkout · Refund Policy

View Documentation
SaaSForge AI: dashboard preview with AI chat, RAG, and billing

What technical buyers check before they buy an AI SaaS Next.js boilerplate

  • Next.js App Router
  • TypeScript
  • Claude & OpenAI
  • pgvector RAG
  • Supabase
  • Stripe billing
Next.js 16
App Router + React 19
Streaming + RAG
Models, uploads, search
Stripe + Supabase
Credits, auth, Postgres
Use cases

What you'll build

Three concrete products you can ship on this template without touching the plumbing.

AI Support Bot

Ingest docs, tickets, or KB articles. Ship a support copilot with citations and conversation history.

Document Q&A

Upload PDFs and reports, ask questions, get answers with chunk citations.

AI Writing Tool

Streaming editor with multi-model switching, credits-per-token metering, and Stripe billing built in.

Why teams buy this AI SaaS Next.js boilerplate

Streaming chat, document RAG on pgvector, token-metered credits, Stripe subscriptions, and Supabase-backed auth are bundled so you can demo a credible AI product after purchase instead of stitching five tutorials together.

Chat UI with streaming and multi-model switching

Buyers want to see a real assistant, not a fetch() demo. You get streaming chat against Claude and OpenAI through the Vercel AI SDK, conversation history, edit and regenerate flows. Enough to demo a real AI product on clone day.

Get instant access

Included in this template

  • Streaming responses with provider switching you can extend
  • Conversation threads persisted through Supabase
  • Per-model configuration and UI affordances
  • MCP-style extension seams for tools and integrations
  • Token-aware UX that pairs with the credit system below
  • Responsive, themeable UI built from shadcn/ui + Radix

Document RAG on Postgres with pgvector

RAG is where most AI templates fall apart under audit. This repo wires uploads (PDF, text, Markdown), embeddings, and semantic search against pgvector in Supabase Postgres. Your data plane story holds up when security asks.

Read configuration docs

Included in this template

  • Upload, chunk, embed, query pipeline with clear extension points
  • pgvector indexes and migrations included in the SQL you ship
  • Citation-friendly retrieval for support and knowledge bases
  • Workspace-scoped data boundaries via Supabase RLS
  • Sane defaults for file types and limits (tighten per product)
  • Operational notes for local dev vs production embeddings

Stripe subscriptions with a real credit economy

Flat-rate “AI credits” marketing rarely survives finance review. You get subscriptions plus token-metered credits, monthly reset endpoints, and Stripe webhooks. A monetization story that matches how teams actually bill LLM usage.

Unlock the full template

Included in this template

  • Checkout, customer portal, and webhook lifecycle handling
  • Credit balances tied to real usage, not vanity counters
  • Cron-friendly reset patterns documented for operators
  • Price tables and plan tiers you can map to your Stripe products
  • Clean separation between metering and UI, so refactors stay safe
  • Guardrails that reduce refund risk after purchase

Auth, isolation, and a dashboard that proves wiring

Supabase Auth (email and OAuth) plus RLS-oriented patterns are the backbone of a serious SaaS fork. A small post-clone dashboard checks env and database wiring, so your first deploy day is boring in a good way.

See getting started

Included in this template

  • Supabase Auth flows that map to common B2C launches
  • Postgres schema and migrations for chat, uploads, and credits
  • Setup validation dashboard: catch misconfiguration before users do
  • Sensible defaults for secrets and server-only boundaries
  • Hooks for extending profiles and org models when you outgrow v1
  • Testing guidance (Vitest) for critical paths

Docs, compliance pages, and the SEO surface buyers expect

Template purchases fall through when legal and marketing routes look like placeholders. Bundled MDX docs, GDPR pages, and metadata helpers kill the “is this toy software?” objection before it comes up in evaluation.

Browse documentation

Included in this template

  • MDX docs with long-form guides for setup and config
  • GDPR, DPA, subprocessors, and retention pages as starting points
  • Open Graph, JSON-LD, sitemap, robots aligned with Next.js 16
  • Blog surface with highlighting and share affordances
  • White-label ready via config-first copy and branding
  • Clear upgrade seams for when you need enterprise-only features later

One repo that matches an AI SaaS pitch deck

If your landing page promises chat, uploads, metering, and billing, the repo should back it up without duct tape. Buy once, demo to investors and customers the same week, then fork hard toward your niche.

Buy template (one-time license)

Included in this template

  • UI, data, billing, and auth in one private codebase
  • Folder boundaries that keep AI code from sprawling
  • Dark mode and responsive layouts across dashboard and marketing
  • Extension-friendly layout for adding tools, evals, or analytics
  • Fewer “coming soon” gaps than generic starters
  • Predictable upgrade path toward your own model routing

FAQ

Questions we get before someone buys a template

Ready to Ship?

Start Building with SaaSForge AI Today

Get the complete source code and launch your AI-powered product in days, not months.