Move WordPress Site to Another Server

Move WordPress Site when you need to transfer server to another new server or sometimes if your website got attacked by malware then you will need to transfer website to New Cpanel. Recently Dewbloggers got malware attack so in order to clean malware completely i have created new cpanel within same server and moveed WordPress site for fresh installation.

Read: WordPress Fresh Installation to Recover from Malware

I have seen that many of newbies feel complex while using WordPress So i understand how complicated for them to grasp part of moving WordPress site. Finally resolved to publish a tutorial in detail which will help anyone, even a newbie to move a wordpress site blog from one host to another in less than 30 minutes with zero downtime. Make sure you read and understand it before you apply it because messing up your database may cost you a lot of money.

Basically we have to took care of two things i.e Website Files and Website Database.

Ways to Move WordPress Site

1. Using Server Cpanel

Most of the server is using cpanel which is good and easy to access, firstly login to your Cpanel from where we will move WordPress site to another Cpanel or server. Scroll down and you will find “Backup Wizard” option under “Files” Tab.

move wordpress

It will come up with more options where you have to select “Backup” then Click on “Home Directory”. You should then be taken to another screen where you can download your Home Directory in the form of a zip file. Sometimes it will download the zip file to your actual web-space. If this is the case, then once it has backup, you will have to download it to your computer from your web-space using an ftp.

Secondly you have to click on “MYSQL Databases” to backup database of website.

database backup

Now we finally have full backup of server, in order to restore whole backup follow below steps to execute proper restore.

Move WordPress Backup to New Server

Let’s restore WordPress site backup that we have taken before, now we have look for downloaded backup data in your computer.

* Firstly we will restore “database” to new server So just Log in to your new web hosting cpanel, go to Back Up Wizard (like we did before), this time click on Restore. Choose “MySQL Databases”. On the following screen, use the field to browse your computer for the zipped database file that we downloaded from previous web host. Click “Up Load”.

That’s it for our database for now. We’ll come back to it later on to make it working.

* Look for “Home directory” zip file to unzip that because I didn’t need all files from backup So after unzip you will find some files Go to “public_html” folder and you will find your domain name folder this is the place where we have all data. Now zip that domain folder and i recommend to use server ftp i.e Cpanel to upload backup data.

* Go to your New Cpanel file manager then public_html or www folder then upload your previous domain name zip file. After uploading unzip that file and delete zipped file, now we have core files data let’s move to restore database.

* We need to create new user for our backup database So Go to “Databases” and click on “MYSQL Databases” it will come up with all databases and users you have on  New server. Under databases tab you will find MYSQL users use that to create user for database to execute it properly with backup database. Give name to your username and copy password (use password generator) with you because we have to edit some files.

create database user

* Add New User section that we’ve just used, there should be another area “Add User to Database”. From the drop down menu choose are new user’s name, and choose the appropriate database from the the drop down menu directly below. Click Add. On the following screen, grant the new user all permissions and click OK. Let’s move on to server file manager because we have to make some changes.

Update Config to Execute Database

Go back to cpanel, click on “File Manager” and go to where we uploaded the WordPress Home Directory to, there will be a file called WP-Config.php. We need to edit this file. Highlight it and click on “Edit” at the top of the screen.

file manager

edit config file

On the next screen you will be presented with a screen of text. Look for the following (should be near the top of the page), and edit it appropriately with your new user info that we created before.

// ** MySQL settings – You can get this info from your web host ** //
/** The name of the database for WordPress */
define(‘DB_NAME’, ‘new_database_name‘);

/** MySQL database username */
define(‘DB_USER’, ‘new_username_here‘);

/** MySQL database password */
define(‘DB_PASSWORD’, ‘putyournewuserpasswordhere‘);

I’ve highlighted in red the parts you need to edit. Click Save when you’ve finished.

Troubleshooting

* Permalinks-  You must look for old permalinks to use them in new otherwise your link structure will crash and it will come up with 404 errors. Check under permalinks via Permalinks options page in you WordPress Admin area (Settings=>Permalinks)

Read: Create Custom SEO Friendly URL

* DNS update- Your WordPress site will not alive till you made new server DNS update vie using Name servers. You will need to change the DNS settings (Domain Name Servers) with your domain hosting provider (ie. Godaddy, NameCheap etc). It will took around 48hr to update Name servers So don’t worry if you didn’t get it in secs.

Checklist to Move WordPress Site

1. Back-up and download the content on your old hosting account using “Back-up Wizard” in cPanel.

2. Use “Back-up Wizard” to also download your MySQL Database from the old hosting account.

3. Use cPanel “Back-up Wizard” on your new hosting account to upload your MySQL Database.

4. Unzip your Home Directory back-up and use FTP Client to upload the relevant blog files to new the web host account.

5. Use MySQL Databases option in cPanel to create a new User.

6. Use the same MySQL Databases screen to associate your new User with the relevant MySQL Database.

7. Update your Config.php file with the new User info

8. Permalink structure should be matched to previous.

9. Redirect your DNS settings and wait for them to resolve.

10. You are Done!

I hope you easily able to move WordPress site to another server If you still got any problem or confusion comment us below we will help you ASAP!

About Amar Ryder


Amar Ryder is Passionate Blogger and Site designer. He used to learn about Social Media and Internet Marketing to Achieve his Dreams. He writes about WordPress, SEO, Online Money Making, Blogging etc.

Join Our Newsletter

Join over to get free and fresh content delivered automatically each time we publish.

Speak Your Mind

*

CommentLuv badge