Friday, November 20, 2009

Is there a better way to change the URL/address of my blog? allows you to change the URL/address of your blog in Just go to the dashboard and select tab Settings|Publishing. Change the URL there and Bang! Your original address is gone, together with your traffic and your readers.

I figured out a better way to get your new blog running and not lose your readers.

Step 1: Clone the blog with a new address

You can create a new blog with the address you desire. Then clone your blog to the new one. To clone, you can go to dashboard and (skip the first 2 steps if you haven't manually modified the template of your blog):
   1. Download the template of the old blog on page Layout|Edit HTML;
   2. Upload the template to your new blog on page Layout|Edit HTML;
   3. Export your old blog on page Setting|Basic|Blog Tools;
   4. Import the xml file to your new blog on page Setting|Basic|Blog Tools.

Step 2: Tell the readers your new address

You can add a description below the title of your blog to tell the readers that you have moved by editing the Header in Layout|Page Elements.

Step 3: Automatically redirect to your new address (optional)

With some JavaScript code on the old blog, you can redirect the readers to the new blog. But keep in mind that not all users enable the JavaScript in their browsers.

To add the redirecting code, go to the page Layout|Edit HTML of your old blog. Look for the tag <head> and add these right below it:
<script type='text/javascript'>
function forwardUrl()
   var oldDomain = "";
   var newDomain = "";

   var myUrl = location.href;

   if (myUrl === oldDomain)
      location.href = newDomain;
      var oldDomain2 = oldDomain + "search/label/";
      if ( >= 0)
         location.href = myUrl.replace(oldDomain, newDomain);

Change and to your own URLs.

Look for tag <body> in the template and change it into:
<body onload='forwardUrl()'>

Save the template. And it is done.

After this, whenever the users enter the Home of your blog or click on any labels, they will be redirected to the new blog.

That was how I changed my blog from to Click on and you can see how it will be forwarded.

Before this solution, I have tried to use Settings|Publishing|Custom Domain to forward the old URL to the new one. Unfortunately, doesn't allow me to forward to a address.

If you have any better ideas, please let me know.

No comments:

Get This <