Are You Moving WordPress From One Folder To Another?
July 23rd, 2016 | by Ravi Chahar || 10 Comments |
If you are moving WordPress from one folder to another folder then you should know the perfect way to complete the action. After starting your blog, you feel the need to place all the WordPress files in the different folder. Do you know how to move WordPress from one folder to another?
You can’t take the risk while doing such things. So make sure that you have the backup of your website and the database on your hard drive. It is necessary to have the secure side for your website. In this post, I am going to show you the perfect way to move files from one folder to another.
How To Move WordPress From One Folder to Another?
Are you running multiple websites on one account? Are you thinking about creating the static home page for your website and the blog option to place the content of your website? You need to check the location of the WordPress files in your cPanel.
After that, the files should be moved from that location to another location. It can be done simply by copying the files and placing in the new folder. Let me show you the practical:-
Moving WordPress From One Folder To Another:-
Step 1:- Login to your cPanel and go to “file manager” under the “files” section. Make sure that you have checked to show the hidden files. It’s because you won’t be able to copy the hidden files like .htaccess if you unchecked it.
Step 2:- If all the WordPress files are located in the root directory or “public_html” then you can select all the files from here only. Otherwise, you have to open the folder where all the WordPress files are located.
Suppose the files are placed in the root directory. Select all the files by using the “select all” option from the menu bar. If you have placed any other sub-domain in the root directory then you have to unselect that folder.
Step 3:- Click on the “copy” option from the menu bar. You will be asked to set the location of the files to get copied. If you have created any folder then set the location as “public_html/foldername” Suppose the folder is “blog”.
If you don’t have the folder then create one. Don’t forget that it’s case sensitive and if you fill “Blog” in place of “blog” then the files won’t get copied.
If you don’t see any activity for few seconds then don’t fret. The system is calculating the time and the size of the files.
Step 4:- Now is the time to set the location of your WordPress files. You can change the site URL using the database. But here, if you are moving WordPress from one folder to another folder then you have to define the location in the system.
It can be done by editing the “wp-config.php” file. Just find this file in the files and folders you just moved. Right-click on the file and click on “Code Edit” and the file will open in the new tab to edit.
Step 5:- In the file, you can see the database name, database username, database hostname. All the credentials are defined by the using the “Define” attribute of the SQL.
Below all these lines, you have to add two lines to change the location. Just add:-
The motive to move files from one folder to another has fulfilled. All the WordPress files have moved from your old location to your new folder “blog”. You can check it by entering the new URL of your website in the browser like “http://yourdomain.com/blog”.
Let me tell you that you can change the site URL using the phpMyAdmin.
Now Do You Know How To Move WordPress From One Folder To Another Folder?
While doing such technical things, you should have the backup of your website and the database. Make sure that to move files from one folder to another folder, you follow the same process described above. I am sure you won’t like to mismatch any code of your website.
Are you still think about moving WordPress from one folder to another folder? Well, stop think and bring your thoughts into an action. Don’t forget to do the last step. Your website won’t open until you edit the “wp-config.php” file. If you face any problem then let me know.
You can also connect with us on Twitter, LinkedIn, and Facebook.
Excellent tutorial! This is something that all self-hosted WordPress users should know how to do, or at least save you post for when they need it.
I’m passing it along. Thank you!
For a WordPress blog, you should know this kind of things. If you decide to run more than one site and to give the priority to another site then you have to move WordPress from the present location to any other location.
Thanks for your support. You are awesome.:)
Hope you are enjoying the weekend.
Thanks for sharing this awesome resource. You know that the way you showed this tutorial, it is so easy to achieve the goal of moving a wordpress site.
Thumbs up Ravi. Take Care
I am glad that you found it helpful and easy to understand. The newbies need to learn these things so that they can build a better blog.
Moving WordPress from one folder to another folder may be challenging for many.
Thanks for stopping by.
Have a great day.
WordPress is beautiful and easiest platform to start blogging career and here i read you have published many wordpress related tutorial.
This one is fantastic !
No doubt that WordPress is on the best platforms. But for beginners, it’s quite hard to know all the aspects to handle a WordPress website. They should learn more and more about this amazing platform.
I am happy that you found the articles helpful.
Enjoy the stay.
This is an excellent step by step description of how to move your WordPress files from folder to folder.
I’ll be the first to admit that I would not try this by myself, though. That’s why it’s good that there are technicians like you to help us out 🙂
Thanks, I will certainly let others know about this.
It’s the matter of choice that people like to move the WordPress from one folder to another. Some people prefer to place it in a separate folder so that they can add a new website in the root directory.
There is nothing to fear about. You just need to follow the guide.
Thanks for your valuable input.
Enjoy the day.
good one ravi…not now but i am bookmarking for my future use and to share it with my friends
Glad that you found it helpful.
Thanks for stopping by.
Enjoy the day.