HermanMartinus / bearblog

Free, no-nonsense, super fast blogging.
MIT License
2.63k stars 75 forks source link

http vs. https: Different codes were found on custom domain sites. #180

Closed ok4ib closed 2 years ago

ok4ib commented 2 years ago

I accessed a custom domain site using both https and http. The client received the same content, but different HTTP codes: 200 and 308 respectively.

It is recommended that users be able to reach your site using both http and https URLs, and see the same content and HTTP codes in both cases.

For more information on this issue, please see here.

HermanMartinus commented 2 years ago

A 308 is a permanent redirect, which is correct as all http traffic is redirected to https traffic on custom domains. Can you expand on what's wrong with the 308?

ok4ib commented 2 years ago

Hi Herman, thanks for your reply! I was wondering about SEO. I just dove deep into the problem and found out that Search engines separately index both HTTP and HTTPS, so it would also be a problem for content originality. Sorry for wasting part of your time. P.S. Happy Birthday!

HermanMartinus commented 2 years ago

No problem :) yeah, so in this case there won't be any content indexed for HTTP, which is good as there won't be duplicate content (and even if there was, all content has a canonical_url set up to illustrate which is the original and defaults to the HTTPS version.

Thanks! 🎉