BlueHost 301 Redirects

By default your website can be accessed with both www.domain.com and domain.com. Since Google penalizes this due to duplicate content reasons, you should restrict the access to either www.domain.com or domain.com. Some links may be outside of your website scope and/or the search engines may have already indexed your website under both addresses.

Create a 301 redirect forcing all http requests to use either www.domain.com or domain.com

In order to redirect the non www version of a domain to the www version of the domain, you will need to edit the .htaccess file. You can follow a detailed tutorial Google Canonical problems - www versus non.www

Create a 301 redirect for file name changes

If you decide to change the names of some of your files, and Google has already indexed your site, your visitors may receive the dreaded  "Error 404 - File not found." Worse yet, your page may already have a good Page Rank and you run the risk of losing traffic. Creating a 301 permanent redirect is the best way to go.

Using the BlueHost Control Panel for SOME 301 Redirects

When I want to redirect one domain to another domain, I normally just edit or create the .htaccess file. For those of you who are using Bluehost as your hosting company, there is another way of doing this. You can use the 301 Redirect Option that is part of your Bluehost Control Panel to redirect one domain to another domain.

Please Note: This tool is designed for basic site to site or directory to directory redirects, not redirects to specific filenames. To accomplish these types of redirects, you will need to create custom rewrite rules in the directory's .htaccess file.

Step 1: Log into your Bluehost control panel.

Step 2: Locate the 'Domains' menu.

Step 3: Locate and click on the 'Redirects' icon. This will take you to the 'Redirects' menu.

Screenshot Bluehost domain tab > 301 redirects.
Fig 1: BlueHost Control Panel Redirects

Step 4: Do the following:

  • Select the 'Type' of Redirect you want to do. Permanent (301) is the default.  See Fig 2
  • Select the domain you want to redirect from the drop down menu. See Fig 2
  • Select where you want the domain to redirect to. You must enter a fully qualified url. Once entered correctly, that field will change color from pink to white. See Fig 3
  • Select the www redirection. Redirect with or without www is the default.
  • Select the Wild Card Redirect if you need it. Note: Checking the Wild Card Redirect Box will redirect all files within a directory to the same filename in the redirected directory.   You cannot use a Wild Card Redirect to redirect your main domain to a different directory on your site.
  • Click the 'Add' button

Screenshot Bluehost Redirects dialog box.
Fig 2: BlueHost Redirects Dialog Screen


Fig 3: Redirect from to dialog screen

Step 5: Once you click the 'Add' button you will be redirected to the screen that shows you that the Redirect has been successful.

Screenshot Redirect Complete.
Fig 4: Redirect complete screen

Step 6: The code added to your .htaccess file looks like this:

RewriteEngine on
RewriteCond %{HTTP_HOST} ^genealogywebcreations.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.genealogywebcreations.com$
RewriteRule ^/?$ "http\:\/\/www\.genealogy\-web\-creations\.com\/" [R=301,L]

NOTE: The above code redirect the non hyphenated version of this domain to the hyphenated version.

To check if your redirect is successful, go to http://www.seoconsultants.com/tools/headers type the url of the site you are redirecting into the URI dialog box > Click the Check Server Headers button.

Check domain redirects dialog.
Fig 5: Header Check for domain redirects

You should see something like this:

Screenshot Header Check resutls.
Fig 6: Header check results



Copyright © 2010 Pat Geary of Expression Web Tutorials & Templates All Rights Reserved
Written and Tested May 18, 2010
Updated August 2011