How do I set up a 301 redirect?

2 replies
  • SEO
  • |
According to website grader, I need to make a permanent redirect for my website. It said that I am not getting credit for www.mydomain.com and mydomain.com. Website grader said once I do that I will get full search engine credit for my backlinks. Thanks Steven.
#301 #redirect #set
  • Profile picture of the author cassidywilliams
    This is easy.

    Go to the root directory of your server and edit a file called .htaccess (if you haven't got it, create it).

    Inside that file insert the following lines (replace yourdomain with your domain name):


    Options +FollowSymLinks
    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^yourdomain\.com$ [NC]
    RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [R=301,L]
    {{ DiscussionBoard.errors[645651].message }}
    • Profile picture of the author ShabirAli
      very well said bro, i was looking for this too.
      Originally Posted by cassidywilliams View Post

      This is easy.

      Go to the root directory of your server and edit a file called .htaccess (if you haven't got it, create it).

      Inside that file insert the following lines (replace yourdomain with your domain name):


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

Trending Topics