+321 123 4567
info@test.com
  • Home
  • My Services
    • Web Design
    • Web Development
    • Technical Writing
    • Portfolio
  • My Thoughts
  • Free Tools
    • Photo Editor
    • Avatar Generator
    • Email Migration Tool
    • QR Code Generator
    • RSS to HTML Converter
    • IP Address Geolocation
    • Base64 Image Encoder
    • NATO Translator
    • All Tools
  • Contact
Home
Web Hosting
Redirect Subdomain to Addon Domain to Avoid Duplicate Content on Google Search

Redirect Subdomain to Addon Domain to Avoid Duplicate Content on Google Search

Wale Adekile
June 17, 2012

The other day I ran some weird google search and saw something that looked rather scary – my sub domain which actually poited to my addon domain was indexed on Google search. Let me make this clear, doncaprio.com is an addon domain on 9jaclub.com. As you know, an addon domain is a subdomain using a custom domain name.


My hosting account is registered with 9jaclub.com and this is the main cPanel domain. I can create unlimited addon domains but when creating an addon domain, a subdomain is always created in the process.

This blog is actually doncaprio.9jaclub.com using doncaprio.com as custom domain. What most webmasters fail to know is that when your blog is available on both address, you can be penalized for having duplicate contents as both are treated as different blogs by google. Once you create an addon domain, you must redirect the original subdomain to the addon domain. If you fail to do this, you’ll have duplicate conetents and I tell you, it isn’t good for SEO.

How do I remove my subdomain from google search and redirect to addon domain

You only have to do a 301 redirect and when search engines reach your subdomain, they’ll understand it’s been permanently moved to the addon domain.

how to redirect subdomain to addon domain to avoid duplicate content on google search

– Log in to cPanel


– Navigate to our addon domain directory

– Edit your .htaccess file and in the very last line, add the piece of code below:

<IfModule mod_rewrite.c>
RewriteEngine On

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

</IfModule>

– Save the file and check your subdomain to see if it redirects or not.

– Be sure to change the following:

doncaprio.9jaclub.com – Change this to your original subdomain that points o the addon domain


www.doncaprio.com – Change this to your real addon domain

As time goes on, the subdomain will be removed from google index.


Previous Post
How to Share Your Computer Network Connection with iPhone / Android / Symbian Phone / other PCs
Next Post
Adding Pagination (Numbered Navigation) to MobilePress
Wale Adekile
Husband to the world's most beautiful woman and father to two awesome kids. A nerd, obviously; also, a technical business analyst, a web designer who preaches the gospel of WordPress, and a writer. You can check out my published books on Amazon.
Web Hosting

Top Free Mobile Site Builders / WAP Hosts

15 years ago
man using a computer
Web Hosting

Choosing the Most Suitable Web Host

9 years ago

Recent Articles

yunmai massage gun mini 2.
Yunmai Massage Gun Mini 2 Review
BenQ LaptopBar Review: The Accessory I didn’t Know I Needed
teendow g20
Teendow Robot Vacuum G20 Review
Yunmai EasePro Massage Gun Review
bathroom
Dear Men, Spraying All Over the Toilet Seat is Disgusting and Irresponsible
winx mediatrans
How to Transfer Photos from iPhone to Computer Without iTunes
How to Use WhatsApp on an iPad
Things to Consider When Buying a MacBook
programmer
Learning to Code: A Comprehensive Guide for Beginners
identity thief
How to Efficiently Prevent Identity Theft

All contents on this blog are copyright protected and cannot be reproduced on other websites without permission.

Copyright © 2022 – NerdieDad | Home | Contact | About | Privacy Policy