.htaccess rewrite rule for https.... recommended?

ssl

#1

I just migrated my site to https and have set cloudflare to Full Strict, Always Use HTTPS, and Automatic Rewrites. It seems to work fine.

But it feels odd to me to not add an “http to https” gloabal Rewrite Rule in the .htaccess file on my server. I have rules there for non-www to www, and other things. I thought Google checks htaccess to discover permanent redirects when crawling a website. Does setting cloudflare toggles generate an actual htaccess file on cloudflare that the search engines use?

Is there any advantage or disadvantage to adding an https Rewrite Rule in my own htaccess file on my server? Thanks much for any feedback!


#2

I for myself don’t see any reason why it should be necessary. You can place htaccess rules if you feel uncomfortable without them. But the mentioned settings here at Cloudflare cause a 301 redirect to https.


#3

Thank you, Mark. :slight_smile: