Pro

Next.js SaaS CLAUDE.md template

Opinionated Next.js App Router SaaS: typed data layer, auth, billing webhooks, and Vercel-first ship discipline.

Building a SaaS on Next.js means juggling auth, billing webhooks, typed data access, and Vercel-first deploy discipline — and your AI assistant needs to know all of it before it writes a single line. TailorMD's Next.js SaaS recipe turns those conventions into a production-ready CLAUDE.md, AGENTS.md, and Cursor rules tuned to App Router, server components, and the stack choices you actually use.

Whether you ship with Clerk or Supabase Auth, Drizzle or Prisma, Stripe or Lemon Squeezy, the recipe encodes folder structure, webhook handling patterns, entitlement checks, and ship checklists specific to subscription products. You answer a short form — project name, auth provider, database, ORM, payments, package manager, deploy target — and get Markdown files your team can drop into the repo today.

The generated context covers non-negotiables like typed env validation, server-only secrets, idempotent billing webhooks, and RLS-aware data access. Cursor rules scope conventions to the right globs; optional skill files give your assistant repeatable review and ship workflows. Re-run the generator when you add a new integration or change deploy targets — no more stale AI briefs copied from a blog post.

What's included

  • CLAUDE.md with App Router SaaS conventions and folder map
  • AGENTS.md for multi-step agent workflows
  • .cursor/rules scoped to your Next.js SaaS repo
  • Skills for code review and pre-ship checklists
  • Webhook, auth, and billing patterns for your chosen stack
  • Live preview, zip download, and CLI scaffold
nextjssaastypescriptvercelstripe

Frequently asked questions

Which auth and payment providers are supported?
The form covers Clerk, Auth0, NextAuth, and Supabase Auth, plus Stripe or Lemon Squeezy. Generated files reference your selections so the AI follows the right integration patterns.
Does this work with the App Router?
Yes. The recipe assumes Next.js App Router with server components by default, Vercel-first deploy discipline, and typed data layers.
Can I use this for an existing SaaS codebase?
Absolutely. Copy the generated CLAUDE.md into your repo and edit project names, routes, and commands to match. The conventions still give your assistant a durable project brief.
What files are generated?
Typically CLAUDE.md, AGENTS.md, .cursor/rules/tailormd.mdc, and optional .claude/skills for review and ship workflows.

Related recipes

Generate your context

Answer a few questions about your stack. Copy CLAUDE.md or download a zip — no API key required.

Checking your account…