Introduction

You probably know that for the sake of your search engine rankings, you should choose to either have your web site use an address like 'www.netdip.com' or like 'netdip.com' - but you shouldn't have it both ways. 

You might already know that you can edit your .htaccess file on your server to make the NON-www domain automatically redirect to the proper WWW domain - or just the opposite.

With TYPO3, you don't need to edit .htaccess. You can configure TYPO3 to do this with domain records.

I've decided recently to let TYPO3 handle my domain redirection for a couple of reasons:

  1. For simplicity I like to manage everything possible regarding my TYPO3 driven site within TYPO3. I like that domain records and redirection instructions can be stored in my TYPO3 database with almost everything else regarding the proper functioning of this site. I don't like to have too much stuff in my .htaccess file, it can get messy and too difficult to manage.
  2. By adding a simple 301 redirect instruction in my .htaccess file, it modifies all pages on the netdip.com domain whether or not those pages are TYPO3 driven. I forsee myself writing some non-TYPO3 applications on this domain for which I might like a shorter url without the 'www' in the beginning. By creating the 301 redirect within TYPO3, I only modify the behavior of TYPO3, and not any little static page I may have lying around on this domain.

So, what follows is all that has to be done to redect an address like netdip.com/typo3-cms/ to http://www.netdip.com/typo3-cms/.