Why the PHP Version Isn’t Updating on Your Server

I had a situation where I updated the PHP version in cPanel from 7.3 to 8.0, but on the actual server it was still at 7.3. No matter what I did in cPanel, the PHP version wouldn’t change on my actual server!

I called up the host, GoDaddy, and they quickly found the problem. It wasn’t their fault at all, but rather a line of code in my the .htaccess file in the root of my site.

Why the PHP Version Isn’t Changing

The culprit was the first line in my .htaccess file, which was this:

AddHandler application/x-httpd-alt-php73___lsphp .php

That line was forcing this directory and everything under to run PHP 7.3! Commenting out that line immediately fixed the problem!

Note that any directory could have this directive in its .htaccess file, so you may want to do a search for it.

Of course, you should also investigate why someone added that line in the first place, but at least you can start that process now.

I hope this was helpful, and many thanks to GoDaddy support for figuring that out! – Brian


Please Leave a Question or Comment

Notify of

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Inline Feedbacks
View all comments