Solved

HTML canonical / 301 redirect confusion

Posted on 2014-09-17
4
150 Views
Last Modified: 2014-09-24
I have a website www.acesestimating.com.
I want acesestimating.com to forward to www.acesestimating.com
To address this I added the following to my .htaccess file:

RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]

It appears to work... typing either address leads to www...

I'm concerned about duplicate content now... It appears that:

acesestimating.com/Free-Trial
www.acesestimating.com/Free-Trial
www.acesestimating.com/Free-Trial.php

can be interpreted as duplicate pages where there is only one physical page.  In the header section of Free-Trial.php I added:

<link rel="canonical" href="http://www.acesestimating.com/Free-Trial" />

Yet when testing using various sites they'll suggest that the canonical tag doesn't exist or isn't correct...

Please help.
0
Comment
Question by:classnet
  • 2
  • 2
4 Comments
 
LVL 53

Expert Comment

by:COBOLdinosaur
ID: 40328590
Actually you don't need the canonical.  The 301 on the re-direct tells the search engines that you are doing a permanent re-direct.  They no it is not duplicate content, and over time they will drop the pages without the www from search results and only return the www version.  The 301 is the method recommended by Google and will never result in the pages looking like duplicate content as long as you do not put both in a sitemap.

Cd&
0
 

Author Comment

by:classnet
ID: 40328964
COBOLdinosaur... so you think that, as long as the sitemap doesn't list any pages twice that I shouldn't be negatively impacted via SEO?
0
 
LVL 53

Accepted Solution

by:
COBOLdinosaur earned 500 total points
ID: 40331012
Right.  As long as the 301 re-direct works there is no problem.  When the pages are crawled the crawler gets a 301 response and then gets the page where they have been re-directed. The crawler then saves the new address in its data and when it is process on the indexing server the index gets updated.  Over time the old links get dropped from the index; replaced by the updated information, but if a crawler runs across an old version of the link on another site, the re-direct still gets it to the newest version.  The crawler never sees the old page because it has been re-directed, so there is no duplicate page.

Cd&
0
 

Author Closing Comment

by:classnet
ID: 40342296
Thank you for the clarification
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses four methods for overlaying images in a container on a web page
Is your Office 365 signature not working the way you want it to? Are signature updates taking up too much of your time? Let's run through the most common problems that an IT administrator can encounter when dealing with Office 365 email signatures.
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…
In this tutorial viewers will learn how to embed an audio file in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: : The declaration should display (CODE) HTML5 is supported by the most recent versions of all major browsers…

838 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question