Multi-Tenancy
Distribute subsites across servers and databases for performance and security
Version 1.2.0 release highlights
Multi-Tenancy 1.2.0 adds the sovereign tenant foundation for production isolation workflows:
- Stateless tenant autologin with short-lived, replay-protected SSO visits.
- Per-subsite database and filesystem isolation for sovereign tenants.
- Hostinger multi-tenancy capability for host-aware tenant provisioning.
- Sovereign migration verification gates for legacy data checks and async push processing.
- Configurable same-machine database host binding for Bedrock, FrankenPHP, and localhost installs.
- Tenant bootstrap, database writer, schema bootstrap, and user provisioning improvements.
- Safer sovereign teardown that cleans tenant credentials.
See the user guides for sovereign migration workflow, multi-tenancy isolation, and sovereign tenant operations.
Requirements
- WordPress 5.3 or higher
- PHP 7.4 or higher
- Multisite Ultimate plugin (active)
Installation
- Upload the addon files to your
/wp-content/plugins/directory - Activate the plugin through the 'Plugins' menu in WordPress
- Configure the addon settings in the network admin
Development
Setup
# Install dependencies
composer install
npm install
# Run tests
npm run test
# Run code standards checks
vendor/bin/phpcs
vendor/bin/phpstan
# Fix code style issues
vendor/bin/phpcbf
# Build for production
npm run build
Project Structure
ultimate-multisite-addon-template/
├── inc/ # PHP classes and includes
│ ├── class-multisite-ultimate-updater.php # Update handler
│ └── class-multi_tenancy-main.php # Main functionality
├── tests/ # Unit tests
│ ├── bootstrap.php # Test bootstrap
│ ├── class-*-base.php # Base test class
│ └── class-*-test.php # Test cases
├── views/ # Template files
├── assets/ # Static assets
│ ├── css/ # Stylesheets
│ ├── js/ # JavaScript files
│ └── images/ # Images
├── lang/ # Language files
├── composer.json # PHP dependencies
├── package.json # Node.js dependencies
├── phpunit.xml.dist # PHPUnit configuration
├── .phpcs.xml.dist # Code standards configuration
└── rector.php # Code modernization rules
Testing
The addon includes a comprehensive testing framework:
- Unit Tests: PHPUnit-based tests with WordPress test suite
- Base Test Class: Provides helper methods for common test scenarios
- Test Coverage: Configured to track code coverage
- Multisite Testing: Tests run in multisite environment
Code Standards
- WordPress Coding Standards: Enforced via PHPCS
- PHP 7.4+ Compatibility: Modern PHP features supported
- Static Analysis: PHPStan integration for type checking
- Code Modernization: Rector rules for PHP upgrades
Build System
- Asset Processing: Minification for CSS/JS files
- Translation: POT file generation
- Packaging: Archive creation for distribution
- Development Mode: Unminified assets for debugging
Configuration
The addon supports various configuration options accessible through the network admin interface.
Sovereign tenant configuration
For sovereign tenants, configure the tenant database, filesystem root, database host binding, and host capability before routing traffic to the tenant. Run migration verification after every change that affects database credentials, host binding, routing, or user provisioning.
Use localhost only when the tenant runtime and database grants expect local socket or same-machine access. Use 127.0.0.1 or a service hostname when that is the grant host configured by your provider.
Hostinger capability
The Hostinger multi-tenancy capability works with the shared Hostinger integration token. Confirm the domain is present in hPanel, DNS points to the Hostinger account, and the tenant database settings match hPanel before verification.
Hooks and Filters
Actions
ultimate-multisite-addon-template_init- Fired after addon initializationultimate-multisite-addon-template_loaded- Fired after all addon files are loaded
Filters
ultimate-multisite-addon-template_settings- Modify addon settingsultimate-multisite-addon-template_enabled- Override addon enable/disable status
License
This addon is licensed under the GPL v3 or later.
Support
For support and documentation, visit MultisiteUltimate.com
Changelog
-
Version 1.2.0 (2026-06-03): add stateless tenant autologin, Hostinger multi-tenancy capability, per-subsite database and filesystem isolation, sovereign migration verification gates, tenant bootstrap/database writer improvements, configurable MySQL host binding, and safer sovereign teardown.
-
Version 1.0.1 (2025-09-28): rename prefix to ultimate-multisite; update text domain; version bump.
-
Version (2025-09-28): rename prefix to ultimate-multisite; update text domain; version bump.