Skip to content

Instantly share code, notes, and snippets.

@AlexanderPoellmann
Created January 21, 2015 22:43
Show Gist options
  • Save AlexanderPoellmann/352decc3b31cafd0cfff to your computer and use it in GitHub Desktop.
Save AlexanderPoellmann/352decc3b31cafd0cfff to your computer and use it in GitHub Desktop.
Force SSL (https) on all Pages with htaccess
# Force https on all pages
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
</IfModule>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment