Skip to content
How to Change PHP Version in cPanel & DirectAdmin (CloudLinux Guide)

How to Change PHP Version in cPanel & DirectAdmin

This guide shows you how to change your PHP version using CloudLinux. Switching PHP versions can fix compatibility issues, improve performance, and resolve errors with WordPress themes or plugins.

Easy Difficulty
2–3 min Time
CloudLinux Required

Why Change PHP Version?

Fix Website Errors

Resolve issues caused by outdated or unsupported PHP versions.

Improve Performance

Newer PHP versions are faster and more efficient.

Plugin Compatibility

Some plugins/themes require specific PHP versions.

Security Updates

Newer versions include important security fixes.

Step-by-Step

Login
Select PHP
Choose Version
Save

Change PHP Version in cPanel

Step 1: Open Select PHP Version

Go to Software → Select PHP Version in cPanel.

Step 2: Choose PHP Version

Select your desired PHP version from the dropdown (e.g. 8.1, 8.2, 8.3).

Step 3: Set as Current

Click Set as Current to apply the version.

Step 4: Verify Website

Visit your website to ensure everything is working correctly.

Change PHP Version in DirectAdmin

Step 1: Open Select PHP Version

Go to Account Manager → Select PHP Version.

Step 2: Choose PHP Version

Select your preferred PHP version from the list.

Step 3: Save Changes

Click Save or Set as Current.

Step 4: Test Website

Check your site to confirm everything is working.

Recommended PHP Versions

PHP 8.2 / 8.3

Recommended for most modern WordPress websites.

PHP 8.1

Good fallback if compatibility issues occur.

Avoid Older Versions

PHP 7.x is outdated and less secure.

Common Issues & Fixes

Website Broken After Change

Switch back to the previous PHP version and update plugins/themes.

Extensions Missing

Enable required PHP extensions after switching version.

Enable Extensions

Still Not Working

Check error logs or contact support.

Related Guides

Enable PHP Extensions

Enable required PHP modules.

View Guide

Resource Limit Reached

Fix CloudLinux resource issues.

View Guide

Clear Cache

Fix updates not showing.

View Guide
← Back to Troubleshooting