Run PHP 7.4 and PHP 8.4 side by side on Windows
An old shop that needs PHP 7.4 and a new Laravel app on PHP 8.4, on the same computer, at the same time. On Windows that usually means two installs and hand-edited server configs. With Lumina it takes a few clicks.
1. Install the PHP versions
- Open Quick Add and pick PHP.
- Click Install next to each version you need, for example 8.4 and 7.4. Every line lists its three newest patch releases, so you can match a server exactly.
- Each download is checked against its published SHA-256 before it is unpacked.
2. Choose the version for everything
On the Services page, the PHP card's Version list sets the PHP that every site uses by default. "Newest installed" follows new versions as you install them.
3. Give one project its own version
- Open Sites and click Edit on the project.
- Pick its PHP version, for example 7.4, and save.
- The site gets its own PHP pool; every other site keeps the shared one. This works with nginx and Apache.
4. Use the same version in the terminal
Lumina puts php and composer on PATH (the PATH page), following the active version. Check it with:
php -v
composer --version
Questions
Which PHP versions can I install?
PHP 7.4, 8.0, 8.1, 8.2, 8.3, 8.4 and 8.5, each with its three newest patch releases. PHP 7.4 to 8.0 are end of life, so use them only for old projects.
Does Xdebug work with every version?
On Windows, Quick Add offers Xdebug for every PHP line from 7.4 to 8.5, and the PHP card switches it on in one click.
And on macOS or Linux?
There PHP comes from Homebrew. Quick Add shows the brew install command for each version line (PHP 8.0 and 7.4 from the shivammathur/php tap), and Lumina finds them on its own.
Related guides
-
Run Laravel locally with HTTPS
Set up a Laravel project locally with a real https:// address and a certificate your browser trusts, plus MySQL and Mailpit, on Windows, macOS or Linux.
-
Local .test domains on Windows
Give every local project its own address like http://blog.test on Windows, without editing the hosts file or Apache virtual hosts by hand.