Log in



WWW. with 301 redirect

Thursday, March 26th, 2009 by Eric Mandell

The most accepted way to make sure all of your traffic goes to the appropriate URL is to use a 301 redirect in your .htaccess file. The reason this is important is because Google and other search engines will see your domain name with the ‘www’ before and without the ‘www’ before it as separate URL’s which creates a problem because those pages will be considered to have duplicate content.

Even though the links to products, categories and other pages are created dynamically in Miva Merchant this still presents a problem because your homepage and every other page can potentially be accessed with and without the W’s in the URL. To make sure this is not a problem with your website update your .htaccess file with the following 301 redirect.  Click here if you need instructions on creating a .htaccess file. You should also add canonical URL’s to your Miva Merchant pages in addition to creating the 301 redirect.

Note: replace ‘morditech.com’ with your own domain name

Options +FollowSymLinks
RewriteEngine On
RewriteCond %{HTTP_HOST} ^morditech\.com$ [NC]
RewriteRule ^(.*)$ http://www.morditech.com/$1 [R=301,L]

Leave a Reply

You must be logged in to post a comment.