PHP
LaraEnv ships with a wide range of PHP versions so you can run any project — legacy or modern — on the version it needs.
Supported versions
LaraEnv supports the following PHP versions (thread-safe, x64):
5.6, 7.0, 7.1, 7.2, 7.3, 7.4, 8.0, 8.1, 8.2, 8.3, 8.4
Each version is installed side-by-side under C:\laraenv\php\<version>\, so they never interfere with one another. The path C:\laraenv\php\current\ is a symlink that always points to the active version.
Installing versions
Install any PHP version from the Installer/Downloads catalog. See the Installer for details on browsing and downloading runtimes.
Switching the global version
Switch the global active PHP version from the runtime chips on the Dashboard. This repoints C:\laraenv\php\current\ to the version you pick, which becomes the default for terminals and tools that don't override it.
Per-project versions
You can also set a PHP version per project on the project itself — see Projects configuration.
LaraEnv runs a dedicated PHP-FPM pool per version and points each project's vhost at the correct FPM upstream. This means several projects can run on different PHP versions at the same time — for example, a legacy app on 7.4 and a new app on 8.4, both served simultaneously.
PHP-FPM status
The Dashboard shows PHP-FPM status cards for each version, displaying the version, its port, and whether it is running.
Behind the scenes, Nginx defines FPM upstreams for each version. Ports fall in the ~9000–9400 range per version, and each pool runs multiple workers for load-balancing.
Because each version has its own pool, switching one project's PHP version never affects the others.
See also
- PHP extensions — toggle extensions and edit
php.ini - Projects configuration — set a per-project PHP version
- Installer — download PHP versions