Sunday, June 17, 2007

How to create a google apps custom domain and move your blogger blogs to your new domain

Okay, I'm impressed.

This was a bit hard for me to figure out from Google's generic documentation [1], but with the way I've described the process below anyone can do it. Cost is $10/year. It took me about 30 minutes to:
  1. create and register a custom domain (kateva.org) and set it up with free google apps.
  2. create a CNAME entry corresponding to the name I want my blog to have.
    (Example: instead of http://googlefaughnan.blogspot.org this blog will eventually move to http://tech.kateva.org)
  3. change my blog publish settings to the new url and demonstrate the new url works and the old one redirects.
I've done this for a test blog I created for this kind of experiment, but in the description below I'll use this blog as an example (though as of this posting I've not yet moved it).

Get your Google Apps domain and configure your subdomain CNAME settings.
  1. Go to Google Apps and register a domain for $10/year configured with the free Google Apps services. (Same thing we do for our family email, I have a few businesses setup this way too.) In this case, I used kateva.org. (Kateva is our dog's name, I rather like it.)
  2. From Google Apps follow the link on the advanced tab to eNom's configuration screens. (The advanced tab will give you a high security password and username information). Note there are host records associated already with ghs.google.com.
  3. Click the edit button and add a new row. For "host name" enter the name of the blog, such as "tech" (for Gordon's Tech, which would then have the url http://tech.kateva.org). For Address use ghs.google.com. For Record Type use CNAME.
Now go to Blogger and select the blog you want to move.
  1. Note the current blog URL, because when you're done it will be gone (but it will redirect).
  2. Click on Publishing tab.
  3. Enter the url corresponding to the CNAME you created (example: notes.kateva.org).
  4. Don't use the missing files host. (This is mostly for persons who had FTP blogs and are switching to a hosted blog.)
Now test
  1. Does old URL redirect?
  2. Does new URL work?
I'm going to do some more testing with feeds and the like, then move my blogs. As to why I'm doing this, that will be a post on Gordon's Notes shortly ...

Two Blogger help files to use for reference:
[1] They're clearly trying to be "open" and "generic", but this works very easily if you do everything with Google. They just don't document it that way.

Update 6/18/07: I'm concerned that after one makes this switch, feeds that point to the old URL no longer update. I hope I'm wrong about this! I'll update as I learn more. Not good if true! (See also)

Update 7/19/07: It turns out that the 301 redirect works, but only at the domain level. Since Google changed the syntax for RSS feeds between their blospot and custom domain implementations RSS feeds don't "update" by redirect. Atom feed syntax is identical, so they do update. Google has not acknowledged nor documented this.

Also, it's interesting how this works. A CNAME is imply a redirect. So all requests for blog.kateva.org are redirected to ghs.google.com. I assume when one switches in Blogger to a "custom domain" Google creates a relationship in ghs.google.com so that all requests for the custom domain sent to ghs.google.com are resolved internally. So this solution implements two layers or indirection, one at the CNAME level and one at ghs.google.com.

Update 4/15/2008: Google never did fix the old-rss redirect bug.

3 comments:

Vijeesh Ravindran said...

Hello Gordon,

Does Page-level redirection work in this case?

For Eg - Will abc.blogspot.com/2007/03/my-post.html redirect to
abc.com/2007/03/my-post.html or just to abc.com (i.e the home page)?

Thanks..

John Gordon said...

Yes, it's page level redirection. The only problem I ran into was with some legacy feeds that Google has half forgotten -- but that's a very unusual circumstance.

Uriah W. said...

So basically, if we switch we would lose all feedburner subscribers?

i wonder if feedburner allows you to change which url the feed comes from, then you would save your subscribers having to switch.

analytics, too, i assume would be from ground up again?