Tech stack for a SaaS or web app

A TypeScript stack that most tutorials, templates and AI coding assistants use. Every piece has a free plan and can be swapped later without rewriting the rest.

For example: a SaaS idea, a dashboard, a marketplace, anything with sign-in and saved data, or an app from Lovable, Bolt, v0 or Cursor.

Cost $0 a month while you build on free tiers (Vercel’s Hobby plan is non-commercial), plus about $11 a year for a domain. Once you charge money, expect roughly $20 to $60 a month plus payment fees.

  1. 1

    A framework

    The code structure your app is written in: pages, routing, data loading and server code. Pick one and learn it well; the rest of the stack plugs into it.

    Next.js

    Free, open source

    React with server rendering and API routes in one project. It is what most SaaS templates, tutorials and AI builders produce.

    Also worth a look: SvelteKit, Nuxt, TanStack Start · compare all frameworks →

  2. 2

    UI components

    Buttons, forms, dialogs, menus and tables that look consistent and work with a keyboard and screen reader, so you do not build them from scratch.

    shadcn/ui

    Free, open source

    Copy-in components styled with Tailwind that you own and can change. Pairs naturally with Next.js.

    Also worth a look: Mantine, daisyUI · compare all UI libraries →

  3. 3

    Somewhere to run it

    Your code has to run on a computer that is always online. An app host builds it from your GitHub repository on every push, so you never manage a server.

    Vercel

    Free tier, then from $20/mo

    Pauses Non-commercial only

    Made by the Next.js team: every branch gets a preview link. The free Hobby plan is for non-commercial use; once you charge money, Pro is $20 a month.

    Also worth a look: Railway, Render, Cloudflare Workers (incl. Pages) · compare all paaS →

  4. 4

    A database

    Where user accounts and everything else you save is kept. Postgres is the safe default; almost every tool and tutorial supports it.

    Neon

    Free tier, then usage-based

    Pauses

    Serverless Postgres with a generous free plan and a database branch for every preview deploy; paid use has no monthly minimum.

    Also worth a look: Supabase, Convex, PlanetScale · compare all databases →

  5. 5

    Talking to the database

    A library that turns your code into SQL with types, and manages changes to your tables (migrations).

    Drizzle ORM

    Free, open source

    Tables defined in TypeScript and queries that read like SQL, with generated migrations. Works on serverless hosts with no extra setup.

    Also worth a look: Prisma ORM, Kysely · compare all ORMs →

  6. 6

    User sign-in

    Sign-up, log-in, password resets and "Sign in with Google". Writing this yourself is easy to get wrong in ways that leak accounts.

    Clerk

    Free tier, then from $25/mo

    Not stated Their branding

    Ready-made sign-in screens for Next.js, free up to 50,000 monthly users.

    At $0

    Better Auth

    Free, open source

    A free, open-source library that keeps users in your own database: no per-user bill however much you grow, for a little more code.

    Also worth a look: Supabase, WorkOS AuthKit · compare all auth →

  7. 7

    Taking payments

    Charging for subscriptions or one-off purchases. Selling software abroad also means sales tax and VAT, which a merchant of record handles for you.

    Polar

    Usage-based

    A merchant of record built for developers: it deals with tax worldwide, with subscriptions, usage billing and license keys. 5% + 50¢ per sale to start, no monthly fee.

    Also worth a look: Stripe Billing, Paddle, Creem · compare all payments →

  8. 8

    Sending email

    Sign-up confirmations, password resets and receipts have to come from somewhere. Sending them from your own server usually lands in spam.

    Resend

    Free tier, then from $20/mo

    Stops at the limit

    3,000 emails a month free (100 a day), with React Email templates and examples for most frameworks.

    Also worth a look: Postmark, Amazon SES · compare all transactional email →

  9. 9

    Work in the background

    Optional

    Anything slower than a page load should not make users wait: sending batches of email, processing uploads, calling AI models, nightly clean-ups.

    Inngest

    Free tier, then from $99/mo

    Pauses

    Runs steps from your existing API routes with retries, on any serverless host; 50,000 executions a month free.

    Also worth a look: Trigger.dev, Upstash QStash · compare all jobs and queues →

  10. 10

    File uploads

    Optional

    Profile pictures, documents and other files users upload belong in object storage, not in your database or on the app server.

    UploadThing

    Free tier, then from $10/mo

    Not stated

    Upload buttons and a typed server API for Next.js, with 2 GB free and downloads not metered.

    Also worth a look: Cloudflare R2, Supabase · compare all storage →

  11. 11

    A domain name

    The address people type (yourname.com). Your host gives you a free subdomain to start with, so this can wait until you have something to show. Compare renewal prices, not the first-year offer.

    Porkbun

    From $11.08/yr

    The same price for a .com in year one and at renewal, with free WHOIS privacy.

    At $0

    No free option

    No registrar is free. A .com costs about $11 a year at a registrar that renews at the first-year price; free subdomains from your host work until then.

    Also worth a look: Cloudflare Registrar, Namecheap · compare all registrars →

  12. 12

    Knowing when it breaks

    Optional

    An error tracker emails you the exact line that crashed before a user has to. Worth adding once real people use the app.

    Sentry

    Free tier, then from $26/mo

    Stops at the limit

    The free Developer plan covers 5,000 errors a month and has a setup guide for every framework.

    Also worth a look: Better Stack, UptimeRobot · compare all monitoring →

What do I need to build a SaaS or web app?

A framework, UI components, Somewhere to run it, A database, Talking to the database, User sign-in, Taking payments, Sending email, A domain name. $0 a month while you build on free tiers (Vercel’s Hobby plan is non-commercial), plus about $11 a year for a domain. Once you charge money, expect roughly $20 to $60 a month plus payment fees.

Is Next.js still a good choice for a SaaS?

Yes for most people: it has the most templates and examples, and it runs on Vercel and any Node host. SvelteKit and Nuxt are just as capable if you prefer Svelte or Vue.

Stripe or a merchant of record?

Stripe has lower fees but leaves sales tax and VAT to you. A merchant of record such as Polar or Paddle costs a little more per sale and handles tax in every country, which is usually worth it for a small team.