Moving WordPress from a sub-folder to main domain in cPanel:

In most of the cases people need to move an installation of CMS from one location to another, mostly from a sub domain to main domain. In this case it is easy to move the WordPress installation by following the steps that we have mentioned below,

Step 1.

At first you need to login to the control panel

cpanel home.

Step 2.

Then you need to open the File-manager.

Now you can go to the location where you have already installed WordPress.

Step 3.

After that select all the contents of the wordpress installation and copy the entire contents to the main folder, that is public_html folder.

Step 4.

After completing the copy process, you need to login to the admin page of the sub-domain location.

On Settings option go to General tab and change the WordPress (URL) and Site (URL) to the name of the main domain.

Step 5.

Now, it’s done.

In some cases you will get some errors while accessing the admin page, this is because of some links are still there in the .htaccess file. So you can remove the links to the old installation from the .htaccess file.

Ex:

RewriteBase /subfolder/ 
or
RewriteRule . /subfolder/index.php [L}

So you need to remove the link towards the subfolder from the .htaccess file and make it as,

RewriteBase / 
or
RewriteRule . /index.php [L}

Step 6.

Now you can remove the old installation from your account, but before that please do an audit on all the internal links of the website and make sure that it’s working fine.

If you need our help to fix any issues on your server. Please feel free to contact us, simply email to support@iserversupport.com

Monthly server support with Unlimited tickets, 24×7 monitoring, Security Audit and lot more for just $59