HomeWP Hosting

How to Transfer a WordPress Blog from One Host to Another

Whenever you create a WordPress blog, the main objective is to draw large traffic to monetize the effort. The performance of any blog depends upon various factors such as its appearance, content, domain, SEO, speed etc.

The loading speed of any website is one of major factors affecting its performance. With the increasing traffic on your blog the server could not easily handle it. With increasing traffic you need to make sure that your website server is able to handle that much traffic. Also if your website is older then you may face problem of running out of space with older server. The support from hosting company could be a reason to change server.

If loading speed of a website is longer, then most of the user’s will bounce back. If lot of people visit your website but do not stay for long time then surely it is a reason to worry. The websites with high bounce rate is not beneficial for the website owner. The great loading time on your new server, low cost and 100% uptime are some of features for which most of blogs move on to a new and better host.

How to migrate a WordPress site from one server to another

How to Transfer a WordPress Blog to Another Host

Transferring your WordPress blog might be very tricky if not followed properly. It usually takes 30-40 minutes to carry out if done properly and now you can enjoy the new experience on your new hosting provider. You should choose a time to carry out transfer when your website doesn’t get much traffic.

Transferring from one server to another can only be effective if all of your data are secure.

Basically, migrating your WordPress blog from one server to another consists of three parts: Moving the wp-content file, moving your database and reconfiguration (if needed).

Note: Make sure to update your wordpress version, themes and plugins to the latest version because you can’t do it during transfer takes place. One should keep their WordPress version updated anyway to keep their site secure and safe from hackers. Make sure to perform some cleanups such that your database and WP-content size is small. It takes time to carry larger file from one location to another location.

You need to carry those files only which you want on your new server. Delete all the unnecessary files that you don’t want to carry like:-

  • Extra themes and plug-ins.
  • All trash comment, post and spam comments.
  • All cache files.
  • Previous database backup.

This will reduce your database size smaller hence it will be easier to transfer smaller database .sql file. You can also compress database to Zip, if its size is huge for faster transfer.

Transferring WordPress site to New Server

Now you are ready to transfer your WordPress blog from one server to another by following 6 simple steps that I provided.

Step 1: Backup files and Database

migrate wordpress from one server to another

Firstly you have to take a back-up of all the data that you need in your new web server.  These data comprises of two parts i.e. – database and WP-Content file.

For WP Content files:- You need to download all your WordPress files from old host.  These include files from themes folder and plug-in folders. These files need to be uploaded later on new server.

  • If you are using cPanel hosting you can simply login to file manager through cPanel and take a backup of WP-content folder or the entire Home Directory.
  • You can use any FTP client such as Filezilla, WS_FTP, Cute FTP, BigDump and Core FTP for easy and fast download of your files.
    One thing to note that some of FTP does not download .htaccess file, these files are important to maintain permalinks. You can click on-> view -> show hidden files to download .htaccess
  • Make sure to download any folder you are using that is maintained outside of your blog’s folder. For ex. You are using a separate folder Video located outside your blog’s folder than you have to download that too.

For Database – The data on your database need to be exported so that it could link to your website.

move wordpress site to another server

phpMyAdmin:- If phpMyAdmin is installed in your device then you can use this method to export file. Login into phpMyAdmin then.

Click on -> database which contain your blog.

Click ->export in top navigation menu then select the ->quick method to export

Choose format as it is i.e. –> .SQL then click on -> go to start exporting files.

Then select the prompt as Save as File

  • Commandline:- This method is used when you don’t have phpMyAdmin installed in your device. To start, login into your server via-SSH using tool like puTTy as a user to work with server.

Search for WP-config file for following details: (‘DB_NAME’, ‘database-name’);

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

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

/** MySQL hostname */
(‘DB_HOST’, ‘localhost’);

Run this command on your command box: mysqldump –h (host_name) –p (port_number)  –u (user_name)  –p (database_name) > name_of_backup.sql

You need to enter password to continue. You should fill the variable in brackets with appropriate value and do not include the brackets.

Your database backup will be exported in /html folder. Move it to another directory so that no one can download your database information.

Optional Step: When export is complete compress it to make transfer faster.

Step 2: Install WordPress in the new server

Login to your cPanel and locate any of the following tools: “fantastico” or “softaculous”. Once inside the tool, click on the text that says “WordPress”. The WordPress installation will ask for a few basic things like – where the install it which is usually blank for root directory and some optional questions like site title and admin username, email id etc.

It will take a few seconds to install WordPress and the configuration details will be sent via. Email in the email id you provide during installation.

Step 3: Import WP-Content file

The file you have saved should now be imported on the new server for select folders, like the image folder, themes and plugins folder and any other custom uploads that had been made in the previous server.

transfer wordpress site from one server to another server

  • cPanel:-If you have used cPanel hosting then login into cPanel in the File Section click on ->

Under Restore a Home Directory backup click on->choose file and navigate to the location of file you have exported during Step 1. Then click on->Open

Now you see the backup file name, so click on->upload. Now you can see the progress of your files being uploaded.

  • FTP Client: Open your FTP client and connect it to your new hosting account. Upload wp-content file (Backup from old host that you took in the first step) – that way you overwrite the files and add the things that was missing in the fresh install.

… /yourdomain.com/wp-content.

Step 4: Import the SQL file that was exported from the previous server

how to move wordpress blog from one host to another

  • phpMyAdmin:- Firstly login into phphMyAdmin to carry out import. After you logged in-

Click on->database to which you want to import. Then click on ->Import tab at top of page.

In the File to Import section select the SQL based file from your device that you wish to import.

Use partial import if you want to skip no. of code. Use format and format specification left to their default values.

Click->Go to initiate the import. Congratulations! You have successfully imported the database file to your new host.

  • Commandline:- As described earlier login into your server via- SSH. Again check for wp-config file to see the details.

Now run this command on command line: – mysql – h (host_name) –p (port_number) -u (username) –p (database name) < path/to/name_of_backup.sql.

You’ll be asked to enter password after entering password import will begin.

Step 5: Edit the WP Configure file

The configuration file – wp-config is stored in root of your WordPress files. Open it and you’ll find the following details, so change the database details to reflect the new database on the new server

// ** My SQL settings – you can get this info from your web host **//

/* the name of the database for wordpress */

define( ‘DB_NAME’, ‘database_name’) ;

/* MySQL database username */


/*MySQL database password */

define(‘DB_PASSWORD’,’ pass_word’);

/** MySQL hostname*/

define(‘DB_HOST’, ‘local_host’);

After doing this now you have edited the database information with new host values.

Step 6: Reconfiguration

Log into your WordPress panel and activate the old themes and the plugins if they aren’t activated automatically. In most cases it is done automatically but if your WordPress blog is not automatically reconfigured then you have to do it manually.

That is pretty much it and everything should be back to how it was in the previous server. The migration may seem very technical stuff to you but if you follow these simple steps then you can do it by own very easily. Now you can enjoy your WordPress blog on your new hosting server with lots of new features and much faster speed. It will take some time, so be patient while this transfer occurs.

Although I have tried to include all the problems that you may face during the transfer of WordPress site from one server to another along with their solution so you don’t have to worry much. But in case you have any then feel free to ask here.

How do you find this post useful? Please share your views in the comments below.

This article is contributed by Saurav – a full time blogger and a growth hacker at Temok. You can catch him on Twitter and Linkedin.

How to Transfer a WordPress Blog from One Host to Another
5 (100%) 1 vote

Comments (18)

  • Awesome guide…

    You explained it very well….

  • Hi Manidipa,

    Well i consistently follow one blog called blogginglove where Ravi shared magnificent tutorials about WordPress. But this is another lucrative post which contains significant information about transferring a WordPress blog from one host to another.

    Thanks for sharing such a fantastic post 🙂



  • Hi Manidipa,
    Great post!

    Addressed a concern that every site owner has when moving from one host to another.

    With this guide, you made it quite simple.

    Thanks for sharing!


    • Hi Hussain,

      Great to have you here. Yeh, it’s a big concern if one is not happy with the current host. Thank you for reading through and sharing your comment.

    • Hi Omar,

      Glad that you found this post simple and useful.
      True indeed that there are various reasons for which a website owner changes its web hosting server.
      The transfer could only be successful if all your data are secure.
      Hope you have a great week!

  • Great post.

    Recently i used this method to transfer my blog from godaddy to hostgator. It is working like a charm.
    After migration, I faced the image upload problem due to changes in the directory path. So, i changed the path from settings.
    Also, I was created zip file to upload all files and extract files after uploading. I think it is easy to upload one file.

    • Hi Gagan,

      Great to know that you found the post useful. Thank you for sharing your experience of hosting transfer and adding value to the content.

    • Hi Gagan,
      Glad you liked the post and used it!
      You may face many problems like you described because of the change in directory. There might be problem with plugins also due to reconfiguration.
      Creating zip file is always recommended as it makes the transfer faster and your data will also be secure.
      Enjoy new experience on your new host server.

  • Hi Manidipa,
    It was a awesome guide, it will really help many of them to change there hosting, if we encounter any problem from a host provider that can’t be solved and we get frustrated from there service and want to change our hosting, thank you for showing us the solution.

    • Hi Akshay,

      It’s great that you found the article helpful. Thanks you for sharing your views here.

    • Hi akshay,

      As I have outlined there are several reasons to change a server.
      The most of Webmaster hesitate in doing it because of complexity but as you can see it is very easy to change it by own.
      I hope now whenever you feel like changing it, don’t hesitate. Just follow this post and enjoy the features of new server in quick time.
      Thanks for your wonderful input.

  • Within a month I am thinking to transfer my word press site to another host. So, This post will be very useful for me.

    I must say really awesome guide.

  • Nice tutorial, it is really helpful to follow your guide. I successfully migrated one of my website to another host.


Leave a Reply

Your email address will not be published. Required fields are marked *