1 Reply Latest reply on Oct 18, 2018 2:25 AM by Jack Sparrow

    How to move WordPress to a different domain at DreamHost ?

    Jack Sparrow

      How to move WordPress to a different domain at DreamHost

       

      This article describes how to migrate a WordPress installation between two domains hosted at DreamHost. The example domains used in these instructions are:

       

      Step 1 – Back up your data

       

      You should always backup your data before making any change to your site. View the following article for instructions on how to backup your web site files, database, and any email you wish to keep:

       

      Manual backup techniques

       

      Step 2 – Add hosting for the new site

       

      Add the new domain (newsite.exampledotcom) to your panel. Make sure to set it as Fully Hosted:

       

      Adding a Domain

       

      Step 3 – Create a new database

       

      Navigate to the (Panel > ‘Advanced’ > ‘MySQL Databases’) page and create a new MySQL hostname and empty database.

       

      Create a new database

       

      Step 4 – Transfer your WordPress installation

       

      Transfer your WordPress files you’ve backed up in step one to your new domain. If you had email addresses on the old site (oldsite.exampledotcom), make sure to create the same addresses on your new domain. You can then transfer those emails.

       

      Import your web files using the following article:

          FTP

      Import your database using the Migrate MySQL article:

          Migrate MySQL

      Transfer email from your old domain:

          Email Setup: Use this article to set up your email addresses on the new domain.

          How to import email: This article explains how to import your email to the new domain.

          Email Client Configuration: This article is a guide to different email configurations you can use.

       

      Step 5 – Edit the new wp-config.php file

       

      Log into your new site (newsite.example.com) via FTP or SSH and open the wp-config.php file (this is in your site’s directory). You’ll see the following contents:

       

      define(‘DB_NAME’, ‘exampledatabase’);

      define(‘DB_USER’, ‘exampledbuser’);

      define(‘DB_PASSWORD’, ‘database password here’);

      define(‘DB_HOST’, ‘mysql.exampledotcom’);

      define(‘DB_CHARSET’, ‘utf8’);

      define(‘DB_COLLATE’, ‘’);

       

      $table_prefix = ‘wp_2hdy121d_’;

       

      Update the following:

       

      Database name

      Database user

      Database user password

      Hostname

      Replace the existing WordPress $table_prefix value with the imported $table_prefix value.

       

      Step 6 – Update the Home and Site url

       

      View the following article for instructions on how to update the ‘Home’ and ‘Site’ URL within WordPress:

       

      Changing the Home and Site url

       

      Step 7 – Update all other URLs in the database

       

      After the ‘Home’ and ‘Site’ URL have been updated, you must update all remaining URLs in the database. View the following article for several options on how to accomplish this:

       

      Changing all URLs in your WordPress database

       

      At this point, your website should load normally on the new domain name.

      Summary

       

      Once the above steps are complete, the new site looks exactly the same as as it once appeared on your old domain name.