URL Canonicalization – a simple fix
Search Engine robots / web crawlers tend to treat URLs with a www and without a www as two entirely separate domains. For example, www.domain.com and domain.com are treated as two separate websites.
This means that if your website does not redirect to just ONE of these addresses each time it is entered in the search bar, your Page Rank will be split between the two URLs – ultimately lowering it and therefore affecting how you rank. If you want to improve SEO so that your site ranks well for the keywords you have chosen, this is an issue you can’t afford not to fix. bad.
So, how do you know whether/not your site has this problem?
It’s simple. In the Google search bar type the following:
1. First try: https://www.domain.com
2. Then try: https://domain.com
If you find page results for both the searches, then it means that your page rank is split in two.
For example, if you type in domain.com without the www. And you are redirected to the www.domain.com version which displays your site, you are fine.
If however you type in domain.com and your site shows up with the URL still displayed as domain.com, and the www.domain.com shows on its own URL, then you’ve got a problem.
Dividing your Page Rank score between the two websites will reduce the likelihood of your website ranking for specific keywords. You will therefore want to get this sorted out as soon as possible. If you want to find out more about how to improve SEO, take a look at our blog post on digital marketing and getting found online.
Resolving split Page Rank issues
Thankfully the fix for this is very simple. All you have to do is redirect one of the pages to the other. For example, if you decide to keep the www version of the domain then redirect the non www version of the domain (and pages) to the www version of the domain (and pages).
This can be done by simply coding 301 redirects into the .htaccess file. The code that you will need to type is given below:
RewriteEngine on
RewriteCond %{HTTP_HOST} ^yoursite\\.com$ [NC]
RewriteRule ^(.*)$ https://www.yoursite.com/$1 [R=301,L]
The process of telling the search engine which URL to consider and which one to ignore is called URL canonicalization. You can read more about it in Matt Cutts’s blog post.