The error "Your PHP version does not meet the Bitrix requirements" occurs when the installed PHP version does not match the required version for Bitrix CMS (Bitrix24). This can happen if:
First, diagnose which PHP versions are running in different environments.
# Create in your Bitrix root directory
sudo nano /home/user/public_html/phpinfo.php
Add this single line:
<?php phpinfo(); ?>
Save (Ctrl+O, Enter, Ctrl+X) and access via browser:
http://yourdomain.com/phpinfo.php
Look for the PHP version at the top and scroll to see installed extensions. Important: Delete this file after checking:
sudo rm /home/user/public_html/phpinfo.php
php -v
systemctl status php7.4-fpm # Check specific version
ls /etc/php/ # List all installed PHP versions
If your PHP version is incompatible, install a supported version for Bitrix.
# Add the Ondrej Sury PHP repository (has multiple versions)
sudo apt install software-properties-common -y
sudo add-apt-repository ppa:ondrej/php -y
sudo apt update
# Install PHP 7.4 (recommended for Bitrix)
sudo apt install php7.4 php7.4-fpm php7.4-cli -y
# Set PHP 7.4 as default for CLI
sudo update-alternatives --set php /usr/bin/php7.4
# Install PHP 8.0 if needed
# sudo apt install php8.0 php8.0-fpm php8.0-cli -y
# Enable EPEL and Remi repositories
sudo yum install epel-release yum-utils -y
sudo yum install http://rpms.remirepo.net/enterprise/remi-release-7.rpm -y
# Enable PHP 7.4 repository
sudo yum-config-manager --enable remi-php74
# Install PHP 7.4
sudo yum install php php-fpm php-cli -y
# Install PHP 8.0 if needed
# sudo yum-config-manager --enable remi-php80
# sudo yum install php80 php80-php-fpm php80-php-cli -y
# For Apache
sudo systemctl restart apache2
# For Nginx
sudo systemctl restart nginx
# For PHP-FPM
sudo systemctl restart php7.4-fpm
If your server has multiple PHP versions, configure your web server to use the correct one for Bitrix.
# Install Apache PHP module
sudo apt install libapache2-mod-php7.4
# Disable other PHP modules
sudo a2dismod php8.0 php8.1 php8.2
# Enable PHP 7.4 module
sudo a2enmod php7.4
# Restart Apache
sudo systemctl restart apache2
# Edit Apache virtual host configuration
sudo nano /etc/apache2/sites-available/your-site.conf
# Add or modify within VirtualHost section
<FilesMatch "\.php$">
SetHandler "proxy:unix:/run/php/php7.4-fpm.sock|fcgi://localhost/"
</FilesMatch>
# Edit Nginx site configuration
sudo nano /etc/nginx/sites-available/your-site
# Update the PHP location block
location ~ \.php$ {
fastcgi_pass unix:/run/php/php7.4-fpm.sock;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
# Test configuration and restart
sudo nginx -t
sudo systemctl restart nginx
sudo nginx -t to test Nginx configuration before restarting, and sudo apache2ctl configtest for Apache.
Bitrix requires specific PHP extensions. Install them for your PHP version.
sudo apt install php7.4-common php7.4-mysql php7.4-mbstring php7.4-xml php7.4-json \
php7.4-curl php7.4-gd php7.4-bcmath php7.4-zip php7.4-intl php7.4-soap php7.4-imagick -y
sudo yum install php-common php-mysqlnd php-mbstring php-xml php-json \
php-curl php-gd php-bcmath php-zip php-intl php-soap php-pecl-imagick -y
# Check loaded extensions
php -m | grep -E "mysql|mbstring|xml|json|curl|gd|bcmath|zip|intl|soap"
# Check via web (create temporary file)
echo "<?php print_r(get_loaded_extensions()); ?>" > /tmp/ext_check.php
php -f /tmp/ext_check.php | grep -E "mysql|mbstring|xml"
rm /tmp/ext_check.php
# Edit php.ini
sudo nano /etc/php/7.4/fpm/php.ini # For PHP-FPM
sudo nano /etc/php/7.4/apache2/php.ini # For Apache
# Ensure these lines exist (uncommented)
extension=mysqli.so
extension=mbstring.so
extension=xml.so
extension=curl.so
extension=gd.so
extension=zip.so
extension=intl.so
# Restart PHP processor
sudo systemctl restart php7.4-fpm # or apache2
mbstring and xml are critical for Bitrix. Missing them will cause the PHP version error even if the version number is correct.
| Issue | Solution |
|---|---|
| Wrong PHP version | Install compatible PHP (7.4 recommended): sudo apt install php7.4 |
| Different PHP version in CLI & Web | Run update-alternatives --set php /usr/bin/php7.4 and configure web server |
| Incorrect PHP for Apache/Nginx | Update SetHandler (Apache) or fastcgi_pass (Nginx) to correct PHP version socket |
| Missing PHP extensions | Install required extensions: mbstring, xml, zip, curl, gd, mysqlnd, bcmath, intl |
| Multiple PHP versions causing conflict | Disable unused PHP modules: a2dismod php8.0 php8.1 (Apache) |
| Bitrix still showing error after fixes | Clear Bitrix cache: Admin Panel > Settings > Clear Cache |
| PHP-FPM not running | Start service: systemctl start php7.4-fpm and enable: systemctl enable php7.4-fpm |
With the correct PHP version and all required extensions installed, Bitrix should no longer show the PHP version error and will run optimally!