Moving a project to another domain name
Moving a project from one domain to another is something you should avoid. Unless it is really necessary – just don’t do it :)
But, maybe you sold a domain and want to transfer a project to another domain name. Then you have a lot of things to do.
I’ll show you here a few steps that you must do to make Google satisfied with this project transfer.
If possible, you should preserve URL syntax. So if you project had links like “olddomain.com/category/post.html” and you’re moving to newdomain.com, then you should go with “newdomain.com/category/post.html”.
To do this, you can use following code in .htaccess file root of your project (on a old domain):
-
-
Options +FollowSymLinks
-
RewriteEngine on
-
RewriteCond %{HTTP_HOST} !^newdomain\.com
-
RewriteRule ^(.*)$ http://www.newdomain.com/$1 [R=301,L]
-
…or this code if you don’t have support for mod_rewrite installed.
-
-
RedirectMatch 301 ^(.*)$ http://www.newdomain.com
-
Using the code from above, you’re redirecting all traffic (both visitors and robots) to a new domaini (newdomain.com) with 301 status (permanent redirect).
This will actually tell robots that you moved your website to another location. Also, visitor will be automatically transfered, so keep in mind that you should notify your visitors about this domain change so they should update their bookmarks as the old domain will no longer be available (for example).
Next thing you should do is to update your domain in webmaster tools (Google, Siteexplorer Yahoo, etc):
- remove sitemaps for the old domain
- add sitemaps to the new domain
This was the easy part. Next thing you should do is to contact all webmasters that have a backlink to your website and ask them to update it to a new address :)
This is important step because backlinks are very important for pagerank calculations etc.
Darko Martić - IT Engineer, eBusiness and eCommerce Professional

August 12, 2009 @ 2:03 pm
If you login to your Webmaster Tools account at Google, under the Site Configuration you can see a new feature called Change of Address.
The title itself is self-explanatory. This is usefull when you’re transferring your website to some other domain name.