T U T O R I A L S E R I E S
Moving your WordPress weblog to a new domain name
Unless your new domain name has propagated around the internet fully, moving your blog could make it unreachable for 24-72 hours. This is nothing to do with WordPress - it's just the way it is.
Accessing your blog using a temporary address given to you by your host could also cause errors due to the way WP works. Best really to do this when you have the time, or plan ahead.
First, you must create a database backup. Instructions for doing this are
here or use the excellent and highly recommended plugin from
Skippy.
Secondly, you need to download your entire WordPress installation. Everything.
If you are having to move domains, this is not the time to try and tidy up your install, or to upgrade / change anything. You can do that once it has been moved, and it is shown to be working.
You should now have in your computer two items:
- one or more database backups. Copy these backups again to somewhere safe on your machine so that you do the next stage on a copy.
- all your wp files / folders / images directories
Two alterations need to be made:
- open the file 'wp-config.php' on your wordpress install, and change the details for your new mysql connection. That's the first change done.
- So you need to change your blog address inside the database. Database files can get quite large and opening them can be slow - it could crash your machine too. So let's not do that. Instead, download this file: SCR 1.0.002 Freeware edition (13KB) . Use that to search and replace your website url with your Xampp url.
For instance, here is how I do it when moving it inside my machine. You would replace the old address with your new address:
This should mean that any URL's within your site - for images, areas outside the blog - will still work.
Please do not forget that if you have moved hosts, your passwords will have changed. Double check your new passwords for your mySQL (database) connection and any other passwords that you have in use.
Next, it's time to upload all your files to your new webspace.
Once that is done, follow the instructions
here to restore your database.
This is the last change you need to make.
From your website cpanel, choose phpMyAdmin, and select the database you are using.
You need to look inside the 'wp-options' table, and check that the values in 'site_url' and 'home' are correct.
Do check carefully that they are.
Before checking your new site, clear your cache and cookies.
If after moving everything you get a blank page when looking at your blog, check your themes. A faulty theme file will cause this blank page. Try changing themes or uploading a new theme then changing to it.
If this does not help, check that all the WordPress files are present and are the correct size. Download a new set of WordPress files if needed and use your ftp client to do this.
These pages are independent of http://wordpress.org
All design, content & images © Mark 2004-2008. All rights reserved.