Back to Blog
Engineering
March 28, 20266 min read

Our Tech Stack: Next.js, Supabase, and AI-Native Architecture

A look at the technical decisions behind Roukit — why we chose Next.js 15, Supabase with RLS, and how AI fits into the architecture.

RT

Roukit Team

Engineering

Our Tech Stack: Next.js, Supabase, and AI-Native Architecture

Why the stack matters

For a multi-tenant SaaS platform handling bookings, payments, and supplier data across multiple languages, the tech stack isn't just an implementation detail. It determines what's possible at scale.

Here's what we chose and why.

Next.js 15 with App Router

We use Next.js 15 with the App Router for the entire customer-facing application. The reasons:

  • Server components by default — most pages don't need client-side JavaScript. Server rendering means faster initial loads and better SEO.
  • Streaming and Suspense — booking pages can load progressively, showing availability before all reviews are fetched.
  • API routes — backend logic lives alongside the frontend, reducing deployment complexity.
  • Edge-ready — the architecture is designed for edge deployment with Lambda@Edge and CloudFront for per-tenant rendering.

Supabase with Row-Level Security

Our database layer is Supabase (PostgreSQL) with Row-Level Security (RLS) for multi-tenant data isolation. This is critical for the SaaS product:

  • Tenant isolation at the database level — RLS policies ensure that one customer's data is never accessible to another, even if application code has a bug.
  • Real-time subscriptions — booking status updates, availability changes, and supplier notifications use Supabase's real-time capabilities.
  • Auth built in — Supabase Auth handles registration, login, OAuth, and magic links without a separate auth service.

The database currently has 66 tables covering tours, bookings, suppliers, reviews, translations, and operational workflows.

TypeScript everywhere

Strict TypeScript across the entire codebase. No any types. Every API response, database query, and component prop is typed. This catches bugs at compile time instead of in production — especially important when handling payment flows and booking state.

AI architecture

The AI features aren't a separate service. They're integrated into the application layer:

  • Recommendation engine — runs as part of the page rendering pipeline, not as a separate API call.
  • Semantic search — query processing and ranking happen server-side before results reach the client.
  • Sentiment analysis — processes reviews at ingestion time, storing structured sentiment data alongside the raw review.
  • Content optimization — scoring runs as a background job, surfacing results in the admin dashboard.

This integration means AI features have zero additional latency for the end user. Recommendations appear as part of the page load, not as a delayed widget.

Infrastructure

  • AWS S3 + CloudFront for media delivery
  • Vercel for deployment with edge optimization
  • Stripe + PayPal for payment processing
  • Resend for transactional email

The stack is designed to scale from the current production load to hundreds of tenants without architectural changes. That's the benefit of making these decisions early.

Join the waitlist

Be among the first to launch your own branded booking marketplace with Roukit.