Page 1 of 1

HTACCESS redirect each page to new URL of same page

Posted: Thu Jan 26, 2017 4:04 am
by simonmlewis
Hi

I need to do a 301 from each URL on our site, to a new site, that has the same structure and DB. So ALL URLS will be the same, except the domain name.

How do I do that in htaccess?

Re: HTACCESS redirect each page to new URL of same page

Posted: Thu Jan 26, 2017 6:45 am
by Celauran
[text]RewriteEngine On
RewriteRule ^(.*)$ http://new.domain.com/$1 [R=301,L][/text]