how to move wordpress from root to a new directory on hostgator?

Iam using hostgator and I want to move my wordpress application from the root directory ‘home/username/’ to a new directory which is ‘home/username/mysite’ and the website url should be mysite.com, I tried to do that but now my website url is mysite.com/mysite, so what I could do ?

Related posts

2 comments

  1. Unfortunately, Hostgator cPanel does not allow you to change the root folder of the primary domain to anything other than the default public_html folder yourself. If you really need to do it, you need to contact their migrations department. Also, please note that this only works for a VPS or a Dedicated server.

    There is, however, a workaround to avoid going through this process to achieve the desired result:

    1. Change the primary domain name on your Hostgator account to something else. (mynewsite.com)
    2. Now create an add-on domain with the original domain name. (mysite.com)
    3. Point the add-on domain mysite.com to the new folder that contains the WordPress installation. (home/username/mysite)
    4. Your original domain name will now point to the new folder as you desired.

    It’s not pretty, I admit, but it gets the job done.

Comments are closed.