There are many situations where you might need to redirect your domain to another domain. For example, you might need to redirect your domain example.com/aboutus.php to otherdomain.com/about.php or if you want to redirect all the requests for example.com to otherdomain.com, you can do that too.
Redirection comes in handy many times. To set up a redirection from the cPanel, follow the below steps:
- Log in to your cPanel account
- Click on the Redirects icon under the Domains section.
- On the next page, select Permanent (301) redirection type. From the next dropdown menu, select the domain that you want to use redirection with.
- On the box with “/”, you can put the page that you want to redirect from. For example, if you want the visitors to be redirected from yourdomain.com/AboutUs.php to example.com/about.php then put /AboutUs.php you can also leave the AboutUs.php box blank if you want to redirect the whole domain.
- On the “Redirects To” box, place the domain or URL where your domain will be redirected to.
- www. Redirection: on this section, you can select whether you want the domain with or without www to be redirected. You can select the option to redirect only with www., redirect both with and without www, or not redirect www at all.
- Wild Card Redirect: If you want all the visitors of the source domain to be redirected to the new domain then you can use the Wild Card Redirect option. For example, it will automatically redirect users from olddomain.com/somepage to newdomain.com/somepage
- After you have configured all the settings, click on the Add button and your website will be added.
After you set up the redirect, wait a few minutes, clear your browser cache and try reloading your domain or link to verify if it is working.