Skip to content

Instantly share code, notes, and snippets.

@remitaffin
Created December 27, 2016 20:37
Show Gist options
  • Save remitaffin/ac11a2002014073ee16f36db9a08453f to your computer and use it in GitHub Desktop.
Save remitaffin/ac11a2002014073ee16f36db9a08453f to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="ForceHttps" stopProcessing="true">
<match url="(.*)" />
<conditions>
<add input="{HTTPS}" pattern="off" ignoreCase="true" />
</conditions>
<action type="Redirect" url="https://{HTTP_HOST}{REQUEST_URI}" redirectType="Permanent" appendQueryString="false" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment