How to force HTTPS on Plesk 12.x

This KB article describes how to force HTTPS on Plesk.

Enable HTTPS with Apache
Under the main domain panel, go to Apache & nginx Settings and add the following on the Additional directives for HTTP field:

RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

Enable HTTPS with nginx
Under the main domain panel, go to Apache & nginx Settings and add the following on the Additional nginx directives field:

if ($scheme != "https") {
    rewrite ^ https://$host$uri permanent;
}

After making these changes, click OK and you are done.

Was this answer helpful?

 Print this Article

Also Read

Install Let's Encrypt certificate on nginx running on CentOS 7

This article provides a brief procedure on how to install a Let's Encrypt certificate on nginx...

Powered by WHMCompleteSolution