Skip to content

Instantly share code, notes, and snippets.

@DownGoat
Created July 13, 2017 13:49
Show Gist options
  • Save DownGoat/ce3d4892fe6fba9fc5569bc93f515562 to your computer and use it in GitHub Desktop.
Save DownGoat/ce3d4892fe6fba9fc5569bc93f515562 to your computer and use it in GitHub Desktop.
IIS URL Rewrite
<rewrite>
<rules>
<rule name="Redirect to HTTPS" stopProcessing="true">
<match url="(.*)" />
<conditions>
<add input="{HTTPS}" pattern="^OFF$" />
<add input="{QUERY_STRING}" pattern="excluded.htm" negate="true" />
</conditions>
<action type="Redirect" url="https://{HTTP_HOST}/{R:1}" />
</rule>
</rules>
</rewrite>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment