×



















    Get a Free Consultation

    Search for:

    How to Configure FastCGI with XAMPP on windows for Magento 2

    Last Updated | July 27, 2023

    Introduction:

    If you are having trouble-configuring FastCGI on Xampp or you are a Xampp user and you want additional performance on windows using Xampp, this is the right place to be. I am going to show you how you can achieve this step-by-step.

    Magento development

    Configuring FastCGI with Xampp on Windows

      1. Download and Extract: http://www.apachelounge.com/download/VC11/modules/modules-2.4-win64-VC11.zip
      2. Copy “mod_fcgid.so” binary file from the extracted folder in “C:\xampp\apache\modules” directory.
      3. Download latest PHP binary folder: https://windows.php.net/download/ [non-thread-safe(nts) version].
      4. Create a folder “C:\XXamp” and extract the above PHP binary in this folder, renaming it to anything(in my case ‘2‘ which makes it C:\XXamp\php7.2)
      5. Open: C:\xampp\apache\conf\extra\httpd-xampp.conf and disable mod_php by commenting the lines below:

    # PHP-Module setup
    #
    #LoadFile "C:/xampp/php/php7ts.dll"
    #LoadFile "C:/xampp/php/libpq.dll"
    #LoadModule php7_module "C:/xampp/php/php7apache2_4.dll"
    #
    #<FilesMatch "\.php$">
    # SetHandler application/x-httpd-php
    #
    #<FilesMatch "\.phps$">
    # SetHandler application/x-httpd-php-source

    Add these lines under the above section(in order to enable FastCGI):

    # PHP-FastCGI setup
    LoadModule fcgid_module modules/mod_fcgid.so
    #
    FcgidInitialEnv PATH "C:/XXamp/php7.2;C:/WINDOWS/system32;C:/WINDOWS;C:/WINDOWS/System32/Wbem;"
    FcgidInitialEnv SystemRoot "C:/Windows"
    FcgidInitialEnv SystemDrive "C:"
    FcgidInitialEnv TEMP "C:/XXamp/tmp"
    FcgidInitialEnv TMP "C:/XXamp/tmp"
    FcgidInitialEnv windir "C:/WINDOWS"
    FcgidIOTimeout 64
    FcgidConnectTimeout 16
    FcgidMaxRequestsPerProcess 1000
    FcgidMaxProcesses 3
    FcgidMaxRequestLen 8131072
    # Location php.ini:
    FcgidInitialEnv PHPRC "C:/XXamp/php7.2"
    FcgidInitialEnv PHP_FCGI_MAX_REQUESTS 1000
    #
    Options Indexes FollowSymLinks ExecCGI
    AddHandler fcgid-script .php
    FcgidWrapper "C:/XXamp/php7.2/php-cgi.exe" .php
    #
    AddType application/x-httpd-php .php
    AddType application/x-httpd-php .php3

        1. Copy your php.ini file from “C:\xampp\php” to “C:\XXamp\php7.2” and open it
        2. Change the extension_dir path to “C:\XXamp\php7.2\ext” for the extensions to be loaded near the configurations where it resides
        3. Finally, restart apache and verify that the Server API is set to “CGI/FastCGI”

    Note: You have to change this “C:\XXamp\php7.2” path in the above configurations to the one you choose.

    Magento integration

    FAQs:

    Does Folio3 provide Magento Development Services?

    Yes, Folio3 provides Magento development services. Folio3 is a software development company that specializes in providing eCommerce solutions, including Magento development. Their team of certified Magento developers can help you build, customize, and optimize your Magento store to meet your unique business requirements. Folio3 offers a range of Magento development services, including custom Magento development, Magento theme development, Magento integration, Magento migration, and Magento maintenance and support.

    Custom Shopify B2B app vs. Magento B2B Solution: Which is best by Customer Support?

    With Magento, there is phone support available at limited time slots. However, to be able to access official support, one has to pay extra costs for the premium plan. On the other hand, Shopify provides free customer support from the customer success manager. Besides, Shopify offers 24/7 support. That being said, Shopify definitely offers one of the best customer support of all web development platforms.


    folio-social-logo
    About