Help! What is correct 301 redirect .htaccess code?

2 replies
  • SEO
  • |
Hello fellow warrior,

I am trying to create the 301 permanent redirect for my client. I am done searching in the google, but it give me a lot of versions, now i am getting even confused of what to do.

Anyone can shoot me the working 301 permanent redirect .htaccess code that is working for your site?

Thanks in advanced.
#301 #code #correct #htaccess #redirect
  • do yourself a favor and go into google webmaster tools forums, you will learn exactly what to do there in 2 minutes, you should learn this for yourself and the particular situation you are working on, you don't want to get back info that could screw something up.
    {{ DiscussionBoard.errors[2258563].message }}
    • Profile picture of the author cheyingtan
      Originally Posted by TargetedTrafficSolutions View Post

      do yourself a favor and go into google webmaster tools forums, you will learn exactly what to do there in 2 minutes, you should learn this for yourself and the particular situation you are working on, you don't want to get back info that could screw something up.
      Thanks for your help. Actually I had been spending more than 2 hours looking at that already..
      Instead of headache on this, I posted my code at the bottom. Is my code correct if I want to redirect my domain from non-www version to www version?

      Options +FollowSymLinks
      RewriteEngine On
      RewriteCond %{HTTP_HOST} ^abcd\.com$ [NC]
      RewriteRule ^(.*)$ http://www.abcd.com/$1 [R=301,L]
      {{ DiscussionBoard.errors[2258626].message }}

Trending Topics