Knowledgebase
How to Redirect Visitors to the Secure URL - Plesk
Posted by KB Editor on 27 April 2017 01:57 PM

This article assumes that you have already ordered an SSL Certificate.

To automatically redirect visitors to the Secure URL:

  1. Log into your Plesk Control Panel
  2. Click Website & Domains

  3. Click File Manager for the website you want to redirect
  4. Click on the web.config file
  5. Click Edit in Code Editor

  6.  Add the the following code after <system.webServer>:
    <rewrite>
    <rules>
    <rule name="http to https" stopProcessing="true">
    <match url="(.*)" />.
    <conditions>
    <add input="{HTTPS}" pattern="^OFF$" />
    </conditions>
    <action type="Redirect" url="https://{HTTP_HOST}/{R:1}" redirectType="Temporary" />
    </rule>
    </rules>
    </rewrite>
  7. Click OK

All visitors to your website should now be redirect to the secure URL https://example.com.



Attachments 
 
(13 vote(s))
Helpful
Not helpful

Comments (0)
Post a new comment
 
 
Full Name:
Email:
Comments:
CAPTCHA Verification 
 
Please enter the text you see in the image into the textbox below (we use this to prevent automated submissions).