I have two domains example.uk.net and example.co.uk – the example.uk.net has been in use since the website was started but i want to change over to the .co.uk version now – both domains are currently pointing to the same IP/sever – you see the same website on both domains…
Now i know i need to 301 redirect from the .uk.net to the .co.uk but i’ve read that it is best to do this page by page to retain google rankings/listings and also it is best practise anyway now i just can’t seem to get this working as both domains point to the same site i can’t use rewrite rules in the htaccess file such as…
Redirect 301 /get-a-quote/ http://example.co.uk/get-a-quote/
i also seem this piece of code on here that did seem to work but only for the main page, not any sub pages also it still doesn’t work on a per page basis only redirecting the whole site…
RewriteCond %{HTTP_HOST} !^example\.co\.uk$ [NC]
RewriteRule ^(.*)$ http://example.co.uk$1 [R=301,L]
If anyone could help me out that would be brilliant or if someone has handled something similar in the past – any pointers would be awesome…
Thanks
You were missing a
/: