Hi everyone
I need to redirect an old domain to new domain. And one thing to remember is that the pages on old domain are not available on the new domain. I tried using the below htaccess method:
redirect 301 / http://www.newdomain.com
But it is not working for all pages, only for the home page. What is the rule we should be using to redirect all old pages from old domain to the new domain index page.
Thanks
If you have deleted all pages, you can setup a redirect for your 404 not found pages to forward to a different domain.
Thanks maartenvr. Will look into it.
Actually the earlier pages still reside on the old domain, so it would be better if I can just redirect all pages from old domain to the new domain’s index page.
thanks though, will try out your method as well.
create a .htaccess file in your public_html folder with this content:
RewriteEngine On
RewriteRule .? http://mynewdomain.com [R=301,L]