Move WordPress from Root to Subfolder

Here is the instructions if we suppose that you intially installed your site into ROOT folder (in the link you provided it’s the method called Method II (With URL change) ).

There are two important steps and between them your site may break but it’s not an issue :

I) First you need to update the link in the settings of your site. But you only need to update the WordPress Address (URL) by adding the subdirectory at the end to make it like this www.yoursite.com/subdir.

Now your site can stop working but no worries.

II) Second move all your files to the subdir then copy .htaccess file and index.php file from subdir and put them into the root directory (copy them and don’t move them back you need to have a copy in root and a copy in subdir).

Open index.php file you moved to root and make these changes :

require( dirname( __FILE__ ) . '/wp-blog-header.php' );

become

require( dirname( __FILE__ ) . '/subdir/wp-blog-header.php' );

After this we are done, now you simply need to login to your site and save permalink structure again (without doing any changes) to be sure the url rewriting is updated correctly.

NOTE that your new admin access will be : www.yoursite.com/subdir/wp-admin.

I also advice you to clear your cookies and cache after migration to avoid any issues.