I am starting a music blog at www.domain1.com. That URL is an alias shared with www.domain2.com which is just a domain I happen to have hosting with but is unused. In the future I may want to develop a site at www.domain2.com as a portfolio site but for now I have www.domain1.com that I want to use with my hosting. At first I had www.domain1.com forwarding to www.domain2.com/domain1 and masking that URL so visitors would only ever see www.domain1.com but the URL never changed when people navigated and not having unique URLs is bad for many reasons. I also tried that because it would allow me to be able to develop sites at both domain2.com and /domain1. However, the unique URL thing is an issue. So I ditched that idea and I created an alias. Great! Now I have unique URLs. However now the same content displays at both domain2.com and www.domain1.com. Not great. My question is how do I tell Google that for the content that is at domain1.com to index that site and don't credit www.domain2.com so I avoid duplicate content issues? Do I add this to the config file?RewriteEngine onRewriteRule ^(.*)$ domain1.com$1 [NC,L,R=301]
Using an alias on my domain. How do I tell Google that I want it to only index the alias to avoid duplicate content?
url;duplicate content;url rewriting;canonical url