Build Your Own Arcade Controls Forum

Main => Everything Else => Topic started by: shmokes on August 06, 2012, 02:59:37 pm

Title: Changing a website's domain name
Post by: shmokes on August 06, 2012, 02:59:37 pm
Anybody have any experience with changing the domain name of a Wordpress based website? I currently run the site http://bestkidipadapps.com (http://bestkidipadapps.com). I want to change the name of it to http://bestkidapps.net (http://bestkidapps.net), which I own, or potentially to another name. I know vaguely that I need to setup redirects to preserve my search engine rankings, but I wonder if there are any other serious pitfalls I should be ready for w/r/t database issues and the like. Also, as much as I know that I need to setup redirects, I don't know how to do it. I just mostly assume that it involves a bit of googling and following directions. Any tips on the subject are much appreciated.
Title: Re: Changing a website's domain name
Post by: 404 on August 06, 2012, 04:22:25 pm
just leave both domain names running and set your canonical url to be the one for your new domain. You will lose pagerank temporarily but it should be fine. Alternatively, there may be a wordpress mod that will do proper 301 redirects for you.
Title: Re: Changing a website's domain name
Post by: capsule on August 08, 2012, 05:44:58 pm
404 is right but you don't need a plugin to solve the 301 problem.

The easiest way to do so is to make both domains point to the same virtual host (hosting company generally call this domain parking or domain aliases).

Once it's ready, reconfigure your wordpress to tell what's the new domain (http://bestkidapps.net (http://bestkidapps.net)) so internal URL and redirects point to the right domain.

To solve the 301 redirect needed to avoid duplicated content (because both domain will display the same website), just use this simple rewrite rule (you can add it on top of your current .htaccess file (wordpress probably created one for you if you configured rewritten URLs):

Code: [Select]
RewriteEngine On
RewriteCond %{HTTP_HOST} !^bestkidapps\.net$ [NC]
RewriteRule (.*) http://bestkidapps.net/$1 [QSA,R=301,L]

Basically, it tells to 301 redirect every request to bestkidapps.net if the original request was not made on this domain.

HTH
Title: Re: Changing a website's domain name
Post by: shmokes on August 09, 2012, 12:08:24 am
Awesome. Thanks so much.