Skip to content

Instantly share code, notes, and snippets.

@glennyboy

glennyboy/301 Domain Redirect Secret

Last active Feb 4, 2020
Embed
What would you like to do?
301 Domain Redirect
RewriteEngine on
RewriteCond %{HTTP_HOST} ^olddomain.com [NC,OR]
RewriteCond %{HTTP_HOST} ^www.olddomain.com [NC]
RewriteRule ^(.*)$ https://newdomain.com.com/$1 [L,R=301,NC]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.