May 25, 2011

Google doesn't like these

If you’ve got a website and you pay attention to where your visitors comes from, you’ll probably see that search engines like Google provide you with a huge proportion of your traffic.

Google is probably the most useful website in the world, and one of the things that makes it so good is that it’s very efficient at clearing out pages that don’t exist any more. Ask yourself, when was the last time you clicked on a link in Google and got taken to a blank page?

It hardly ever happens, and when it does happen, it’s usually because a website has just changed and Google hasn’t cleared out its data about that website yet.

So what do you do when you’ve got a website with hundreds or thousands of pages … and you want to scrap the whole lot and move to a new system?

Will your old pages disappear forever from Google? The ones you’ve spent years optimising for high Google rankings? Will your hard-earned search engine traffic disappear?

The answer is “probably yes, and you’ll need to wait until Google finds all your new pages” – unless you use the power of the redirect.

Let me explain…

On the web, when you try to connect to a website and load up a page in your browser, the other computer sends your computer a code to tell it whether your request has been succesful or not.

There are quite a few of these status codes, but here are the most common ones:

200 – OK
301 – Moved (permanently)
302 – Moved (temporarily)
401 – Unauthorised
403 – Forbidden
404 – Not found
500 – Internal error

You’re probably most familiar with the 404 error. This is what happens when you try to browse to a non-existent page. You can see examples of them on most good websites.

Check out our 404 error page here:

Facebook’s 404 page is here:

And here’s Amazon’s 404 page:

If Google finds a link to a page that gives this error code, it deletes that page from its index. So your pages that don’t exist will disappear from Google’s search results.

How to ensure a smooth transition to your new site

Often when you create a new site to replace your old one, your pages stay roughly the same and you just want to redirect people (and Google) from the old pages to the new pages.

So what you need to do is use the ‘Moved (Permanently)’ codes (301) to point Google in the direction of your new page if they follow a link to the old page.

A few of our clients have required this on a pretty massive scale, e.g. Kennedy Park Top 10 Holiday Resort and EIT.

There are two ways you can do set up redirects:

  1. If your pages have simply changed their filetype (e.g. page.html to page.php), you can set up a rule to redirect any page ending in .html to its equivalent page ending in .php.
  2. If the structure of the site has changed significantly, you’ll need to do it the hard way: i.e. set individual redirects for every page you want to be redirected. A good way to do this is to list all the old pages in the first column of an Excel spreadsheet and then in the column next to it, put the page that you want each one redirected to.

Then someone (like us) who knows their way around a web server will be able to set up these redirects and when you switch the site over from the old one to the new one, Google won’t dump all of those old pages. They will be replaced in the Google index by the new pages. They might move up or down in the rankings, but at least they’ll be in there.

The added benefit of this is that your internal links will still work and links to your content from other sites will still work too.