Link to home
Start Free TrialLog in
Avatar of Arikkan
ArikkanFlag for United States of America

asked on

Redirect HTTP to HTTPS in Azure

We just installed SSL in our azure website to convert it to HTTPS.

Now we want that any request coming in as HTTP should be changed/redirected to HTTPS connection.

How can I do this?
ASKER CERTIFIED SOLUTION
Avatar of Alex Smith
Alex Smith
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Arikkan

ASKER

I tried this and it did not work on my server. So I used the simplest rule to test.
Even that did not work.

  </system.webServer>

        <rewrite>
            <rules>
                <rule name="Redirect to HTTPS">
                       <match url="*.*" />
                        <action type="Redirect" url="http://www.google.com"  />
                </rule>
            </rules>
        </rewrite>
  </system.webServer>

Open in new window


Any ideas?
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Arikkan

ASKER

I used this

<action type="Redirect" url="https://{HTTP_HOST}{REQUEST_URI}" redirectType="SeeOther" />