0

My website, for example, https://example.com was running on https. Now, ssl certificate validity is expired on host server. So there is requirement to redirect traffic to http://example.com. All users were initially using https://example.com, so their browser automatically picks https. http is working fine. How to redirect traffic to http if someone attempts to access using https. https gives error:

ERR_SSL_PROTOCOL_ERROR This site can’t provide a secure connection

I already viewed this question, but it has been marked off-topic, so there are not more suggestions/answers. Sometimes, solution provided by one works for one and does not work for another.

halfer
  • 19,824
  • 17
  • 99
  • 186
Ishpreet
  • 659
  • 5
  • 19
  • 1
    It may be easier to just fix the certificate's validity. If you are stuck, how about Let's Encrypt - it is pretty easy to get started and it's free of charge. – halfer Apr 19 '19 at 15:44
  • SSL certificate is not free on hosted server. It is paid service. Renew is not free. – Ishpreet Apr 19 '19 at 16:13
  • You will need to buy a new certificate, or explain in your question why that is not an option. As far as I know you cannot do any redirects on an invalid cert, since a user would have to click through an invalid cert warning before their browser would cooperate with the redirect request. By that time, they might as well browse the site with the invalid cert. – halfer Apr 19 '19 at 21:25
  • @halfer, I misunderstood your Let's Encrypt. Now, I understood Let's Encrypt is free. Thanks a lot for suggestion. – Ishpreet Apr 22 '19 at 07:16

0 Answers0