Production-Ready SaaS Starter

TanStack Start SaaS Template

A production-ready SaaS template for TanStack Start. Built-in enterprise authentication, Stripe billing, multi-language i18n, SEO, an admin dashboard, and referral and affiliate systems, so you can cut your time from idea to revenue.

Core Tech Stack:
TanStack Start
Cloudflare D1
Stripe
referral-rewards · route.ts
import { db } from '@/lib/db';
import { referrals, users } from '@/lib/schema';
import { grantReferralReward } from '@/lib/referral';

// TanStack Start + Cloudflare Workers · Referral reward grant
export async function POST(req: Request) {
  // 1. Query Cloudflare D1 for referral relation
  const relation = await db.select().from(referrals)
    .where(eq(referrals.code, 'MOKER8X'));

  // 2. Auto-grant credits + extend subscription days
  const reward = await grantReferralReward({
    referralId: relation[0].id,
    refereeId: relation[0].referredId,
    plan: 'pro',
  });

  // 3. Insert into Drizzle ORM history + trigger webhook
  await db.insert(referralHistory).values({
    userId: relation[0].referrerId,
    action: 'subscription_reward',
    pointsAwarded: reward.points,
    subscriptionDaysExtended: reward.days,
  });

  return Response.json({ ok: true, reward });
}
Full-Stack Tech · Modern SaaS Infrastructure

Full-Stack Architecture Built for Production.

Production-grade modern dev frameworks, zero-config out of the box, so you can focus on your core business logic.

TanStack Start · Cloudflare Workers

Stack: React 19 + TS

Built on TanStack Start with Cloudflare Workers for edge-native SSR and streaming, with ultra-fast global deployment.

Cloudflare D1 + Drizzle

Status: Type-safe ORM

Cloudflare's D1 serverless SQLite database with the lightweight Drizzle ORM for fully type-safe database interactions.

TANSTACK_ROUTER
CLOUDFLARE_D1
STRIPE_BILLING
Framework Live Test Status

> [04:22:11] TanStack Start + Cloudflare Workers route loaded... OK

> [04:22:15] Cloudflare D1 pool init succeeded (12ms)

> [04:22:19] Stripe SDK & Webhook received event: checkout.session.completed

Stripe Subscription Integration

Integration: Webhook + Portal

Built-in Stripe Checkout, monthly/annual subscriptions, webhook endpoints and a self-service customer billing portal.

Production-Ready Out of the Box

Deploy: Cloudflare Workers

No cloud vendor lock-in. One-click deploy to Cloudflare Workers, Cloud Run or any Node.js / Docker compatible server.

Dev Efficiency Boost
10X+
Core Components
40+ Ready-to-use
DB Compatible
Full Cloudflare D1
Architecture
Production-Ready
All-in-One SaaS Solution

Out-of-the-box core business modules.

Admin console, user workspace, Stripe multi-tier subscriptions and affiliate rewards—all ready, no reinventing the wheel.

Module {current} / {total}

Admin Console
Total Control of Your SaaS.

A powerful admin system with user management, role-based access, analytics and points adjustment—so you can run the whole platform with confidence.

  • User management with granular roles (Admin / Member)
  • Track active users, MRR revenue and subscription conversion
  • Manual/auto points adjustment with full audit logs
Avg. Dev Time Saved
200+ Hours
Ship your core business
Referral Commission
30% Rate
Auto-settled & withdrawable

Super Admin Panel (Admin Console)

Site-wide users, roles, points activity and financial analytics

SUPER_ADMIN
Admin Console Preview
Dashboard + user management + role permissions
Transparent Commercial License

Flexible plans for indie developers and growing teams.

Choose the plan that fits your team. Get started with the trial, scale with monthly or annual billing, or contact us for enterprise customization.

Trial
$4.99 / 7-day trial

7-day trial to experience full features

  • Duration: 7 days
  • Credits: 1,000 included
  • Complete SaaS template + advanced features
  • Complete user authentication system
Recommended
Annual
$159 / year

Annual subscription, best value option

  • Duration: 365 days
  • 15,000 credits included
  • Complete SaaS template + advanced features
  • Stripe payment integration
  • 1-year technical support
  • Best value - Save 34%
Professional
$15.9 / month

Ideal for startups and SMEs, includes advanced features

  • Duration: 30 days
  • Credits: 1,000 included
  • Complete SaaS template + advanced features
  • Stripe payment integration
  • 1-year technical support
Real Developer Reviews

Trusted by developers & creators.

Verified

Zhang Ming

Indie Developer · Founder @ AI Writing Assistant

“This SaaS template saved me tons of repetitive setup work on TanStack Start & Cloudflare Workers and Stripe subscriptions. I shipped in 3 days and received my first overseas subscription payment!”

Verified

Alex Chen

CTO @ CloudScale Engineering

“The out-of-the-box PostgreSQL and Drizzle ORM schema config is super elegant. Clean codebase, second development is a breeze.”

Verified

Wang Xiaolei

Full-Stack Engineer @ Global SaaS Geek

“The cleanest TanStack Start SaaS template I've seen. No bloated third-party dependencies, focuses on auth, database and Stripe subscriptions—highly recommended!”

FAQ

Technical & Deployment FAQ.

Answers to common questions indie developers and startups have about using the template, choosing the architecture, and shipping to production.

The template is built on TanStack Start + Cloudflare Workers, Better Auth authentication, Resend email service, Cloudflare D1 serverless database (Drizzle ORM), and the Stripe subscription SDK.