Moving a WordPress webstite from server to server, to another domain, How?

A quick outline on moving a WordPress website and changing all the permalinks to the new location.

 

 

Database

  • Step 1 : Backup You MySQL database as an .sql dump file
    • Tip: If you database is large export the tables only first then export the data separately.
  • Download and save the dump files locally.
  • Setup a replica database and import the exported dump file. (all files if you have made multiple)
  • In the database (new location) you will need to update the “options” table the two records point to your domain name (original website) by entering you new location domain name here.

Files

  • Step 2:  Login to the server (usually through a file manager) or FTP manager and make a *.zip or .Rar archive of the entire root directory of your domain. (the entire website)
  • Download this file once finished and unzip to the (desired root directory of the new server location)
  • Change – wp-config.php – the database and user name to the new database setup for the new location

Database Posts/Pages Records

Plugin – If you are using commercial plugin editors like WordPress bakery or have saved direct URLs in you website editor. It can be a nightmare fixing all the urls pointing to the old domain

  • Step 3: – Ok now login to the new ly located WP website and install the following plugin. (this will allow us to do a find and replace in our MYSQL database for the original URL’s to the newly located webstte URLs)
  • Download: Better Search Replace: Recommended if moving your WordPress website as a developer manually from location to location.
  • you will find it in tools in the dashboard search for you old domain name and replace with the new one if you you have one – the new location of the moved wordpress website.

 

 

A few things to note.

  • COLLATE= can cause errors in import and export files, sometimes finding a good text editor and doing a find replace can remove these import errors
  • “/////////” – this can sometimes become an insure from Woo Commerce Australia Post Plugin by Elex – when exporting payment tables it creates hundreds of lines in the dump files. If you do a find a replace for this in the dump archive and save, this should allow you to import the records.
  • The above “////////” can also cause the text editors to break the files and find and replace wont work, you will need to find and delete manually using a text editor.
  • A great text editor is Notepad++ – get it free or use my power as a reseller and website developer to get a discount through me.
  • Remember to check the .htaccess file! – you may need to remove or edit this to make it work locallyWindows and IIS
    • for permalinks in IIS – web.config file
    • Check file permissions
    
    

     

Hope this helps.

IIS WordPress Permalinks web.config Example