Header Redirect

I would like to redirect my website to another website (domain, location) How would I do that?
 
Redirecting your domain couldn’t be simpler. You can do it two ways. We will explain both methods here.
 
Method One:
 
The number one method is what you would do at your registrar. You would login to your registrar account and forward your domain to a new location (website). Please beware that not all registrars support domain forwarding.
 
Method Two:
 
The second is what is known as a “Header Forward” is a simple PHP file called index.php in your main /public_html/ directory. Please see the code below for it:
 
<?php

header("Location: http://www.example.com/"); /* Redirect browser */

/* Make sure that code below does not get executed when we redirect. */
exit;

?>
 
How to get the file in place:
 
  1. Open notepad copy the above code
  2. Replace “http://www.example.com/” with your domain
  3. Save the file as index.php
  4. Upload the file using your FTP Software to the /public_html/ directory.
  5. Visit your site and it will take you to the site you are redirecting to.