How to add a SSL certificate to your website with Virtualmin and enable HTTPS redirect

1. Login into Control Panel
2. Expand the Server Configuration menu.
3. Click on the SSL Certificate menu
4. Click the Let’s Encrypt tab.
5. At the bottom, make sure there is a “2” in the box, and make sure “Only renew manually” is not selected. The default setting is correct so just go with it.
6. Click Request Certificate
Now FTP to your site or use the control panel manager to create a .htaccess file containing the following information:
RewriteEngine On 
RewriteCond %{HTTPS} off 
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

Share this article

Leave a Reply

Your email address will not be published.

Scroll to Top