Andrew_Newth
Basic Pleskian
Hi all, I have set up my first Let's Encrypt SSL certificate on my site and can access the site via SSL. What is the best way to force the use of https? Is there a way to set this from within plesk at the moment?
I have added a redirect to my web.config and this seems to work OK but want to make sure this is the best method.
here is the rewrite i used:
Any advice greatly appreciated.
I have added a redirect to my web.config and this seems to work OK but want to make sure this is the best method.
here is the rewrite i used:
Code:
<rewrite>
<rules>
<rule name="HTTP to HTTPS redirect" stopProcessing="true">
<match url="(.*)"></match>
<conditions>
<add input="{HTTPS}" pattern="off" ignoreCase="true"></add>
</conditions>
<action type="Redirect" redirectType="Permanent" url="https://{HTTP_HOST}/{R:1}"></action>
</rule>
</rules>
</rewrite>
Any advice greatly appreciated.