Disable HTTP and Allow only HTTPS RRS feed

  • Question

  • User-1902119878 posted

    Hi Team,

    I've an issue with url redirection. Currently i have an app devleoped in Python and used IIS to deploy it. Portal works fine with http binding. Network team has configured the domain in such a way that if user enters http://xxx.yyy.net, it will redirect the request host to https.

    A week ago, we got SSL certificate for our domain to make it secure. I recieved pfx certificate from them. Using Server Certificates option, i imported the certificate and binded my website with it.

    Now the issue, website is running only when i have both http and https bindings in it. If i remove http bindings, website stops.

    So i kept both http and https in my binding and to find is the request host url is http or https, i written a log in my python code to track it.

    I found it was only http://xxx.yyy.net and not https://xxx.yyy.net.

    So is there any workaround to make it https and block http. I dont want the website to work on http.

    Thursday, February 13, 2020 2:45 PM

All replies

  • User690216013 posted

    If i remove http bindings, website stops.

    Stop in which way? Show it clearly.

    You should not remove HTTP binding either, as people now simply use URL Rewrite module to redirect from HTTP to HTTPS.

    Thursday, February 13, 2020 3:24 PM
  • User-1902119878 posted
    Thanks lextm for your reply.

    I have 2 bindings one with http(unassigned):80 and another with https(unassigned):443. When i run my website with any of the url, its working fine. But when i remove http binding and try to run my website, the page doesn’t getting loaded.

    Since I’m using some python libraries for single sign on implantation, i need request url to be https and not http.

    If i have both http and https binding, my python library is getting http request when page loaded.
    So i thought of allowing only https and not http.
    Thursday, February 13, 2020 5:58 PM
  • User-848649084 posted


    You cant remove the HTTP binding from the site as lex li suggested. you could use IIS URL rewrite module to redirect the HTTP request to https.

    below is the rule:

     <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" />

    Note:  make sure you installed the URL rewrite Extention. if not you could download it from below link:


    you could refer below link on how to configure pfx certificate in iis:



    Friday, February 14, 2020 7:44 AM
  • User-848649084 posted


    Is your issue solved?

    If your issue is solved then I request you to mark the helpful suggestion as an answer. This will help other people who face the same issue.

    If your issue still exists then try to refer the solution given by the community members.

    If then also you have any further questions then let us know about it.

    We will try to provide further suggestions to solve the issue.

    Thanks for your understanding.



    Wednesday, February 19, 2020 1:43 AM