in order to redirect any http calls to https. please follow these steps.

1. Open IIS as administrator
2. Right click on the website you would like to redirect the site to and click explore.
3. If there is a web.config file, make sure it does not currently have any rewrite rules. If so, remove it.
4. Use the below section of code, you should take off configuration XML tag if you already have one, if not, create a new web.config and copy / paste the below code.

<rule name=”HTTPS force” enabled=”true” stopProcessing=”true”>
<match url=”(.*)” />
<add input=”{HTTPS}” pattern=”^OFF$” />
<action type=”Redirect” url=”https://{HTTP_HOST}{REQUEST_URI}” redirectType=”Permanent” />

5. These steps will work assuming you have URL Rewriter installed as a part of IIS.

6. If you would like to install URL Rewriter – download and follow these steps for installation.

Permanently redirect http to https – IIS

Leave a Reply

Your email address will not be published. Required fields are marked *