Transfer WordPress sites to new servers fast and safely

b. Import the database

* Install Adminer, a plugin that manages a blog’s database and is able to import databases. Open its admin page (in the “Tools” menu) and select the “import” option.

Locate the SQL file (it can be compressed) of your backup and import your database. In case that your database is large, let’s say 10 mb or more even when it is compressed, you may face connection issues importing it. Adminer is able to import very large files, but your server may be configured to stop the execution of scripts after a certain time. You can gzip your database, upload it in the directory where Adminer is installed at “wp-content/plugins/adminer/inc/adminer”, making sure it is named “adminer.sql.gz” and import it using the option “From Server,” instead of from your PC.

* After your database is restored you may need to login again, in which case you will be redirected to the old version of your blog, because the imported settings have no idea that you are using a temporary alias url.

To escape this trap, open your wp-config.php file (at the root of your new WordPress installation), using the File Manager of your host or your FTP client, to add these two definitions: