PHP Error 500 - Cannot start php-cgi.exe - MSVCR110.dll is missing - How to fix

php-cgi.exe - The FastCGI process exited unexpectedly error and how to fix it

Installing PHP on a Windows machine is quite simple, expecially if you rely on the official setup packages or (even better, if you're using IIS) the great PHP Manager tool available through the Web Platform Installer, which we already mentioned here.

However, as soon as you install it and try to execute your first php page, it's very common to be struck with a 500 error. They can be quite different depending on your script, but the most common ones are this one:

and this one:

If you're experiencing the former, we already talked about quite some time ago: the latter can sound different, but the cause (and thus the fix) is basically the same. You need to install Visual C++ Redistributable for Visual Studio 2012 Update 4 (or newer): when you do that, be sure to get the x86 / 32-bit version, even if you have a 64-bit operating system: you need to install the 32-bit version because PHP is still a 32-bit application.

Here's the download link: http://www.microsoft.com/en-us/download/details.aspx?id=30679

Once you install that, you'll be good to go.

UPDATE: Since the launch of the x64, experimental version of PHP 5.6 (and above) this post requires the following update: if you're using an 64-bit PHP build, you have to install the 64-bit Visual C++ package, available through the same download link mentioned above. As the two packages can coexist without hassles, our suggestion for 64-bit based installations is to install both as long as x64 PHP builds will be marked as "experimental", so you'll be able to switch back to the x86 version whenever you need to.

 

About Ryan

IT Project Manager, Web Interface Architect and Lead Developer for many high-traffic web sites & services hosted in Italy and Europe. Since 2010 it's also a lead designer for many App and games for Android, iOS and Windows Phone mobile devices for a number of italian companies. Microsoft MVP for Development Technologies since 2018.

View all posts by Ryan

Leave a Reply

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.

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