Skip to content

Instantly share code, notes, and snippets.

@m4tlch
Created April 17, 2015 06:45
Show Gist options
  • Save m4tlch/f816113751d515f7db83 to your computer and use it in GitHub Desktop.
Save m4tlch/f816113751d515f7db83 to your computer and use it in GitHub Desktop.
# Redirect to HTTPS
RewriteCond %{HTTPS} off
RewriteCond %{HTTP:X-Forwarded-Proto} !https
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment