Below is a guest post by Desiree at OrcsWeb with an IIS/PHP/CGI troubleshooting tip:

I installed WordPress for one of our managed clients recently, and what should have been a simple install, turned into quite a bit of troubleshooting. The client was running Windows Server and using IIS for their site hosting. Before starting the WordPress install I confirmed that the server showed PHP was previously installed and configured.

After the install, the site wouldn’t load and returned the error below:

HTTP Error 500.21 - Internal Server Error
Handler "PHP54_via_FastCGI" has a bad module "FastCgiModule" in its module list

Detailed Error Information
 Module    IIS Web Core
 Notification    ExecuteRequestHandler
 Handler    PHP54_via_FastCGI
 Error Code    0x8007000d
 Requested URL

Physical Path    C:\Data\\wp-admin\setup-config.php
 Logon Method    Anonymous
 Logon User    Anonymous
 Failed Request Tracing Log Directory    C:\inetpub\logs\FailedReqLogFiles

The problem is that the error isn’t very clear. After some troubleshooting and research I figured that to resolve the issue I would need to either install CGI or remove and then reinstall CGI. The server showed that CGI was already installed, but perhaps it wasn’t installed properly? As part of continued troubleshooting, I removed and then reinstalled CGI. The application still didn’t work and was now showing the following error:


If this happens, it is because the removal of CGI removes the registration in PHP Manager. In IIS, open PHP Manager. Click on “Register new PHP version” task and then provide the full path to the location of the main PHP executable file: php-cgi.exe (i.e., C:\Program Files (x86)\PHP\v5.4\php-cgi.exe).

After those changes, we reloaded the site and everything worked properly.

If you run into a similar issue getting PHP and CGI (and perhaps specifically WordPress) working on your IIS server, I hope this helps!

Be Sociable, Share!
    Handler "PHP5x_via_FastCGI" has a bad module "FastCgiModule" in its module list
    Tagged on:             

    One thought on “Handler "PHP5x_via_FastCGI" has a bad module "FastCgiModule" in its module list

    • July 4, 2013 at 7:30 am

      Hey Brad-

      Your last post [Handler “PHP5x_via_FastCGI” has a bad module “FastCgiModule” in its module list] was freaking awesome. I have gone ahead and added your stuff to my Feedly account. Please keep me updated if you post anywhere else.

      Keep rocking –


    Comments are closed.