Creare SEO homepagesovereign logo
0800 01 999 06

SEO & PPC – The Perfect Mix: Nick and James take a look at using PPC and SEO in conjection with each other to he... http://t.co/sWE16LKV

Posts Tagged ‘SEO friendly re-directs’

How to make a search engine optimisation friendly .htaccess file

author Author: Nick Rinylo
category posted in Search Engine Optimisation

A lot of sites can have duplicate content issues and especially CMS (Content Management Systems). I talked about the canonical link element on a previous post, which describes how to let Google know what page holds the original copy within your website.

This post on how to build a search engine optimisation friendly .htaccess file and is designed as a basic piece of good practice in SEO, which helps sites with duplicate content issues and means that links which are not 100% accurate are still rated by Google.

For Example. If you have links going to /index.php and not the root this can be interpreted as 2 different pages, I have seen sites with different Page Ranks on the root/ to the index/ page.

You can stop this happening by adding a .htaccess file or similar dependent on your host / server. The following code is designed for a linux apache server and is designed to revert the following:

  1. domain.co.uk >> www.domain.co.uk
  2. www.domain.co.uk/index.php >> www.domain.co.uk
  3. domain.co.uk/index.php >> www.domain.co.uk

To do this you require 2 sections of code to be added to your .htacess file; The first adds the www. back onto the front of the domain.

So from domain.co.uk >> www.domain.co.uk

RewriteEngine On
RewriteCond %{HTTP_HOST} !^www.domain.co.uk$ [NC]
RewriteRule ^(.*)$ http://www.domain.co.uk/$1 [R,L]

The second removes the index.php;

So from www.domain.co.uk/index.php >> www.domain.co.uk

Options +FollowSymLinks
RewriteCond %{THE_REQUEST} ^.*/index.php
RewriteRule ^(.*)index.php$ http://www.domain.co.uk/$1 [R=301,L]

General good practice within SEO if often overlooked, please add any additional servers code in the comments.

Canonical Link Element – Duplicate Content

author Author: Nick Rinylo
category posted in Search Engine Optimisation

After coming across the canonical link element in February i hadn’t yet found a use for this tag / element. But now i believe i have. Basically it is designed to tell Google which page is the true version of potentially a wide range of domain combination or DB queries. For example Google could potentially see the following as different pages (this is important within SEO):

domain.com
domain.com/
domain.com/index.php
domain.com/default.asp
www.domain.com
www.domain.com/index.php
www.domain.com/default.asp
www.domain.com/

You get the basic idea….

So i here you ask how do i let Google know which page is the correct version, well before you start doing any crazy 301 re-direct’s or use the canonical link element, if possible you should be consistent from the start meaning:

• Always link to the same domain
• Use a .htaccess re-write your domain
• Set up the correct domain in Webmaster Tools
• Consistent Internal Linking

If you have followed these simple steps you will have no need to use the canonical link element, however if you free you potentially have duplicate content issues with you CMS or ecommerce platform all you need to do is add the following code in your <head></head> tags.

<link rel=”canonical” rel=”http://www.yourdomain.com” />

Google will trust that you have used this correctly and unless you have made a mistake i.e. created a infinite loop. It will assume that this command is correct. This tag is only based for sites that you fear may have duplicate content issue, any other issues can be solved with 301 re-directs.

Remember also that you can only use the canonical element internally and sub domains, NOT external websites.

References:

http://googlewebmastercentral.blogspot.com/2009/02/canonical-link-element-presentation.html

Welcome to Creare Communications SEO Blog, you will find tips, tricks and video tutorials all about SEO.
rss iconfacebook iconlinkedin icontwitter iconyoutube icon

search the SEO blog

Monthly Archives