I recently upgraded my site to SSL and I was wondering if I should force my traffic to HTTPS rather than leave access to HTTP?
If so how should I go about doing this on WordPress?
Webmasters Stack Exchange is a question and answer site for pro webmasters. It only takes a minute to sign up.
Sign up to join this communityIt is a good idea, but be warned, you may encounter many "mixed content" warnings where some content is loaded over http. This will happen with hard coded links to things like google fonts and images. If this happens, your page will be regarded as insecure.
Having said that, if you want to force to https add the following to your .htaccess file
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://example.com/$1 [R=301,L]
.htaccess
file and still expect them to work!) The above redirect should ultimately be changed to a 301 (premanent) redirect after you've made sure it is working OK (ie. change R
to R=301
).
– MrWhite
Jan 19 '17 at 10:53