Probably the most unnerving thing you’ll need to do when you’re designing your own website (or if you do it for a living, other people’s websites) is migrate it from one place to another.

It’s quite common for designers and developers to use a staging domain for developing a new website (e.g. a subdomain like client.yourdomain.com) or creating it locally using a program like MAMP. Though even if you aren’t a professional you’ll still be responsible for migrating your website if you need to move hosting providers so it’s still a good bit of knowledge to have.

Even though it may feel that so much can go wrong when transferring your website, you do have quite a few options to help you along the way. We’ve detailed a few ways that you can effectively migrate your website, ranging from complete plugin solutions to the manual method. Let’s go!

 

Using All in One Migration

 

All in One Migration is simply our favourite way of migrating websites and that’s why it is at the top of our list. The plugin allows you to wrap up your website and database into one file, making it simple to transfer your website hassle-free.

 

 

The plugin allows you to build in a search and replace function, which is really handy if you are moving a website from a staging domain to a live website (otherwise your migrated site would still point back to your staging domain).

To begin, just install the All in One Migration plugin on the source website, go to the “export” tab on the left hand side and fill in any search and replace details (leave this blank if your domain name is remaining unchanged, as it would if you are only moving hosts). The export will start and once complete you’ll be able to click the animated button to download your website and database file.

 

 

Next, you’ll need a new WordPress installation in the location that you are looking to migrate your website to. If you have access to cPanel and a half-decent hosting provider, you’ll be able to use Softaculous (yeah, we can’t pronounce it either), an app that allows you automatically install many widely used frameworks, to install WordPress automatically. Thankfully this means we don’t need to bother creating a new user or database as we will for the following methods. Just make sure you note what the admin login details will be or change them to something memorable if you prefer.

The process of installing WordPress is quick and once complete log in to the new installation. Install AIO Migration again and this time select “import”. Drag the backup file and simply follow the on screen instructions. Once this process is complete you’ll have migrated your website!

Note: If you are moving a site from a staging site to an already live website, simply log in to the live website, install AIO Migration and import the backup file. No need to create a new installation or any of that other guff.

 

Using Duplicator

 

The Duplicator plugin is another nice solution, although in our experience has a few drawbacks. If your website is small it is the quickest and easiest way to migrate your website, however if you’ve been online for a number of years it’s likely that Duplicator will find it difficult to export your site on slow web hosts.

On this basis, if your website is small start by installing the Duplicator plugin on the source website. On the left hand side admin menu and select “packages” followed by “Create new” in the top right hand corner. Once you’ve then clicked the orange “Next” button Duplicator will run and determine the health of the site in preparation for exporting. If you receive a green rating on all of these factors you can proceed with the export and download the backup file and the “installer.php” file.

 

 

Armed with your downloaded files, jump on the cPanel of the live website. Although Duplicator does not require you to install WordPress first, you do have to create a new user/password and database for the migration. Simply google how to do this as it is really simple, but make sure you make a note of the username and database name you create. When you’ve added a database you’ll need to upload your backup and installer files via the file manager into the folder of the new website (normally this is the public_html folder).

To initiate the migration, visit your domain followed by /installer.php. For example this would be yourdomain.com/installer.php. Through this process you’ll need to input the database name and user/password before completing the process. Once you’re done Duplicator will handle everything else, leaving you to log in to the migrated website and remove the installation files (this is simple to, Duplicator will guide you how).

Top tip: We use duplicator to start every website design project. We have a duplicator export file that contains a base installation of all of our websites. This includes the CSS we commonly use for most projects, our most used plugins as well as page structures. Every time we begin a new website we simply drop the installer and backup file, import it and we’re ready to go!

 

The manual method

If you’re a purest, or your website host doesn’t allow plugins to operate in this way, you might prefer/need to migrate your website the old fashioned way. This will involve manually move across all of your website files, doing the same for your database and then reconnecting everything.

 

 

To begin, you’ll need to log in to the cPanel of your source website. In file manager you should be able to download all website files typically located in the public_html folder. You’ll need to download all files here, including any folders that begin with “wp-“. Once you have downloaded all of these items, jump on to the cPanel of the hosting that you are transferring your website to and re upload them all. It’s easier to use an ftp client to do this (here’s a good guide).

Once you’ve transferred your files across the next step is to move your database. First you’ll need to find out which database is the correct one for your website (unless you only have one). Once you’ve uncovered this, go on to PHPmyadmin within your cPanel and find “Export” in the top menu. This will download a .sql file.

 

 

The second to final step involves creating a new database back in the live hosting panel. Again, ask Google how to do this if you are unfamiliar. Once you have a database go into PHPmyadmin again, this time going to “Import”. Don’t worry about changing any of the settings and upload the database backup.

 

 

Now that your database and files have been moved across, the final steps involve amending a few things. You’ll need to go into your file manager and locate the wp-config.php file in your public_html folder. Within this file you’ll see 3 lines relating to your database name, username and password. Just swap what ever is in these areas with your new database name, user and password.

And that’s it! You’re done. If you have any issues with pages returning 404 errors, you just need to go into your WordPress dashboard and find Settings > Permalinks. Just press save changes without making any amendments to the options to reset your structure. Everything should now be sorted.

 

Final thoughts

And that’s it! 3 different ways for you to migrate your website. We hope you’ve found it useful and as always, let us know if you have any questions.

 

3 Ways To Easily Migrate Your WordPress Website ultima modifica: 2018-11-09T20:34:36+00:00 da Liam Pedley