In the last two chapters, I talked about Installing WordPress Locally and Building Custom WordPress Theme. This chapter will cover exporting your local WordPress to a web host. Assume you are done with the local WordPress development, it is time to learn how to export and import WordPress. Then you can keep the local version for backup purpose and future development (ie. testing new themes, plugins, and upgrades).
1. Export Local Database
Login to your local phpMyAdmin, select the database from the dropdown. Click on the Export tab:
- Under the Export field, make sure all tables are selected
- Under the Structure field, tick "Add DROP TABLE / DROP VIEW"
- Tick "Save as File"
- Then click Go and it will prompt you to download a SQL file

2. Find & Replace All Local URLs
Open the database SQL file with a text editor. Find and replace all local URLs with your domain URL (eg. replace all "http://localhost:8888/mysite" with "http://www.yourdomain.com").

3. Import The Database
Login to your server cPanel, go to MySQL Databases, create a new database and assign a user. Now go to phpMyAdmin, select the database (the one that was just created) from the dropdown, click on the Import tab, browse the SQL file and click Go.

4. Upload WordPress
Upload the entire WordPress folder to your server.
5. Change The wp-config.php Setting
On your server, open the wp-config.php file. Change the database details to reflect your server settings.

6. Done
Go to your website and everything should work perfect.
Thanks for the easy to undersand report. You have answered all my questions and save me a lot of time wondering what to do.
I have one more question: if you move from one hosting (Godaddy) to another, how to preserve the mailbox e-mails and move them later on to the new mailbox with the same name?
Thanks for the easy to undersand report. You have answered all my questions and save me a lot of time wondering what to do.
I have one more question: if you move from one hosting (Godaddy) to another, how to preserve the mailbox e-mails and move them later on to the new mailbox with the same name?
hey thanks for this :) made a development site switch a lot easier!
Thank you so much for this easy tutorial, and for sharing your knowledge, it saved me.
I’m a first time MAMP user (and first time WP user) and this made getting my site live, not quite a breeze, but definitely do-able.
i just want to ask… on step 4, “Upload the entire WordPress folder to your server” how do you upload the whole WordPress folder through phpmyadmin? Need help on that…
Anyway,
Thank you!
Not through phpadmin, but via your FTP client, or file upload on your server’s control panel. :)
Upload the entire WordPress folder to your server” how do you upload the whole WordPress folder through phpmyadmin? Need help on that…
Not through phpadmin, but via your FTP client, or file upload on your server’s control panel.
i have followed these instrucitons (skipped the custom template since i am using a purchased templagte) but my phpMyAdmin screens look different than yours and i can’t follow them since things are not the same. for example:
OK -Under the Export field, make sure all tables are selected
NO – THIS IS UNDER THE OPERATIONS TAB- Under the Structure field, tick “Add DROP TABLE / DROP VIEW”
NO DROP TAB, its under the export tab and then i have to toggle the custom field Tick “Save as File”
Then click Go and it will prompt you to download a SQL file
ok…then i go to the next set of instructions and import the data base and of course it shows me ERROR…can’t go any further. i have done this 500 x…..
can you help me?
MAMP version 2.1.1
Mac OSX 10.6.8
this is the error:
Error
SQL query:
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
–
– Database: `ftcWP_0915`
–
CREATE DATABASE `ftcWP_0915` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
MySQL said: Documentation
#1044 – Access denied for user ‘rburns’@’10.%’ to database ‘ftcWP_0915′
Thank you so much! This is the best manual on the net. Much better than worpdpress’ manual itself and better than my hosting company’s site, and that’s supposed to be their job. I use this manual with any new site i build, juts to make sure i do everything right.
For those asking how to transfer the files, best option is the use the free ftp software FileZilla. It’s all drag and drop and never does any problems in copying files from your computer to the storage server. The configuration details you can get from your tech support of the storage site.
Thnx again!
sasha
Oh my gosh, your tut saved me from a lot of headaches! Thanks so much!
how to extract wordpress file in html.not xml please solve my problem….
It’s Very nice Article and helping us
http://youknowlinux.com/how-to-install-wordpress-application-manually/
Above link help you for install wordpress manually
Can anyone please help me? Im having this error which says
Unable to open WampServer’s config file, please change path in index.php file
Im not an I.T expert, so simple solutions would be greatly appreciated
How can I recover the old wordpress from a folder where I only copy paste all the info from my ftp? That means i didn’t export the database.
Thanks for the help
David
Thanks a ton for sharing this. I saved a lot of time and efforts to move the site to a new Domain.
Cheers
Aditya
I would have thought another benefit of doing this is it will copy over things like category ID’s which will save you having to search your theme for where you’ve excluded cat’s etc.
Nice one. Now we can do every thing easily on wordpress :)
wonderful wonderful wonderful so its not as hard as I thought>>>thanks a million for making it so understandable….pls do u have such a tut on PHP and MySQL. thanks once again
GoDaddy was founded in 1997 as Jomax Technologies by Bob Parsons, a veteran of the United States Marine Corps. Prior to GoDaddy, Parsons sold his financial software services company, “Parsons Technology, Inc.” to Intuit. The sale provided him with several millions of dollars in the mid-1990s. As a result, Parsons decided to retire. In 1997, Bob Parsons came out of his retirement to launch a new company, Jomax Technologies which later became GoDaddy Group Inc.;`
Please do take a peek at our new blog page
http://www.calaguastourpackage.com
thanks for the nice tutorial. But, i m confused a bit because my server is not located remotely its at my working place and i have full access to it so i m confused regarding where to copy the wordpress files and on my server CentOS 6.3 is installed which makes the task more difficult to achieve..
So, help me… would be thankful for your help…
thanks in advance…