freshheads/multi-site-bundle
A Symfony bundle for running multiple websites from one codebase, with per-site configuration, routing, and content isolation. Simplifies multi-site management without duplicating application logic.
site-a.example.com, path-prefix /de/, or locale-driven). That is a genuine product decision — it changes SEO structure, cookie scoping, CDN config, and how marketing links are built. Use it to settle that decision in a design doc rather than in code review.if ($host === ...) checks. This is the piece most worth copying even if you don't install the package.Important caveat for the decision record: this is a Symfony bundle, not a Laravel package. On a Laravel stack it is not adoptable as-is — it is a reference architecture and a spec, nothing more.
Update from release 1.3.0 (informational): the project has added Symfony 7 support, PHPStan static analysis, a pinned php-cs-fixer toolchain, and a changelog-enforcer check on pull requests. That is a real but modest maturity signal — the codebase is now analysed and CI-gated, and the supported-version question that blocked a Symfony evaluation is answered. It does not change the adoption calculus for a Laravel team, and it does not change the community-size risk. Version 1.3.0 should be treated as the baseline for any reference-reading or spike work.
Consider it when all of the following hold:
composer.json before committing.Look elsewhere when:
stancl/tenancy or spatie/laravel-multitenancy; both are maintained, widely adopted, and cover database-per-tenant isolation this bundle does not. The 1.3.0 Symfony 7 work does not change this at all.To executives: We are evaluating a small open-source component for serving several brands or regions from one application. It is MIT-licensed and free, and it would let us launch additional sites without standing up additional infrastructure — a meaningful reduction in hosting and on-call cost. The component is now on a current release (1.3.0) that adds support for the latest framework version and introduces automated code-quality checks, so it is better maintained than when we first looked. It is still a very low-profile project (two GitHub stars, no downstream users), so I am not recommending we depend on it in production. I am recommending we use it as a reference design and build a thin internal layer modelled on it. That gives us the same capability with no third-party maintenance risk, at an estimated effort of a few days rather than the multi-week scope of a full multi-tenant platform.
To engineering: The bundle solves two problems worth solving: resolving the current site from the request (host or path strategy) and exposing per-site configuration to the rest of the app. That abstraction is the right one and we should adopt the pattern. We should not adopt the dependency — it is a Symfony bundle, our stack is Laravel, and the adoption signal is still too weak to justify ownership. Read the code at tag 1.3.0 (it is now PHPStan-clean, which makes it a better spec to read than earlier versions), and spend a timeboxed spike implementing site resolution and configuration scoping ourselves, with this repo as the reference.
Recommendation: Adopt as a design reference; reject as a dependency. 1.3.0 improves the reference value (Symfony 7 support, static analysis, CI gates) but does not move the dependency decision. Revisit only if we move to Symfony and the upstream project gains dependents or a second active maintainer.
How can I help you explore Laravel packages today?