HostArmada Web Hosting Knowledge Base

Knowledge is power! Use that power and achieve total and unconditional control over the Web Hosting Services!

I added a redirect in cPanel, but it is still not working. How to fix it?

Introduction

If you are looking to set up a redirect in the first place and would like some instructions, you can look at this HostArmada knowledgebase article regarding setting up a domain name redirection.

If, on the other hand, you are having trouble setting up a redirect in your cPanel despite following all the instructions, then you can find a solution for the most common issue with that right here if you keep on reading!

I added my redirect in cPanel, but it is still not working. How to fix it?

When you add a redirect with the cPanel interface, the system places redirect rules at the bottom of the .htaccess file. Some third-party applications will ignore your rule because those applications only read rules and configurations that their section of the .htaccess file contains.

In such cases, for the redirection rule to work correctly, you will have to move it at the top of the .htaccess file. To do that, you should open the .htaccess file for editing using the File Manager feature of cPanel or via the SSH service for your Web Hosting Account.

When you open the file, look at the bottom for a code snippet similar to the following:

drupal.user.example.com represents the URL to redirect.

http://cpanel.net/ represents the URL to which to redirect the domain name to.

<IfModule mod_rewrite.c>

RewriteEngine on

RewriteBase /

RewriteRule ^index\.php$ - [L]

RewriteCond %{HTTP_HOST} ^drupal\.user\.example\.com$ [OR]

RewriteCond %{HTTP_HOST} ^www\.drupal\.user\.example\.com$

RewriteRule ^cptest$ "http\:\/\/cpanel\.net\/" [R=301,L]

</IfModule>

Of course, depending on the redirect you have configured, the code we provided will differ and include the domains/subdomains you have redirected instead of those used in our example.

Conclusion

All of this can vary on a case-by-case basis. However, depending on the third-party application, there may be additional steps required to resolve it.

Please bear in mind that most web browsers add redirections to a cache. That means that you and your website’s visitors will need to clear your web browser cache before seeing a redirection and also when you’d like to see if a redirection has been removed.

*Note: Your redirection will also not work if your domain name isn’t pointed via the DNS system towards your HostArmada web hosting account. That can be another reason for it not to be working properly.

Suppose you followed the instructions and did everything you could to complete the redirection. However, if it is still not working, then have no fear, and reach out to us immediately so that we can take a look for you to resolve it!

Was this article useful and on point?

Find out more about HostArmada entire range of optimized Web Hosting Services and take action today on improving your website Loading Speed, Security, and overall Stability!