.htacces file in azure web app

Mamadou Oury BARRY 50 Reputation points
2023-08-07T18:45:15.29+00:00

How i can configure my htacess file in side web app on azure. i try before the suggest to me to try getway or window server iis. please i hope you will help me. thank.

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,935 questions
{count} votes

1 answer

Sort by: Most helpful
  1. VenkateshDodda-MSFT 24,951 Reputation points Microsoft Employee Moderator
    2023-08-08T06:25:41.76+00:00

    @Mamadou Oury BARRY Thank you for reaching out to Microsoft Q&A.

    I understand that you want to configure htaccess file on azure webapp (in app service). htaccess file is part of Apache and can be used to alter the configuration of the Apache Web Server software to enable/disable additional functionality and features that the Apache Web Server software has to offer.

    If you want to host your application on Azure App service and want to use Apache as web server then you need to use runtime version as PHP and also starting php >=8.0 nginx is the web server on app service.

    PHP versions <8.0 and =~8.0 are reaching End-of-life on azure app service and deploying/creating the webapp from portal (except phpv8.0) is not possible, you refer to this GitHub article for more information about php on app service.

    If you want to use php runtime version <8.0 then you need to webapp for containers.

    The below articles might help you in changing the configuration to htaccess file in app service in linux.

    1. rewrite or redirect in azure app service on linux.
    2. Apache configuration: htaccess

    Feel free to reach back to me if you have any further questions on this.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.