How to Install, Upgrade PHP Version & Customize PHP Settings With xCloud Hosting?

Updated November 26, 2026 · 7 min read

Summarize with:
Share:

To upgrade PHP in xCloud, install the new version on your server under Management → Manage PHP, then switch each site to it under Site Settings → PHP Configurations. You don’t have to edit any server files or run commands on Ubuntu. A security patch such as PHP 8.3.36 is different: it updates the version you already run, with one click from the same Manage PHP page, and your sites stay on PHP 8.3.

PHP 8.6 is now available on NGINX servers. Start testing your sites, plugins and themes on a staging site: see how to use PHP 8.6 on xCloud.

Choosing a host for a custom PHP app? The cloud PHP hosting page shows the PHP versions and tools you can use on xCloud.

This guide covers each job in order:

You want to Where in xCloud Section
Add a PHP version to the server Server → Management → Manage PHP → Install Step 1
Pick the version new sites use Manage PHP → Set As Default Step 2
Move a site to a newer PHP version Site → Site Settings → PHP Version Step 3
Change limits or turn on OPcache Manage PHP → three-dot menu, OPCache toggle Step 4
Install a patch such as 8.3.36 Manage PHP → Scan Patch → Update to Step 5
Remove a version no site uses Manage PHP → three-dot menu → Uninstall Step 6

PHP Configuration for Server

If you want to keep default settings for your server so that all sites created under it use the same configuration, you can set a default PHP configuration for that server. When a site is created under that server, it will automatically use those settings.

Step 1: Install a PHP Version

First, go to your Server from the xCloud dashboard. Then navigate to the ‘Management’ →‘Manage PHP’ to access all the available PHP versions and manage them easily.

Open Management → Manage PHP on the server

Under the ‘PHP Configuration’ tab you see every PHP version your server can install. Click ‘Install’ in the row of the version you want, for example PHP 8.4. When the install finishes, the version shows ‘Installed’ in the ‘Status’ column.

Click Install beside PHP 8.4 on the Manage PHP page

The list depends on your server’s Ubuntu version and web server. See why your Ubuntu version decides which PHP you can install below.

Step 2: Set a Default PHP Version

Next, to make an installed PHP version the server’s default, click ‘Set As Default’ in its row. New sites on this server then use that version unless you pick another one when you create the site. Existing sites keep their own version.

Click Set As Default beside an installed PHP version

👉 You can also install, patch or set the default PHP version from chat: see how to manage PHP and Node.js with the xCloud AI Assistant.

Step 3: Switch a Site to the New PHP Version

Installing a version on the server does not move any site to it. Each site keeps its own PHP version until you change it, so you can upgrade one site at a time.

  1. Open the site and click ‘Site Settings’ in the left menu.
  2. In the ‘PHP Configurations’ card, choose the new version in the ‘PHP Version’ list, for example PHP 8.4.
  3. Click ‘Save Settings’ at the top of the card.

Choose PHP 8.4 in the PHP Version list under Site Settings, then click Save Settings

You see ‘PHP Settings updated successfully’, and the change takes a short while to apply. If the version you picked is not installed on the server yet, xCloud installs it first and then switches the site. Afterwards, check the limits under ‘Current settings for PHP 8.x’ in the same card, because each PHP version keeps its own settings.

The card also tells you when a site needs attention:

  • ‘PHP 8.x is supported and gets security fixes.’ means the site’s version is still maintained by the PHP project.
  • ‘PHP 8.x no longer gets security fixes’ appears on an end-of-life version, such as PHP 8.1 or older. Click the ‘Choose PHP 8.x’ button it shows, then ‘Save Settings’. If the server can’t install a newer version (for example on Ubuntu 20.04), the card links to ‘Clone this site to a newer server’ instead. End-of-life versions are also marked ‘(End of life)’ in the list.
  • ‘A newer build with security fixes is ready’ means a patch is waiting for this version on the server. Install it as shown in Step 5.

If the site breaks after the switch, choose the old version in the same list and click ‘Save Settings’ again. To avoid downtime, try the new version on a staging site first and switch the live site only when everything works.

Before you upgrade a WordPress or custom PHP application to PHP 8.3 or newer

The server side of an upgrade is the few clicks above. The real work, and most of the cost of moving an older custom PHP application to PHP 8.3, is checking that your own code and its packages run on the new version. Check these first:

  • Plugins, themes and packages. Update WordPress plugins and themes, or run composer update for a custom app, and check that each one supports the PHP version you want. For a Composer project, the require → php line in composer.json must allow it.
  • PHP extensions. An extension you added by hand must be installed for the new version too. See how to manage PHP extensions.
  • A staging copy. Switch the staging site first, click through the pages that matter, and watch the site’s error log.
  • Deploys. If you deploy the site from Git, run a test deploy on staging after the switch.

Step 4: Configure PHP Settings and OPcache

You can now easily customize your PHP as well. Just click on the three dot icon beside the version you have installed or set as default or want to configure. The following options can be modified:

  1. Max Execution Time
  2. Max Input Time
  3. Memory Limit
  4. Max File Upload Size
  5. Max Input Vars
  6. Post Max Size
  7. Session GC Maxlifetime

Customize the options according to your preferences and click on the ‘Save Changes’ button.

PHP settings form for an installed version with the Save Changes button

These are the server’s settings for that PHP version. To change limits for one site only, use the ‘Edit’ buttons in its ‘PHP Configurations’ card, as explained in how to configure PHP settings of your site.

Enable OPCache

Enabling OPcache can significantly improve the efficiency of your PHP applications. To enable it, turn on the toggle in the ‘OPCache’ column of the version’s row.

Turn on the OPCache toggle in the row of an installed PHP version

Note: The OPCache toggle works for every installed PHP version, including PHP 8.5.

Step 5: Install PHP Security Patches

When PHP publishes a security release, you get it as a patch for the PHP version you already run, for example 8.3.35 → 8.3.36. Your sites stay on the same PHP version, so you don’t need to switch versions or change any site settings. xCloud checks every installed PHP version for a newer patch and lets you install it with one click.

When a critical PHP security patch is ready for a server, your To-Do list also shows a card that says A PHP security patch is needed, with a Fix button. See the PHP security patch card in the To-Do Center.

Check for patches. On the ‘Manage PHP’ page, xCloud checks for patches automatically when you open it, if the last check was more than 24 hours ago. To check right away, click ‘Scan Patch’ at the top right. ‘Last checked’ next to the button shows when the last scan ran. A scan refreshes the server’s package lists first, so it can take a minute.

Last checked time and the Scan Patch button on the Manage PHP page

Install a patch. When a patch is available, the ‘Patch’ column shows the installed version and the new one, for example 8.3.35 → 8.3.36. A dash means no newer build is available for your server. On Ubuntu 22.04 or newer, that means the version is up to date. On Ubuntu 20.04, it means no more patches are published for that server at all, so a dash there does not mean patched. See why your Ubuntu version decides which PHP you get.

Patch column showing PHP 8.3.35 with an available patch to 8.3.36

To install it:

  1. Click the three dot icon in the row of the PHP version that has a patch.
  2. Click ‘Update to 8.3.36’ (the version number matches the patch shown).
  3. Click ‘Yes, Update!’ to confirm.

Action menu with the Update to 8.3.36 option

Confirmation dialog asking to update PHP 8.3.35 to 8.3.36 with the Yes, Update! button

The update runs in the background and takes a few minutes. When it finishes, you see ‘PHP 8.3 updated successfully’ and the ‘Patch’ column shows a dash again. The ‘Version’ column then shows the full release, such as PHP 8.3.36. Repeat the steps for each installed PHP version that shows a patch.

PHP 8.3 updated successfully notification, with the Patch column back to a dash

Patching happens per server: one update covers every site on that server that uses that PHP version. If you manage several servers, patch each one.

During the update, xCloud upgrades the PHP packages for that version and the extensions it installed with it, then reloads NGINX or OpenLiteSpeed. PHP restarts as part of the upgrade, so on busy sites choose a quiet time.

Note: Patches work the same way on NGINX and OpenLiteSpeed servers. A patch appears only after the package repository publishes the new build (Ondřej Surý’s PHP packages on NGINX, LiteSpeed’s own PHP packages on OpenLiteSpeed). This can take a few hours or more after a release on php.net, and the two stacks don’t always get it at the same time. If nothing shows right after an announcement, click ‘Scan Patch’ again later.

Install PHP Patches Automatically

By default, a server’s automated security updates install Ubuntu’s security updates, not PHP patch releases. To have the server install PHP patches on its own:

  1. Go to your server and open ‘Security’ → ‘Security Update’.
  2. Turn on ‘Managed Service Updates’.
  3. Pick an ‘Update Time’ and click ‘Save Settings’.

The server then installs patch releases for the services xCloud installed, including PHP, once a day at that time. The ‘Components on this server’ list on the same page shows each service and whether it is up to date. Services restart when they update, so choose a quiet time for your sites. You can still install an urgent patch immediately with ‘Scan Patch’ and ‘Update to’.

To learn more about automated updates, read How Automated Security Updates and Auto Reboot Work in xCloud.

Step 6: Uninstall PHP Versions You No Longer Use

Every PHP version installed on a server needs its own security patches, even if no site uses it. Old, unused versions, especially end-of-life ones such as PHP 8.1, 8.0 or 7.4, add risk and nothing else. Removing them leaves fewer versions to keep patched.

  1. Go to your server and open ‘Management’ → ‘Manage PHP’.
  2. On the version you want to remove, click the three-dot icon and choose ‘Uninstall’.
  3. Confirm with ‘Yes, Uninstall!’. This cannot be undone. You can install the version again later from the same page, as long as your server’s Ubuntu version still offers it (see the PHP versions compatibility table). On Ubuntu 20.04, only PHP 7.4 can be installed again.

Uninstall an unused PHP version from the Manage PHP menu

Confirm with Yes, Uninstall!

xCloud only uninstalls a version that nothing depends on:

  • Sites still use it? xCloud shows a ‘Sites Using PHP’ list instead of uninstalling. Switch those sites to a supported version first, as shown in Step 3, then try again.
  • It’s the server’s default? Set another version as the default (Step 2) before uninstalling it.
  • PHP 8.3 can’t be uninstalled for now while a compatibility issue is being fixed.

Sites Using PHP list shown when sites still use the version

Tip: before you uninstall an old version, move its sites to PHP 8.3 or newer and test them on a staging site first.

Currently Supported PHP Version in xCloud Hosting

xCloud runs PHP 5.6 up to PHP 8.5, and one server can run several versions side by side. New sites use PHP 8.3 unless you pick another version or set a different server default. The full list for each setup is in the PHP version compatibility table.

PHP versions for NGINX servers

An NGINX server on Ubuntu 22.04 or 24.04 can install every version from PHP 5.6 to 8.5. On Ubuntu 26.04, it offers PHP 8.2 to 8.5.

PHP versions for OpenLiteSpeed servers

OpenLiteSpeed servers use LiteSpeed’s own PHP builds and offer a shorter list: PHP 7.4 to 8.5 on Ubuntu 22.04 x64, PHP 7.4 and 8.1 to 8.5 on Ubuntu 22.04 ARM, PHP 8.1 to 8.5 on Ubuntu 24.04 x64, PHP 8.2 to 8.5 on Ubuntu 26.04 x64, and PHP 8.3 to 8.5 on ARM servers with Ubuntu 24.04 or 26.04. The compatibility table shows which versions each Ubuntu version and CPU type can install.

Why your Ubuntu version decides which PHP you can install

xCloud installs PHP from package repositories that build PHP for each Ubuntu version (Ondřej Surý’s on NGINX, LiteSpeed’s on OpenLiteSpeed), so the server’s Ubuntu version limits what Manage PHP offers. This is how PHP packaging works on Ubuntu, not an xCloud setting. A server on Ubuntu 20.04 only offers PHP 7.4, plus versions that are already installed, and gets no new PHP patches on NGINX.

To get a newer PHP version on an old server, create a new server on Ubuntu 24.04 or 26.04 and move your sites with full server clone. You can add freshly installed Ubuntu 22.04, 24.04 or 26.04 LTS x64 servers from any provider to xCloud, with full support for both NGINX and OpenLiteSpeed. Ubuntu 20.04 servers are no longer accepted.

If your sites are still on a host where you can’t pick the PHP version, our free website migration lets you move WordPress sites to an xCloud server at no cost, and managed WordPress hosting lets you switch PHP for each site from the dashboard.

Frequently asked questions

How do I upgrade a site to a newer PHP version in xCloud?

Open the site, go to Site Settings, choose the new version in the PHP Version list under PHP Configurations, and click Save Settings. If that version is not installed on the server yet, xCloud installs it first. Test the site on a staging copy before you switch the live site.

Do I need to change my site’s PHP version to get a PHP security patch?

No. A security patch is a newer release of the same PHP version, for example 8.3.35 to 8.3.36. Your sites stay on the version they use now. Install the patch from Management → Manage PHP on the server.

Are PHP security patches installed automatically?

Not by default. Automated security updates install Ubuntu’s security updates. To have the server install PHP patch releases on its own, turn on ‘Managed Service Updates’ under Security → Security Update on the server.

Does PHP patching work on OpenLiteSpeed servers?

Yes. The Scan Patch button, the Update action and the automatic option work on both NGINX and OpenLiteSpeed servers. OpenLiteSpeed servers use LiteSpeed’s own PHP packages, so a patch can appear there at a different time than on NGINX servers.

Why doesn’t a patch show up right after PHP announces a release?

xCloud installs PHP from package repositories, and a patch appears only after the repository publishes the new build. This can take a few hours or more after the release on php.net. Click ‘Scan Patch’ again later.

Should I remove PHP versions I no longer use?

Yes. Every installed PHP version needs its own security patches, so an unused version is extra work and extra risk. Go to Management → Manage PHP, open the three-dot menu on the version, and choose Uninstall. xCloud blocks the uninstall while any site still uses that version.

Why can’t I uninstall a PHP version?

xCloud does not uninstall a version that is the server’s default or that any site still uses. Switch those sites to another version and set a different default first. PHP 8.3 uninstall is also temporarily unavailable while a compatibility issue is fixed.

If you run into any issues, feel free to reach out to our support team.