Skip to content

Instantly share code, notes, and snippets.

@iamchetanp
Last active December 16, 2018 21:28
Show Gist options
  • Save iamchetanp/e6a53c08d159e8086106843357e3de19 to your computer and use it in GitHub Desktop.
Save iamchetanp/e6a53c08d159e8086106843357e3de19 to your computer and use it in GitHub Desktop.
Reditect rule for redirecting HTTP to HTTS (Apache) htaccess
# Redirect HTTP URLs to HTTPS
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment