WordPress: How to Move Your Site to Another Folder
In this article, we will show you how to move your WordPress site from a subfolder or subdomain install, up to your main /public_html folder. This is useful if you have developed a new site in a sub folder and want to move it to your main domain now.
1): Login to SiteAdmin or cPanel (we are using SiteAdmin in this article)
2): Proceed to the File Manager by clicking the File Manager link found in the Website Tools section of the left menu.
3): Navigate to the location where your WordPress in installed. In this article, our WordPress is setup to work in the /blog subfolder.
4): Select all the contents of the subfolder (in this case, /blog). Copy (not move) all the contents of the sub folder into the main /public_html folder:
5): Once the files are copied, log into your wp-admin dashboard for the /*sub* site. Then go to Settings -> General, change the WordPress Address (URL) and Site Address (URL) to the main domain name. (this will likely also kick you out of the wp-admin page after saving, not to worry.)
7:) If you are having issues logging back in, or getting a 404 or other error at the new domain/wp-admin page, check your .htaccess file in the /public_html folder. Remove any references to the old subfolder in the WordPress rewrite rules, such as:
RewriteBase /blog/ or RewriteRule . /blog/index.php [L}
They should read as follows instead:
RewriteBase / or RewriteRule . /index.php [L}
8): After you’re satisfied the site is correct, you can then remove the files for the old site in the subfolder, to save disk space, and keep things clean and organized in your file manager.
You may still have some images or files that are referring to the old URL. To fix these, you can use a plugin such as Velvet Blues to change any left over urls.
For more information on moving your WordPress site from different folders, or from one server to another, check out the official WordPress.org article on moving your site: