Knowledgebase

How to redirect a site using htaccess redirect?

How to redirect a site using htaccess redirect?

The htaccess redirect is possible only in the "Linux" based hosting. First, the "301 redirect" should be made active in the server. Then configure the 301 redirect with the "Apache". 

Use the below mentioned code to redirect a website. 

Redirect 301 / http://yoursite.com/ 

You must replace the word "yoursite" with the URL of the site, for which you want to redirect your site. 

To redirect one page to another page:

Redirect /old-index.html http://www.yoursite.com/foldername/new-index.html

You must replace the word "yoursite" with the URL of the site, for which you want to redirect your site.
  • 0 Users Found This Useful
Was this answer helpful?