JealousBrother.com official blog

How to Transfer a Wordpress Blog From One Server or Host to Another

http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/digg_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/reddit_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/dzone_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/stumbleupon_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/delicious_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/furl_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/newsvine_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/google_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/myspace_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/facebook_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/yahoobuzz_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/sphinn_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/mixx_32.png http://www.jealousbrother.com/blog/wp-content/plugins/sociofluid/images/twitter_32.png

Introduction:

There are numerous articles that cover the process of transferring a Wordpress blog from one server or host to another but I’ve found that most of them left me asking questions after reading them. I am a very visual person and hope the following article and images help you get your Wordpress blog transferred successfully. The following article was compiled from firsthand experience of transferring two Wordpress blogs from a Godaddy hosting account to my own dedicated linux server.

Step #1 -Backup Your Wordpress Database:

Most hosting accounts include PhpMyAdmin which is what you will use to backup the Wordpress database. The process really isn’t that difficult. The first thing you’ll need to do is find PhpMyAdmin within your hosts control panel. After you’ve logged into PhpMyAdmin you’ll need to do the following.

  • Click on the database you need to back up. It will be located on the top left region of the screen.
  • Click on “Export” on the top tool bar of PhpMyAdmin.
  • Complete the following steps.

  1. In the Export box make sure all of the tables are highlighted and if they’re not click on “Select All”
  2. In the Options box make sure to select the following options in addition to the default settings. 1.) Add DROP TABLE/VIEW/PROCEDURE/FUNCTION 2.) Add AUTO_INCREMENT value 3.) Enclose table and field names with backquotes 4.) Complete inserts 5.) Use Hexadecimal for BLOB
  3. Lastly, towards the bottom of the screen make sure you select “Save as file” and then type a file name that correlates to your website and click “Go”. That’s it, your Database should now be backed up on your local drive.

Step #2 Transfer all of your Wordpress files to the new server:

For the time being I’m not going to cover this step in extreme detail because there are so many different ways this can be done. I chose to use the FTP client FileZilla to complete this task which is free. If any of you would like me to add additional information on this step of the process please let me know and I’ll add it to this post.

JealousBrother.com

Step #3 Create a new Database on your new server/host.

If you’re using Cpanel this task is extremely simple but should be a very similar process on other control panels.

  • Click on “MySQL database wizard”
  • Enter a Database name. This could be wordpress or anything else you’d like. Then click “next step”.
  • Enter a Username and Password. Note: The Password must be entered twice and make sure it’s secure. (variation of numbers,letters, and cases) Then click “next step”.
  • Select “All Privileges” and click “next step”. That’s It!
  • Important Note: Make sure you write down the Database Name, Username, and Password or you’ll have to go back and find that information later.


Step #4 Edit the WPCONFIG.php



At this point you should have already copied all of your Wordpress files to the new server and we now need to modify the WPCONFIG.php file with the new Database information. Once in Cpanel you need to complete the following steps.

  • Click on “File Manager”.
  • Select “Web Root” and make sure “show hidden files” is selected(May not be necessary but better safe than sorry).
  • Find WPCONFIG.php within the file manager. Depending on where you copied the Wordpress files on the server this file should be located in Wordpress’s root directory. (Meaning it’s not located in wpcontent or wpadmin, it’s located in the same directory as all of the wordpress folders)
  • Once you locate WPCONFIG you’ll need to click on the mouses right button and select “Edit”.
  • You now need to alter three (possibly four) different items in the file.

  1. Database Name
  2. Username
  3. Database Password
  4. Database Host (If you’re hosting Wordpress on your own server this should be localhost but may vary depending your hosting situation. If you’re unsure you’ll need to contact your administrator)

  • Note on Charset Value: This value must match the value of your old Database. I left it at the default setting and everything worked correctly but I have read that having an incorrect charset can cause compatibility issues within the Database.
  • Save Changes to the file and you’re done.

Step #5 Import your old Database tables into your newly added Database.

This is a step that caused some serious issues for me when I first tried transfering a Wordpress blog. Whithout completing this step your new database will not function because it doesn’t contain any of the tables or information from your Wordpress powered website. There are a couple of options to complete this task and your choice should very based on the size of your database backup. If you’re database is larger than 10mb in size you’ll likely need to use third party software to complete the task. If you’re Database backup is smaller than 10mb in size you can use PhpMyAdmin to complete the import.

Option #1 Using PhpMyAdmin (Databases under 10mb in size)

Follow these steps when using PhpMyAdmin to complete the import.

  • Click on PhpMyAdmin within Cpanel and login.
  • Click on the Database you created earlier. This database should have a zero next to it representing that it doesn’t contain and tables. It should in the upper left hand side of the screen.
  • Click on the “Import” tab located on the upper navigation toolbar.
  • Click on “Browse” and find the Database backup that you earlier saved to your local drive.
  • Click “Go” and let PhpMyAdmin handle the rest.

Presuming you’re database backup was less than 10mb in size you should now be ready to roll.

Option #2 Using BigDump (Databases over 10mb in size)



One of the Wordpress blogs I transferred required the use of BigDump which is an amazingly useful tool. Don’t be scared to use it, it’s extremely easy to use. Follow these steps if you’re using BigDump to complete the import.

  • Create a temporary folder on your server using “File Manager” in Cpanel. The reccommended name for the folder is “Dump” but it doesn’t really matter.
  • Upload bigdump.php and your database backup(example – wordpress.sql) into the “Dump” temporary” folder.
  • You now need to edit bigdump.php with the same process you used to edit WPCONFIG.php earlier. Use file manager within cpanel, right click on bigdump.php, click “edit”, and then proceed to modify DB host, DB name, Username, and Password. Save changes!
  • You now need to load bigdump.php in your browser. Open your favorite browser and enter the location of bigdump.php (example: http://www.yourdomain.com/dump/bigdump.php) Once loaded you’ll see the BigDump menu and you should see your database backup listed.
  • Click “Start Import” and let BigDump go to work.
  • You will see an activity page and will see a prompt below the activity page informing you when BigDump has completed the task.

Final Step: Don’t forget about your Nameservers!

Depending on your situation you will likely need to alter your Nameservers with your domain registrar. In some situations you can continue to use the Nameservers provided by the domain registrar as long as you make the necessary modifications on your new server/host. It should be noted that a lot of other people suggest changing nameservers earlier in the process but I refrain from doing that because of some issues I had with DNS on my server the first time I attempted the transfer.

In Closing

I hope you found this article helpful and if anyone would like me to add more details on any of steps in the process please let me know. If you found this article helpful I would greatly appreciate you sharing it with others. You can use the sociable links below or share it on other networks that aren’t listed. Thank You!br

25 Responses to “How to Transfer a Wordpress Blog From One Server or Host to Another”

  1. I would just ask the new hosting provider do this for me. It will save me time and prevent major error.

    Posted on by: Hamdani
  2. Hamdani,
    Your approach is definitely the easiest and should result in your website getting safely transferred. However, I’m not sure that this is a service that most hosts provide. At least not free of charge. There is also a lot of people like myself who run their own dedicated machines so it’s up to us to accomplish this task on our own. Thanks for stopping by.

    Posted on by: bigkazzyry
  3. [...] A Complete Guide to Transferring Wordpress From One Server or Host … [...]

    Posted on by: Looking For The Best WordPress Host?
  4. You know how you tell yourself you are studying because you have your certification books opened in front of you? But you are really clicking on Stumble Upon to find interesting posts to read?

    Yeah well, I came across yours and had to write to tell you I enjoyed it very much. I gave it the thumbs up, so more people can come across it and enjoy it also.

    Posted on by: Georgia Stath
  5. This is a very good information. Thank You very much for doing this. Actually I saw this post by searching the way to find the transfer of my site bollygossips.com from one server to another server.
    So this method will help me to change the database from one server to another.
    Thank You again.

    Posted on by: Ajit
  6. Thank you very much for your article. I find it very scary to move your beloved website from one place to another. I’m currently working on it now (as I write this), and almost p***ing my pants, because I don’t want to lose anything…. anyhoo – thanks again for writing this how-to…

    Posted on by: Parnuuna
  7. You are very welcome and I hope the article helps make the process less stressful. If you come across any questions I might be able to answer please don’t hesitate. Best of luck on the transfer.

    Posted on by: bigkazzyry
  8. Success! Thanks so much for posting this. I transferred a wordpress site flawlessly!

    Posted on by: MapleWebsites
  9. You are very welcome. I’m glad the article helped you out.

    Posted on by: bigkazzyry
  10. Okay probably the most pathetic question ever…

    In step 2, do I upload all the WP files such as the WP Version, Theme, Plugins?

    Posted on by: mimo
  11. @ Mimo
    That’s a totally legitimate question and yes you’ll want to transfer all of your files and directories. Just make sure you edit the wpconfig (Step #4)(The one copied from your old server/host) to match the settings of your newly added database. (Step #3)

    Let me know if you have any further questions.

    Posted on by: bigkazzyry
  12. Jealous Brother!!

    I love you guys! I’m glad I found your site. Before JealousBrother.com, I looked through other websites and it was confusing. I’m glad you had pictures and all.

    I finally did it (I tried it last night but it didn’t work due to the change in Name Servers.. no changes in Name Servers was in effect until this morning). Then I decided to give it another try today and it worked! Woo hoo!

    Just out of curiousity… in step 2, do I have to “install” wordpress again? For myself, I set up Wordpress after I transferred the files on Filezilla. So I had a new password.

    Then when I was finished step 5… I couldn’t log in from Step 2 (new password). I decided to give a try by using my old password (from old database) and it worked. So my question is, is it unnecessary to go through the installation process in step 2? Since once I’m done with step 5, I can automatically log in as usual (from old database)?

    Thanks Jealous Brothers!

    Posted on by: mimo
  13. @ Mimo

    Thank You and you’re very welcome. I wrote this article after having the same problem you did in finding confusing sources of information. I’m very glad it helped you. There are so many steps I’ve even bookmarked the article myself as a quick reminder when the time comes for me to transfer one of my many WordPress blogs again.

    In regards to your question: I may be a bit confused at what you’re referring to. You shouldn’t have to setup a new Wordpress account, that is done only one time (when you set your blog up originally).

    Answer me this, are you referring to step 2 of the “Famous Five Minute” Wordpress installation or the directions in the above blog post? Step 2 on this blog post is to transfer all of your files to your new server/host. (This is why I’m confused)

    Here’s what I think you’re looking for: My answer would be no, you do not need to install Wordpress again that was done the first time you installed the blog and by completing step 5 you have successfully imported all of your database tables into your newly created database on your new server/host. Once the nameservers are changed everything should be fine and exactly how you remember it.

    Here’s a bit of advice one of the tech guys gave me from my server company (In regards to your nameservers not changing immediately. Chances are it was cached on YOUR ISP, meaning your blog was visible to everyone else but you. Sometimes your local dns server(for your ISP) can cache (store information)data. If you’re on a windows based machine you can always try the following. Open “Command Prompt” on your pc and type: ipconfig/flushdns (Have to open the command prompt as administrator).

    Posted on by: bigkazzyry
  14. Hi Jealous Brother,

    Yes, I was referring to the Famous Five Min. Installation. Thanks! Now I know not to go through the installation process again. Haha. Thanks for the tip and advice!!! You made my day!

    Posted on by: mimo
  15. You are very welcome Mimo.

    Posted on by: bigkazzyry
  16. Hey, can you email me back about this? I have done everything you said but the only that doesn’t work are images. Individual images work but nextgen and wordpress galleries wont display. They show up in the media folder and in the nextgen gallery. Any ideas?

    Posted on by: Spewf
  17. [...] If you would like to view this article with images, click here: Article with Images [...]

    Posted on by: How to Transfer Wordpress From One Server Or Host to Another :: What is a Blog
  18. [...] If you would like to view this article with images, click here: Article with Images [...]

    Posted on by: G4b1Dev » How to Transfer Wordpress From One Server Or Host to Another
  19. [...] If you would like to view this article with images, click here: Article with Images [...]

    Posted on by: How to Transfer Wordpress From One Server Or Host to Another | Best info.
  20. Hi, I have done all you said but the images like the top comments do not work. kind of stuck any help would be grateful. thanks

    Posted on by: art
  21. Art,
    Another individual had a similar problem. The following is the email message I received from them once the issue had been fixed. I hope this helps, let me know if it doesn’t and I’ll try and help you find a solution.

    ————————————————————————————

    Hey, I figured it out. For some reason the new server didn’t like the paths to the images. I went in and had to change the path to wp-content/uploads/5/3/22.jpg instead of having the http://

    I appreciate you emailing me back though!

    Posted on by: bigkazzyry
  22. Post transfer tip. I found I needed to goto Settings>>Miscellaneous Settings in wordpress and put in the correct upload path for the images. Otherwise i got an error message “Unable to create directory ….. Is its parent directory writable by the server?” when uploading new pictures.

    Posted on by: Jeff
  23. Jeff,
    Thank you for the information. I’m sure other visitors will find it very useful.

    Posted on by: bigkazzyry
  24. Wow,it’s wonderful tutorial..but I haven’t still convince yet to do this now,maybe someday!

    Thanks for this post.

    Posted on by: Mattress Cover
  25. [...] of the MySQL database. This is probably the most tricky transfer but you can read up on it at: http://www.jealousbrother.com/blog/transfer-wordpress-blog-serverhost/Payment – This is the big one. Usually you will need to pay at close, or within a given time [...]

    Posted on by: Ultimate Social Bookmark « Share Social Bookmarking

Leave a Reply: