How to Retain .htaccess Rules After Transitioning PHP Handler from Apache to Nginx in Plesk

November 14, 2023 / Plesk

This article explains the process of retaining .htaccess rules after transitioning PHP handler from Apache to Ngnix in Plesk.

Let us follow the steps:

  1. Log in to Plesk as admin.
  2. Install htaccess to nginx converter extension.
  3. Select the “Domains” option.
    domains
  4. Choose the domain.
    domains
  5. Then select “Hosting & DNS” tab and click on the “Apache & Nginx settings” sub-option.
    hosting & DNS
  6. Scroll down until you find, “Additional nginx directives” option, click the link.
  7. Add the content of .htaccess file and click “Convert to nginx” button.
  8. Click the “Ok” button to save the changes.
    additional

This way, you can preserve .htaccess rules when switching the PHP handler from Apache to Nginx in Plesk. If you encounter any challenges, do not hesitate to contact our support experts.

Spread the love