DEV Community

Cover image for Laravel Filament Multi-Tenant Starter - Build your app fast
yebor974 for Filament Mastery

Posted on • Originally published at filamentmastery.com on

Laravel Filament Multi-Tenant Starter - Build your app fast

Building a SaaS with Laravel Filament? You need more than two panels. You need teams, invitations, tenant-aware permissions, and a member experience that works for multiple users within the same organization.

Laravel Filament Multi-Tenant Starter does it for you. Backend panel, tenant member panel, team-based multi-tenancy, invitation system, team roles. All wired up and ready to go with Laravel 13 and Filament PHP v5.

What you get

Two panels, two worlds

  • Backend panel for your admins, accessible via subdomain or path
  • Member panel for your users, tenant-aware, with team switching built in

Each panel has its own middleware, routing config, and permission scope.

Team-based multi-tenancy

Multi-tenancy is powered by a Team model. Each user can belong to multiple teams and switch between them directly from the member panel.

  • Users can belong to multiple teams simultaneously
  • Team switching built into the member panel
  • Each team has its own profile page (name), editable by Team Admins
  • Tenant-aware resources and access control throughout the member panel

Two-tier role system

Application roles secure the Filament panels:

  • Backend - access to the backend admin panel
  • Member - access to the member panel

Team roles govern what users can do inside their team:

  • Team_Admin - manages team members, sends invitations, edits team profile

All roles are pre-seeded and defined via enums, clean, extensible, no magic strings.

Complete invitation flow

For existing users:

  1. Team Admin sends an invitation
  2. User accepts
  3. User is immediately attached to the team

For new users:

  1. Team Admin sends an invitation
  2. User receives an invitation email
  3. User registers
  4. User is automatically attached to the team and can access the panel immediately

Secure authentication

  • Email invitation system for backend and member users
  • First-login password setup enforced
  • Password renewal flow via Filament Renew Password
  • MFA with authenticator app support

Production infrastructure, included

  • Laravel Horizon - queue monitoring, backend-only access
  • Logs Viewer - backend-only access
  • Redis for queues and cache
  • Multi-stage Docker setup - PHP-FPM, Nginx, PostgreSQL, Redis, Horizon, scheduler, all wired with healthchecks

Developer experience

  • app/Filament/Shared - shared schemas between panels
  • app/Models/TeamUser - team membership with role scoping
  • app/Services/TeamUserService - team user logic cleanly extracted
  • Per-user timezone applied automatically everywhere
  • Strong password policy enforced globally
  • Light & Dark theme switch + empty custom theme scaffold
  • Database notifications (Filament native)
  • Fully localized - English by default
  • Laravel Debugbar, PHPStan, Laravel Pint, PestPHP included

Tech stack

Framework Laravel 13
Admin panel Filament PHP v5
Frontend TALL Stack: Tailwind v4, Alpine, Livewire
Testing Pest PHP v4
PHP 8.3+
Database PostgreSQL or MySQL
Queue & cache Redis + Laravel Horizon

Who is it for?

✅ SaaS applications with team-based access

✅ B2B platforms where each client is a team

✅ Project management tools

✅ Any app where users belong to organizations with different roles

✅ Add your own billing layer (Laravel Cashier, Paddle, LemonSqueezy)

Need a simpler setup without multi-tenancy? See the Multipanel Starter or the Backend Starter

Compare starter templates

Feature Backend Starter Multipanel Starter Multi-Tenant Starter
Laravel 13 + Filament v5
Backend Panel
Member Panel
Subdomain or Path Routing (per panel) (per panel)
Email Invitation
Public Registration
First-login Password Renewal
MFA (App authenticator)
Roles & Permissions (Spatie)
Team-based Multi-Tenancy
Team Switching
Team Invitations
Team Profile Management
Team Roles (Admin)
Per-panel Permission Scope
Per-user Timezone
Logs Viewer
Laravel Horizon
Dark Mode
Multi-language
Docker Setup
Use case Internal tools Full-stack app SaaS, B2B platforms

Billing

This starter does not include a billing module. The Team model is designed to be extended. Add your Stripe customer ID, subscription status, or any billing-related fields directly to the Team model and TeamUser as needed.

How to install

Without Docker

composer install
cp .env.example .env
php artisan key:generate
npm install
npm run build

Enter fullscreen mode Exit fullscreen mode

Configure your .env, database, Redis, mail, and your panel access:

# Backend panel at backend.yourdomain.com
FILAMENT_PANELS_BACKEND_DOMAIN=backend.yourdomain.com
FILAMENT_PANELS_BACKEND_PATH=

# Or at yourdomain.com/backend
FILAMENT_PANELS_BACKEND_DOMAIN=
FILAMENT_PANELS_BACKEND_PATH=backend

# Member panel at member.yourdomain.com
FILAMENT_PANELS_MEMBER_DOMAIN=member.yourdomain.com
FILAMENT_PANELS_MEMBER_PATH=

# Or at yourdomain.com/member
FILAMENT_PANELS_MEMBER_DOMAIN=
FILAMENT_PANELS_MEMBER_PATH=member

Enter fullscreen mode Exit fullscreen mode

Then run the setup command - migrations, roles & permissions, first backend user:

php artisan backend:setup

Enter fullscreen mode Exit fullscreen mode

All panels are live.

With Docker (recommended)

A docker-compose.example.yaml is included with everything pre-configured: PHP-FPM, Nginx, PostgreSQL, Redis, Horizon, and the scheduler. A dedicated bootstrap service runs migrations automatically before the app starts.

For a deep dive into the Docker architecture:

👉 Production-Ready Docker Setup for Laravel Filament

👉 Production-Ready Docker Compose for Laravel Filament

cp docker-compose.example.yaml docker-compose.yaml
cp .env.docker.example .env
docker compose up -d --build
docker compose exec php-fpm php artisan backend:setup

Enter fullscreen mode Exit fullscreen mode

Access your panels:

  • Backend: https://localhost:4443/backend
  • Member: https://localhost:4443/member

⚠️ Always use https:// - Nginx expects SSL on port 4443. ⚠️ Self-signed certificate warning in local dev is expected. Certificates are provided in docker/example/nginx/certs/.

For production, adapt the compose file and Nginx config to your own infrastructure. See the GitLab CI guide for a complete production pipeline.

Visual overview

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Login

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Sign up

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Team Registration

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Dashboard

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Team Profile

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Team Users List

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Team User Invite

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Team User Invitation Email

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Member Team User Invitation On Login Page

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Backend Dashboard

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Backend Members List

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Backend Teams List

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Backend Teams Edit

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Backend Teams List - Attach User

Laravel Filament Multi-Tenant Starter - Build your app fast
Laravel Filament Multi Tenant Backend Backend Users List

Get access

The Multi-Tenant Starter is included in the Member tier of Filament Mastery, along with the Backend Starter, the Multipanel Starter, all premium articles, and every future starter and guide.

Your membership grants you the right to use this starter on unlimited personal or client projects

Join Filament Mastery ->

Top comments (0)