Skip to content

Instantly share code, notes, and snippets.

@lyquix-owner
Last active August 10, 2016 03:58
Show Gist options
  • Save lyquix-owner/b90f472e5d52c91585143da266220aca to your computer and use it in GitHub Desktop.
Save lyquix-owner/b90f472e5d52c91585143da266220aca to your computer and use it in GitHub Desktop.
Force SSL to a whole domain
# Force domain to SSL #
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://www.example.com/$1 [R=301,L]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment