Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I have a domain, say www.example.com which is redirected to a website built in Google Sites. I don't want different search engines treat example.com as a different site from www.example.com. How do I make a permanent link between the two? My domain is under GoDaddy.

EDIT

In Go Daddy, I have forwarding option set to Google site link.

Under CNAME, I have Google provided alias and directions.

share|improve this question
    
Can you provide more information or at least a clearer explanation of what your current setup is (method of redirect, A/CNAME records, etc)? –  MaQleod Jun 10 '11 at 23:24
    
Just edited. Thanks for your time. –  Milli Saboski Jun 10 '11 at 23:44
add comment

migrated from superuser.com Jun 10 '11 at 23:56

This question came from our site for computer enthusiasts and power users.

2 Answers

1) Do a 301 redirect from one to the other. Here is the code you can place in an .htaccess file in your webroot (change your_domain.com to be your actual domain):

RewriteEngine on
RewriteCond %{HTTP_HOST} !^www.your_domain.com$
RewriteRule ^(.*)$ http://www.your_domain.com/$1 [R=301]

2) In Google Webmaster Tools you can set your preferred domain so Google knows which one you prefer.

share|improve this answer
add comment

You can also specify canonical URLs for pages on your site by putting an HTML <link> element with proper information in the page <head>.

For example:

<link rel="canonical" href="http://www.example.com/product.php?item=swedish-fish" />

See "Specify Your Canonical" at the Google Webmaster blog.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.