.htaccess file to redirect one website to other website

Discussion in 'Apache' started by ANaveenN, Jul 4, 2011.

  1. #1
    Hello All,

    It's my first post in this forum..

    I would like to redirect one of my website to other website to reduce the maintenance costs, so please provide me the code to place in .htaccess (Linux Version) file and I would like to redirect ALL my OLD website pages to Single Page of other website, so please advice me how to do it???

    For Ex: Olddomain.com to NewDomain.com and ALL pages of Olddomain.com to redirect to newdomain.com/abc.html including home page??? Please advice me.
     
    ANaveenN, Jul 4, 2011 IP
  2. hans

    hans Well-Known Member

    Messages:
    2,923
    Likes Received:
    126
    Best Answers:
    1
    Trophy Points:
    173
    #2
    ADD this into your old site .htaccess

    that permanently redirects all traffic from old to new site
    make sure the folder/file structure on new site is identical TO OLD SITE !!

    OR

    SEE MORE VARIATIONS/options at

    http://httpd.apache.org/docs/2.2/mod/mod_alias.html#redirectpermanent
    http://www.isitebuild.com/301-redirect.htm
     
    hans, Jul 10, 2011 IP
  3. hans

    hans Well-Known Member

    Messages:
    2,923
    Likes Received:
    126
    Best Answers:
    1
    Trophy Points:
    173
    #3
    keep in mind:
    when you permanently move content from one site to another
    as soon as you close your first site account - the redirect disappears and all existing backlinks and related traffic are lost for good

    chances that people do the extra work for you to update all links to your new site is near zero - time is $ !!!
    my own procedure in all such cases is to delete all invalid links and never link to same site/owner again if links are changing

    changing domain name or file structure comes at a price - to be paid by you and never by others
    never expect directory admin to do all the extra effort of modifying your dead links

    before redirecting - think if you can afford to lose all backlinks and start from scratch again
     
    hans, Jul 10, 2011 IP
  4. jenniferhudson

    jenniferhudson Peon

    Messages:
    34
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    well dear you can visit this link and there you can change your old URL redirect to your new URL.
    For further information about this or anything visit our seo services Thanks
     
    jenniferhudson, Jul 13, 2011 IP
  5. rndm

    rndm Greenhorn

    Messages:
    51
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    16
    #5
    Also - you should have a one-to-one match for the content that is being 301'd. I've had GREAT results with 301's where I had a pretty close match content-wise for each redirect.
     
    rndm, Aug 21, 2011 IP