Contact Information
+27 11 768 5724

Web Design

We specialize in Joomla! web design, custom templates and Joomla! hosting.  Toxzen also develop custom data driven PHP web applications.

Web Hosting

Affordable Web Hosting services, domain registration and email.  Our business Web Hosting packages are perfect for your growing business.

To www or not to www - that is an SEO question

Rate this item
(1 Vote)

Is it really important to make sure your websites incoming traffic lands on either www or not?  This question bothers many and for some its never even occured to them.  This tutorial outlines how to set your Joomla htaccess file to redirect to one or the other.

Should I, shouldn't I

Think about it logically, search engines use bots (software) to read your site and index key topics.  This helps users who search to find what they looking for.  If your site has no consistency and can be read by either going to or simply - what should they put in the search results?  On a more complicated level, is the same site as  How does a computer know.  While you might fill the pages of search results initially it pains search engines and users.  Bigger search engines are penalising users for not fixing this problem.  So you need to choose!

What are my options?

These comments from another site really sum it up well: "It doesn't matter which you choose but you should pick one and be consistent ... So whichever you choose for aesthetic reasons should be consistently used for SEO reasons".  However keep the following in mind:

  • It's also useful to have a single canonical domain so cookies don't get lost, which really confuses users.
  • If you chose one as canonical, accept the other but redirect it to avoid duplicate content from the search engines point of view.
  • Don't, whatever you do, require the www to be typed manually. Ever.

A lot of people feel that typing the www is pointless, we all know we're on the web.  Although it does provide clarity if you use sub domains like  The main this is keep it consistent!

How do I do this for Joomla?

You need access to your files hosted on the server.  Open and edit the htaccess file.  If you have not changed its name, it will be htaccess.txt.  Once done you need to save it as .htaccess (dot comes first and there's no txt extension).  Search this file for the expression "# Redirect non-www to www".  Below it you will see instructions saying "Comment out the non-www to www rule if you choose to use this".  You can remove the # in front of the next 2 lines to make it effective, or put them back to turn it off.  Bear in mind that this may take some time to take effect.  Turn off caching when testing.

I had some trouble using those settings provided and opted for something like this:


RewriteCond %{HTTP_HOST} ^mydomain\.co\.za [NC]

RewriteRule ^/?$ "http\:\/\/www\.mydomain\.co\.za\/" [R=301,L]

REPLACE mydomain with your domain name and the \.co\.za with your domain extension.  NOTE also that this redirects from a non www address TO a www address.  In other words if you type you will automatically be sent to making it consistent for search engines.



Additional Info

  • Software: Joomla
  • NOTE: Some knowledge of files hosted on the server.
8 subscribers

Comment subscription

Receive email notification when a new comment is added to this item.