Skip to content

PHP Versions ​

The PHP Versions page lets you install, manage, and configure the supported PHP versions on the server, across every available engine on a single page.

PHP Versions with the REMI repository and the installed PHP versions

Overview ​

URL: /admin/settings/php-manager-versions

Navigate to Settings > PHP > PHP Versions.

The PHP area has two tabs across the top of the content, and each one is a page in its own right:

TabAddressDocumented in
Versions/admin/settings/php-manager-versionsThis page.
Domain Assignment/admin/settings/php-manager-domainsMulti PHP Domains Manager

The counter next to Versions shows how many versions are installed out of the total, and the one next to Domain Assignment counts the domains on the server.

The page shows summary counters (Total, Installed, Available, Repositories) and a card for every supported PHP version. Each card shows the version, its repository (engine), whether it is Installed or Not Installed, and an Install, Configure, or Uninstall action. A search box above the cards filters by version, name, or repository.

PHP versions come from up to three repositories, selected with the filter chips above the card list:

  • REMI - standard PHP for Apache (mod_php / PHP-FPM).
  • LiteSpeed - LSPHP builds served through LSAPI, used when LiteSpeed is the active web server.
  • CloudLinux - Alt-PHP, available after a CloudLinux conversion, including legacy versions down to PHP 5.2.

The REMI repository is always present; LiteSpeed appears once the LiteSpeed module is installed, and CloudLinux (Alt-PHP) appears after conversion, each as an extra chip alongside All. Assign domains and plans to the matching engine on the Domain Assignment tab and, for LiteSpeed, the PHP Migration page.

Note: Since panel 1.9.0, a CloudLinux server runs websites on alt-php only, because Remi PHP and LSPHP run outside the account's LVE and CageFS. On the REMI and LiteSpeed filters the page says so, marks those versions Not supported on CloudLinux, and offers no install for them; an installed one can still be uninstalled. Hosting plans, domains, and clients choose from alt-php versions, and websites still on another version are moved from the Isolation Report. See CloudLinux.

Since panel 1.9.0, clients choose only from the PHP versions you offer them, on the domain form and through the client API. A domain already on a version hidden from clients can still be saved without changing it. The list of installed versions updates on its own when a version is installed or removed, also from the command line, so a new version can be assigned straight away.

One release from several repositories ​

The same PHP release can be installed from more than one repository, for example PHP 8.4 from REMI and from LiteSpeed. Since panel 1.9.2, each of these builds is a version of its own throughout the panel: it lists, and checks before it is removed, only the websites that run that build. A website on REMI PHP 8.4 no longer stops you from uninstalling an unused LSPHP 8.4 or alt-php 8.4, and is not named as one of their websites. Each build has its own configuration and its own profiles.

LSPHP that no web server uses ​

An installed LSPHP version stays on the list when no web server on the server can run it any more, for example after OpenLiteSpeed was removed. Since panel 1.9.2, its card is marked No web server uses it now, and you can still configure or uninstall it. An LSPHP version that is not installed is not offered in that case, since it could not be installed.

Since panel 1.9.4, the panel treats LSPHP the same way everywhere: a website can use an LSPHP version only while a LiteSpeed web server (LiteSpeed Enterprise or OpenLiteSpeed) is the active web server or the LSAPI Engine (mod_proxy_lsapi) is active. A server that still has LiteSpeed installed but was switched back to Apache counts as one without, so its LSPHP cards are marked too. While no such web server is active:

  • the PHP version lists of hosting plans, Create Account, and new domains leave LSPHP out,
  • creating an account or a domain on LSPHP, and saving a hosting plan or changing a domain to it, is refused with the reason: websites on it would show their PHP code as plain text. Choose another PHP version, switch to LiteSpeed or OpenLiteSpeed, or install the LSAPI Engine,
  • a hosting plan already on such a version shows it marked PHP not available on this server, and the plan cannot be saved until you pick another version. See Server Application.

The note of GET /api/admin/php-versions follows the same rule.

Versions disabled in the PHP Selector ​

On a CloudLinux server, an alt-php version disabled in the CloudLinux PHP Selector in LVE Manager is not offered to hosting plans, domains, or clients. Since panel 1.9.4 it stays that way: before, loading this page or the PHP versions API could offer it again, because the version's package is still on the server. The update hides versions that were already offered again.

This page still shows such a version as installed, so you can configure or uninstall it, and GET /api/admin/php-versions reports it with is_installed true. A domain already on it keeps it and can still save its PHP settings. Moving a domain to it, or creating a domain on a plan that uses it, is refused with "PHP X.Y is disabled in the CloudLinux PHP Selector, so it cannot be chosen here. Nothing was changed. Enable it in LVE Manager under PHP Selector, or choose another PHP version."

Installing and uninstalling a version ​

Install on a card starts the installation and opens a window that follows the job until it ends, titled with the version, for example Installing PHP 8.4. Since panel 1.9.2, the log shows each step by its name, without the progress bar of the command that runs it. Close reloads the page. The version's default profile is applied when the installation completes.

Uninstall asks for confirmation first. When something still uses the version, the confirmation dialog (Uninstall PHP 8.4, for example) says so before you confirm, and names:

  • the domains the version is currently serving,
  • the domains assigned to it in the panel,
  • the hosting plans using it.

Reassign them to another version on the Domain Assignment tab and in the hosting plans first. If you confirm anyway, PHP version is in use names them again and nothing is removed. When Bolt Agent cannot be reached to check which domains run the version, the uninstall is refused with Cannot confirm this version is unused, because removing a version a live website runs on takes that website down.

Since panel 1.9.2, installing or uninstalling a REMI version applies or removes only the REMI default profile. The LSPHP and alt-php profiles of the same release stay as they are.

Configuring a PHP Version ​

Configure on an installed version opens the configuration page for that version, at /admin/php-versions/<id>/configure. That page sits outside the Settings area, so the Settings groups are replaced by a PHP Versions breadcrumb that takes you back.

Configuration page for an installed PHP version

PHP Profile ​

At the top, a PHP Profile dropdown allows selecting which configuration profile to edit (e.g., "PHP 8.4 - Default (default, php)"). An options menu (three dots) is available next to the profile selector.

Service Status ​

On a REMI version, which runs PHP-FPM, a status banner shows whether the PHP-FPM service is running, with a Check Service Status button. LSPHP and CloudLinux alt-php versions do not run PHP-FPM and have no banner.

Configuration Tabs ​

The configuration page is organized into three tabs: PHP Configuration, PHP-FPM Configuration (REMI versions only), and Extensions. Apply Configuration at the bottom of the page applies all of them at once; see Applying the configuration.

1. PHP Configuration ​

Contains Core PHP Directives with the following settings:

  • Memory Limit - Maximum memory a script may consume.
  • Upload Max Filesize - Maximum size of uploaded files.
  • Post Max Size - Maximum size of POST data.
  • Max Execution Time - Maximum time in seconds a script is allowed to run.
  • Max Input Time - Maximum time in seconds a script may spend parsing input data.
  • Max Input Variables - Maximum number of variables that can be accepted.
  • Error Reporting - Error reporting level.
  • Display Errors - Whether to display errors (toggle).
  • Display Startup Errors - Whether to display startup errors (toggle).
  • Log Errors - Whether to log errors (toggle).
  • Date Timezone - Default timezone.
  • Default Charset - Default character set.
  • Default Mime Type - Default MIME type.
  • File Uploads - Whether to allow HTTP file uploads (toggle).
  • Upload Tmp Dir - Temporary directory for uploaded files.
  • User INI Filename - Name of the file where user-defined INI settings can be set.
  • User INI Cache TTL - TTL for caching user INI files.
  • Variables Order - Order of variables.
  • Request Order - Order of request variables.
  • Register ARGC ARGV - Whether to register the argv and argc variables (toggle).
  • Auto Globals JIT - Whether to enable auto globals JIT (toggle).
  • Short Open Tag - Whether to allow the short-form <? tag (toggle).
  • Precision - Number of significant digits displayed in floating point numbers.
  • Output Buffering - Output buffering size.
  • Output Handler - Output handler to use.
  • Zlib Output Compression - Whether to transparently output pages with the text/html content-type (toggle).
  • Zlib Output Handler - Zlib output handler.
  • Implicit Flush - Whether to flush output buffers automatically (toggle).
  • Unserialize Callback Function - Callback function for unserialize.
  • Serialize Precision - Precision for serializing floating point numbers.
  • Disable Functions - Comma-separated list of functions to disable.
  • Disable Classes - Comma-separated list of classes to disable.
  • Zend Assertions - Zend assertions mode.
  • Zend Detect Unicode - Whether to detect Unicode (toggle).
  • Zend Enable GC - Whether to enable garbage collection (toggle).
  • Zend Multibyte - Whether to enable multibyte support (toggle).
  • Zend Script Encoding - Script encoding for multibyte support.

Since panel 1.9.0, the time zone, zlib, and Zend values of this form apply to the PHP version. Websites on alt-php and LSPHP keep PHP error messages from visitors by default, also on servers updated to 1.9.0; a domain's own error display setting still applies.

Since panel 1.9.3, the upgrade step that switches Display Errors and Display Startup Errors off for websites saves the new value for a PHP version only once the server runs it, so this form shows what visitors get. A version the server could not change keeps its setting, and the step is reported as failed on System Updates: it runs again with the next update, or when you run bolt-cli run-upgrade-steps --retry-failed, the command that page names.

Since panel 1.9.2, Implicit Flush reaches the server as well. Log Errors, File Uploads, Auto Globals JIT, Zend Detect Unicode, and Zend Enable GC are on in PHP by default: they show on until you turn them off, and turning one off now reaches the server.

2. PHP-FPM Configuration ​

Shown for REMI versions only. Contains PHP-FPM Global Settings:

  • PID File - Path to the PID file.
  • Error Log File - Path to the error log file.
  • Log Level - Log level for error log (dropdown: e.g., Notice).
  • Emergency Restart Threshold - Number of child processes that can die before restart.
  • Emergency Restart Interval - Time interval for emergency restart (e.g., 60s, 1m).
  • Process Control Timeout - Time limit for child processes to respond to signals.
  • Daemonize - Whether to daemonize the process (toggle).
  • RLimit Files - Maximum number of open files.
  • RLimit Core - Maximum core file size (unlimited or size).
  • Events Mechanism - Event mechanism to use (dropdown: e.g., epoll).
  • Systemd Interval - Interval for systemd status updates (seconds).
  • Include Path - Path to include additional configuration files.

3. Extensions ​

PHP extensions are grouped in sections. Each extension has a switch, and an extension's own settings appear once its switch is on.

  • Database Extensions - Enable PDO MySQL Extension, with the PDO MySQL default socket, user, password, host, and port, and Enable MySQLi Extensions, with MySQLi Allow Persistent, the persistent and link limits, and the MySQLi connection defaults.
  • String and Encoding Extensions - Enable MBString Extensions and Enable Intl Extensions, each with its settings.
  • Image Processing Extensions - GD JPEG Ignore Warning and, on CloudLinux alt-php versions that ship Imagick, the Imagick settings.
  • Caching Extensions - Redis, APCu, Memcached, OPcache, and Xdebug, each with its settings.
  • Other Extensions - a switch for every other extension the version offers.

A switch can be locked on, with the reason under it: Required by Redis for the extensions Redis needs while Redis is on, and Required by the PostgreSQL module for the PostgreSQL drivers while that module is installed.

Since panel 1.9.3, switching an extension off keeps its settings on the page. The server gets nothing for an extension that is off (for OPcache, only that it is off), and the settings come back when you switch the extension on again.

Extensions on LSPHP ​

Since panel 1.9.3, the extension switches of an LSPHP version switch the extension on and off on the server:

  • The page offers only the extensions installed for the version, as it does for alt-php, and leaves out a section with none of them.
  • An extension that another switched-on extension needs stays on, with Required by and the extensions that need it under the switch. For example, pdo and mysqlnd stay on while PDO MySQL is on.
  • When the agent did not report which extensions the version loads, the tab says so at the top and the switches are locked: Apply Configuration leaves the extensions as they are. Start or check the agent, then reload the page to change the extensions. On such a page, loading a profile does not apply its extension switches, and Save as New Profile is refused.

MySQLi Allow Persistent, GD JPEG Ignore Warning, Imagick Set Single Thread, APCu Enabled, Memcached Session Locking, and the OPcache switches Use CWD, Validate Timestamps, Save Comments, Load Comments, and Inherited Hack are on in PHP by default. Since panel 1.9.2, they show on until you turn them off, and turning one off reaches the server.

Extensions on CloudLinux alt-php ​

Since panel 1.9.2, a CloudLinux alt-php version offers only the extensions it ships, and a section with none of them is left out. When the panel cannot read which extensions the version ships, it offers the whole list. Every extension switch of an alt-php version now reaches the server; before, many of them were saved without changing what the websites loaded.

OPcache ​

Since panel 1.9.2, the OPcache settings reach the server on every kind of version. What OPcache Enable does depends on the version:

  • REMI - switches OPcache on or off. Until you set it, OPcache runs as the PHP package has it, which is on, and the switch shows on.
  • CloudLinux alt-php - loads or unloads the OPcache extension, as the other alt-php extension switches do. Until you turn it on, OPcache is not loaded.
  • LSPHP, and alt-php once it loads the extensions each account chooses in the PHP Selector - the page has no OPcache Enable. OPcache runs as the LSPHP package or the PHP Selector has it, and the other OPcache settings still apply. The Isolation Report has the step that switches alt-php to the PHP Selector's extensions.

The OPcache settings appear while OPcache Enable is on, or always where the page has no such switch.

Since panel 1.9.3, OPcache Optimization Level takes a decimal number or a hexadecimal one that starts with 0x, such as 0x7FFEBFFF.

Applying the configuration ​

Apply Configuration applies the three tabs to the server. Since panel 1.9.2, every setting on the PHP Configuration and Extensions tabs reaches the server, including Implicit Flush, the OPcache settings, and the Imagick settings, and the configuration is saved only once the server runs it:

  • When the server applies it, PHP Configuration Applied Successfully confirms it (LSPHP or Alt-PHP in place of PHP for those versions).
  • When the server refuses it, a notification titled Apply PHP configuration (or Apply LSPHP configuration, or Apply Alt-PHP configuration) gives the reason and the next step, and nothing is saved. The page and the API keep showing what the server runs, so the next save starts from there.
  • On CloudLinux alt-php, when the new PHP settings were applied but the extension changes were not, and the previous settings could not be put back, a warning says Only part of the change reached the server. Reload the page to see what the server uses now, then apply the extension changes again.

Since panel 1.9.3, after an LSPHP configuration is applied on LiteSpeed Enterprise or OpenLiteSpeed, or an alt-php configuration on LiteSpeed Enterprise, the PHP processes that still run with the previous configuration are ended. When some of them are still running, a warning titled Apply LSPHP configuration (or Apply Alt-PHP configuration) says how many; they switch over when they end, or apply the configuration again a few minutes later to end them. A value that contains a line break or another control character is refused under its field.

Since panel 1.9.2, saving a CloudLinux alt-php configuration also reloads the web server that serves alt-php, so the new settings take effect at once. On a REMI version, a change to Disable Functions or to the OPcache settings restarts the version's PHP-FPM service.

Settings saved before panel 1.9.2, also those held in profiles, carry over: they reach the server with the next save. Two kinds of switch are the exception, because their earlier value never reached the server: the earlier OPcache switch, so a REMI version keeps OPcache as the package has it until you set OPcache Enable, and a switch that is on in PHP by default but was turned off before 1.9.2, which shows on again. Turn it off and apply the configuration to switch it off on the server. A field the page leaves out for a version, such as an extension an alt-php version does not ship, is not sent to the server.

The administrator API ​

Since panel 1.9.1, PHP versions are on the administrator REST API under /api/admin/php-versions, so a server's PHP can be installed and configured from your own tooling. Authentication is the same as for the rest of the API. The API applies the same rules as this page and the configuration page, and a refusal says why.

Versions ​

Method and pathWhat it does
GET /api/admin/php-versionsThe versions this page lists, with the installed state read from the server first. Filter with source (remi, alt for CloudLinux Alt-PHP, or lsphp) and installed (true or false). Each version carries can_install and can_remove, with an install_refusal or remove_refusal when not, and running_job_id for a job still under way. Since panel 1.9.2, note says so on an installed LSPHP version that no web server can run now, and is null otherwise. installed_state_confirmed is false when the server could not be asked, and the flags are then the last known ones.
GET /api/admin/php-versions/{id}One version, with its usage: the domains served by it, the domains that only have it on record, and the hosting plans that assign it. Since panel 1.9.2, the domains served by it are those of this build only, not of another repository's build of the same release.
POST /api/admin/php-versions/syncRe-read which versions are installed, as opening this page does. Use it after installing PHP outside the panel.
POST /api/admin/php-versions/{id}/installStart the install this page runs. Answers 202 with the job_id and the poll and log addresses. The default profile is applied when the install completes.
DELETE /api/admin/php-versions/{id}Start the removal. Answers 202 with the job, as install does.
GET /api/admin/php-versions/jobs/{jobId}The state of an install or removal: running, completed, failed, or unconfirmed when the server stopped answering about the job. Once it has finished, php_version is the version read again, so is_installed says whether the change happened. A failure carries an error and a correlation_id to quote to support.
GET /api/admin/php-versions/jobs/{jobId}/logThe lines this page shows while it waits, with their level (info, success, warning, or error). Since panel 1.9.2, a step line holds the step's name without a progress bar.

A refused request answers 409 with a refusal object, a code and a message that gives the reason. can_install and can_remove, with install_refusal and remove_refusal, show beforehand whether a request would be accepted.

Jobs started on this page can be followed through the API too. An unknown job id answers 404.

PHP-FPM settings for all accounts ​

Since panel 1.9.4, GET /api/admin/php-fpm/global-settings reads the PHP-FPM settings for all accounts, for every version (default) or for one installed version, and PATCH saves the settings sent, as Save Changes does for All Accounts. A setting left out keeps its value. As on the page, saving stores the values only: running PHP-FPM pools are not changed by the save.

Configuration ​

Method and pathWhat it does
GET /api/admin/php-versions/{id}/configurationWhat the configuration page shows: the stored configuration (ini, fpm, extensions, and the extra.enable_<name>_extension toggles), the extensions the version offers with their state, and the lowest and highest value of each numeric field. sections says which parts apply: fpm only where the version runs PHP-FPM, so not for LSPHP or CloudLinux Alt-PHP. connected is false until the default profile is installed.
PUT /api/admin/php-versions/{id}/configurationWhat Apply Configuration does. Send only what changes, for example {"ini": {"memory_limit": "512M"}} or {"extra": {"enable_xdebug_extension": true}}. The change is checked with the page's own rules and applied to the server before the call answers.
POST /api/admin/php-versions/{id}/configuration/default-profileInstall the version's default profile and apply it. On a version already set up, this is the way back to the defaults.

What to expect from a change:

  • Send the settings as GET returns them under configuration. A change the panel cannot accept answers 422 naming the field.
  • An extension that another part of the server needs stays on. A request to turn it off is overridden, and required_by on the extension says why. Since panel 1.9.3, required_by also names the LSPHP extensions that need it, and the answer to PUT lists the extensions kept on in kept_on, each with its required_by.
  • A refused change answers 409 with a message that gives the reason.
  • When the server does not apply the change, the call answers 502 with a correlation_id, and the stored configuration is left as it was. Since panel 1.9.3, the 502 also carries a next_step. When only part of an alt-php change went through, the call also answers 502, and the stored configuration holds what the server now runs: read it again with GET.

Since panel 1.9.2:

  • GET returns the extra.enable_<name>_extension toggles of the extensions the version offers only, and every switch that is on in PHP by default at its default where it was never set, so what GET returns can be sent back as it is.
  • On a CloudLinux alt-php version, a toggle for an extension of the list that the version does not ship is accepted when it switches the extension off or keeps the stored value, and answers 422 naming the field when it would switch the extension on.
  • On LSPHP, and on alt-php once it loads the extensions each account chooses in the PHP Selector, GET leaves extensions.opcache.enable out and a change to it answers 422; the other OPcache settings apply. Elsewhere extensions.opcache.enable can be set to true or false, also before it was first set.
  • implicit_flush is still accepted at the top level of the body, as before, and is applied and stored as ini.implicit_flush.

Since panel 1.9.3:

  • GET adds extension_state_known, which is false when the agent did not report which extensions the version loads. The extension switches cannot be changed then.
  • The answers to PUT and to applying a profile add php_processes, with how many PHP processes were found, signalled, ended, and are still_running, and a warning while some are still running.
  • A value with a line break or another control character answers 422 naming the field.

Profiles ​

Method and pathWhat it does
GET /api/admin/php-versions/{id}/profilesThe profiles the PHP Profile menu lists for this version.
POST /api/admin/php-versions/{id}/profilesSave as New Profile: save the stored configuration under a name, with optional tags. A profile of the same name for this version is overwritten.
PUT /api/admin/php-versions/{id}/profiles/{profileId}Save Profile: the stored configuration replaces what the profile held. Nothing is applied to the server.
GET /api/admin/php-versions/{id}/profiles/{profileId}Download Profile: the profile with its payload, in the form import accepts.
POST /api/admin/php-versions/{id}/profiles/importLoad Profile: a new profile from an exported document, under a new name. Nothing is applied to the server.
DELETE /api/admin/php-versions/{id}/profiles/{profileId}Delete Profile.
POST /api/admin/php-versions/{id}/profiles/{profileId}/applyApply the profile: it becomes the version's configuration and is applied to the server before the call answers.

The shipped default profile (is_system is true) cannot be changed or deleted. A refused request answers 409, or 422 for a profile that holds values the page would refuse, with a message that gives the reason. The REMI, Alt-PHP, and LSPHP builds of one release keep separate profiles.