How to use WordPress website with Nginx in Virtualmin

You have to configure the rewrite rule in the Nginx configuration file for WordPress because Nginx does not use the htaccess file.

Login to Virtualmin >> Webmin >> servers >> nginx >> edit config file

Add the following code to the Nginx configuration file and you're done. Your site should work properly.

location / {
root /home/domains/public_html;
index index.html index.htm index.php;
try_files $uri $uri/ /index.php?$args;
}

 

Note: Download the backup of your Nginx config file before making changes. Change Location Path "/home/domains/public_html;" then restart the Nginx service after the changes.

 
 
  • Virtualmin, backup, Nginx, domain
  • 1 Users Found This Useful
Was this answer helpful?

Related Articles

How to increase PHP memory limit in virtualmin

To increase the PHP memory limit in Virtualmin, do the following:   1. Log into Virtualmin...

How to change password of Virtualmin

Please follow the below steps to change the password of the Virtualmin Admin. Login to...

How to create an email account in Virtualmin

To create an email account in Virtualmin, do the following: logged into Virtualmin. Choose...

How to install FREE SSL certificate in Virtualmin

Please follow the below steps to install a FREE SSL certificate in Virtualmin. 1. logged into...

How to run Cron job manually in Virtualmin

Please follow the below steps to run the run cron job manually in Virtualmin.   Login to...

Powered by WHMCompleteSolution