#241241st of 358 in Backends, databases and hosting
tenancy
Laravel package that adds multi-tenancy without changing application code
Run it:RackNerd ↗ (opens in a new tab)RepoCloud ↗ (opens in a new tab)Affiliate links, no effect on a rank.
- Stars
- 4.4k
- License
- MIT
- Last commit
- Nov 2026
- Last release
- Aug 2026
- Language
- PHP
4,292 on 27 Apr 20264,430 on 23 Nov 2026
From GitHub's daily star counts.
Checked on GitHub.
Overview
stancl/tenancy is a PHP package that makes an existing Laravel app multi-tenant. It identifies tenants by hostname, including second-level domains, and switches the database connection per tenant without model traits or replacing Laravel classes such as Cache and Storage. The README points to v4 documentation on a separate site.
Who it is for: Laravel developers building multi-tenant SaaS apps
Strengths
- No model traits needed to switch the database connection per tenant
- Cache, Storage and similar Laravel classes are kept, not replaced
- Built-in hostname tenant identification, including second-level domains
- MIT license with CI workflow and a dedicated documentation site
Weaknesses
- Laravel only; not usable in other PHP frameworks
- Not an AI project and has no AI features
- README badge says Laravel 10.x while its alt text says 11.x
- README has no install steps or tenancy models; those are in external docs
What it needs
- no GPU
- Docker + Compose
- Needs Laravel, PHP
What changed
From the release notes. No flag means the note does not say so, not that the upgrade is safe.
Known problems
Reported, then fixed by a linked change
- [4.x] PostgresRLSBootstrapper: with a DB_URL the tenant connection keeps the central user's credentials ↗ (opens in a new tab)0 reactions · closed 12 Nov 2026Fixed by [4.x] database: support DB_URL, handle read/write/direct configs ↗ (opens in a new tab)
- Modifications to `BroadcastingConfigBootstrapper::$credentialsMap` are overwritten with values from `$mapPresets` ↗ (opens in a new tab)0 reactions · closed 23 Jul 2026Fixed by [4.x] BroadcastingConfigBootstrapper: fix central instances persisting in tenant context ↗ (opens in a new tab)
- Updating pivot values on TenantPivot causes duplicate entry errors ↗ (opens in a new tab)0 reactions · closed 8 Jul 2026Fixed by [4.x] Fix duplicate entry error when updating TenantPivot columns ↗ (opens in a new tab)
- Race condition in FilesystemTenancyBootstrapper::storagePath() causes mkdir(): File exists warning ↗ (opens in a new tab)0 reactions · closed 13 Apr 2026Fixed by [4.x] Prevent mkdir() race conditions in FilesystemTenancyBootstrapper ↗ (opens in a new tab)
Titles are the reporters' own words, taken from the project's GitHub issues and ranked by reactions. We have not tried to reproduce any of them.
Also in Backends, databases and hosting
See all 358| Rank | Project | Score |
|---|---|---|
| #239 | mallSpring Boot e-commerce backend with admin and storefront APIs | 63 out of 100 |
| #240 | faasServerless functions platform with auto-scaling and language templates | 63 out of 100 |
| #242 | squidexHeadless CMS with REST API, OData filtering and Swagger, built on ASP.NET Core | 63 out of 100 |
| #243 | openchoreoKubernetes developer platform with Backstage portal, CI, GitOps and observability | 63 out of 100 |
| #244 | dante-cloudSpring Cloud microservice base that also runs as a monolith from one codebase | 63 out of 100 |