Set up Mobile Redirect on HostGator

  • Knowledge Base
  • Mobile Website Builder
  • Set up Mobile Redirect on HostGator
  • Duda Support > Mobile Website Builder > Going Live



1.  Login to your cPanel link (HostGator usually emails you this after purchase).
2.  In the cPanel, scroll down to the Files section.
3.  Click on "File Manager."
4.  If prompted, select to edit the "Web Root" folder.
5.  Find the index.html or index.php file of your website. Highlight that file.
6.  Click on Code Editor at the top. A new window will appear.
7.  Find the tag and click directly after it then hit return to create a new line.
8.  Copy and paste the redirect code on the new line you've created. 
9.  Click Save Changes, make sure to wait for the green conformation then browse your site on your phone.

Exmaple Script:

<script src="" type="text/javascript"></script>
<script type="text/javascript">Mobile_redirect("");</script>


Note: You will need to setup this redirect on all pages which you want to make mobile friendly.

Was this article helpful?
0 out of 0 found this helpful

Please Log in as a Pro

Priority Phone Support is available exclusively to Pros. Log in to your Pro account now to see our international support numbers.

Log In
Not a Pro? Purchase a Pro plan!