Skip to content
FossShelf
Home / Categories / For Web Developers

Next-Elite

Open source Next.js boilerplate with auth, RBAC, and i18n baked in

Replaces Vercel, Netlify, Supabase

133 starsMITlast commit 13 Nov 2026
Screenshot of Next-Elite

Who it's for

Developers starting a multi-role SaaS product

Next-Elite's RBAC setup (admin and user roles with server-side guards) and parallel route slots cover the common pattern of a SaaS dashboard with separate admin and end-user views. Auth, role gates, and dashboard layout are pre-built; the team can start on product features immediately.

Skip if your app needs a single-role interface or no admin vs user distinction. The parallel routing setup adds structural complexity that is unnecessary for simple single-tenant tools.

Teams building internationalized apps for global markets

The six-locale i18n setup with RTL support covers Arabic-speaking markets that most starters ignore. Type-checked translation keys prevent missing-string regressions at build time rather than at runtime, which matters when shipping across multiple locales under CI.

Skip if your target market is English-only. The i18n layer adds translation files and locale configuration overhead that is unnecessary for single-language apps.

Solo developers who want a tested, linted foundation

The repo ships with Vitest unit tests, Playwright E2E tests, Oxlint, Oxfmt, Knip, and Lefthook pre-commit hooks. A solo developer gets a disciplined workflow from the first commit without configuring each tool individually. Demo credentials let them validate the auth flow immediately.

Skip if you prefer to configure your own toolchain incrementally. The opinionated linting and hook setup can feel restrictive when starting with a blank slate.

Teams moving off Supabase Auth to a self-hosted auth layer

BetterAuth covers the core Supabase Auth features: email/password, Google OAuth, session handling, and role-based access. Teams that want to remove the Supabase dependency and run auth on their own server can use this boilerplate as the migration target.

Skip if you need Supabase's realtime subscriptions, row-level security, or built-in storage. Next-Elite provides no equivalent for those features and bundles no database.

The problem

Starting a Next.js project means re-solving the same setup problems on every build: configuring authentication flows, wiring role-based access control, setting up internationalization across locales, adding form validation, connecting a testing suite, and tuning Lighthouse scores. Each piece requires reading docs, resolving package conflicts, and debugging integration edges. A typical team spends the first sprint on infrastructure, not product. Commercial boilerplates address this but add per-seat licensing or required subscriptions. Paid services like Supabase bundle auth and a database under a pricing tier that scales with usage. Vercel and Netlify offer convenient deployment but charge for team collaboration and advanced analytics that become necessary at scale. The trade-off is predictable: start fast on someone else's stack, then hit the pricing ceiling when it matters.

How it works

BetterAuth with permission-based RBAC

Ships email/password and Google OAuth authentication via BetterAuth, with server-side guards (requireUser, requirePermission) and parallel route slots (@admin, @user) for role-based dashboard routing. Admin and user roles are pre-configured; adding a new role means editing one permissions file and optionally adding a route slot.

Type-safe i18n across six locales

Cookie-based localization (no URL prefix) supporting English, Bengali, Arabic RTL, French, Spanish, and Chinese via next-intl. Translation keys are type-checked at compile time, so typos fail the build before reaching production. Adding a new language requires one JSON file in messages/ and a locale entry in site.config.json.

50+ shadcn/ui components with Tailwind CSS v4

Pre-built accessible UI primitives using shadcn/ui, Radix UI, and Tailwind CSS v4. Components cover auth layouts, a collapsible dashboard sidebar, form inputs with Zod validation, theme toggle, and language switcher. All components live in src/components/ and can be extended without modifying core logic.

Integrated quality gates with Oxlint and Playwright

Linting runs via Oxlint and formatting via Oxfmt through Lefthook pre-commit hooks. Knip detects unused dependencies. Commitlint enforces conventional commits. Vitest handles unit tests; Playwright handles end-to-end tests. A single npm run check runs typecheck, lint, knip, and all tests as the CI gate.

Docker and multi-arch self-hosting

Produces a standalone Next.js Docker image compatible with linux/amd64 and linux/arm64 via Buildx. Runs on ARM servers including Oracle Cloud Free Tier and Raspberry Pi. Ready for Dokploy out of the box. A health probe at /api/health lets load balancers monitor and restart the container automatically.

SEO and PWA suite from site.config.json

site.config.json is the single source of truth for sitemap, robots.txt, and PWA web app manifest. OpenGraph metadata, Twitter cards, and JSON-LD structured data are pre-wired. An llms.txt file supports AI discovery. Sentry integration covers error tracking on both client and server with minimal configuration.

Features

  • BetterAuth with permission-based RBAC
  • Type-safe i18n across six locales
  • 50+ shadcn/ui components with Tailwind CSS v4
  • Integrated quality gates with Oxlint and Playwright
  • Docker and multi-arch self-hosting
  • SEO and PWA suite from site.config.json

How to install

Clone the repository and install dependencies to start the local development server.

git clone https://github.com/salmanshahriar/Next-Elite.git
cd Next-Elite
npm install
cp .env.example .env
npm run dev

Recommended for this setup

Strengths

  • MIT license with no attached backend: The MIT license means no usage restrictions, no revenue share, and no forced upgrade path. Unlike Supabase's backend-as-a-service model, Next-Elite is database-agnostic: BetterAuth runs independently, and data fetching connects to any REST, GraphQL, or BFF endpoint you control.
  • Production-ready from the first clone: The repo ships with CI workflows, pre-commit hooks, conventional commit enforcement, E2E tests via Playwright, and unit tests via Vitest. A developer who clones it and runs npm run check gets passing tests, zero lint errors, and a working type-check before writing a single line of product code.
  • Parallel routing for role-based dashboards: Next.js parallel routes (@admin and @user slots) mean both roles share the /dashboard URL, with the server selecting the correct slot based on the session role. This avoids separate /admin and /user route trees that duplicate layout code and diverge over time as the app grows.
  • RTL and multi-language from day one: Arabic RTL support is baked in, not bolted on later. The six-locale setup uses cookie-based locale selection, so the URL stays clean and middleware handles language switching without redirects or reloads. Type-checked translation keys prevent missing-string regressions at build time.

Trade-offs

  • No bundled database or ORM: Next-Elite ships with no database connection, no ORM, and no migration tooling. Teams that want a full-stack starter with Postgres and Drizzle or Prisma pre-configured must wire that themselves. This is a deliberate design choice documented in the README, but it means more setup for apps that need a data layer from day one.
  • Small community and young repository: At 107 stars and created in November 2025, the project has a small community compared to established alternatives like T3 Stack or create-next-app. GitHub Discussions and community resources are limited, so debugging unusual issues means reading source code rather than finding existing answers.
  • npm-only package manager: The repo ships a package-lock.json and all scripts assume npm. Teams using pnpm or yarn workspaces will need to convert the lockfile and verify that Lefthook hooks still run correctly after the migration. The README names npm as the single supported package manager.

Tech stack

Languages
TypeScript, JavaScript, CSS, Dockerfile
Frameworks
Next.js, React
Databases
—
Tooling
—

FAQ

Does Next-Elite include a database?

No. Next-Elite is intentionally database-agnostic and ships with no ORM, migration tooling, or database connection. It is built for an API-driven workflow where data is fetched from a separate backend. Teams that need Postgres or another database must add it themselves.

Can I self-host Next-Elite without using Vercel?

Yes. The boilerplate ships a standalone Docker build that runs on any server, including ARM64 machines. It also supports Dokploy for self-hosted deployments. The one-click Vercel button is a convenience, not a requirement. Set BETTER_AUTH_URL to your server's domain when deploying outside Vercel.

How does the RBAC work in Next-Elite?

Next-Elite uses BetterAuth for sessions combined with a custom permissions layer. Server components call requirePermission('dashboard.view:admin') to guard routes at the server level. Parallel route slots (@admin and @user) let the /dashboard URL show different content based on the session role. Adding a new role means editing the permissions file and optionally adding a route slot.

What languages does the i18n support cover?

Next-Elite ships translations for English, Bengali, Arabic (RTL), French, Spanish, and Chinese. Locale is stored in a cookie with no URL prefix, so switching languages does not change the URL. Adding a new language requires creating one JSON file in messages/ and adding a locale entry in site.config.json.

Is Next-Elite suitable for production use?

It is a starting point, not a finished product. The repo ships production-quality tooling: Vitest tests, Playwright E2E tests, Oxlint, Docker standalone output, Sentry integration, and health probes at /api/health. You need to add your own database layer, configure environment variables for production, and set NEXT_PUBLIC_DEMO_MODE=false before shipping.

Similar tools

More in Web Developers