Home    Articles

 

How to move your wordpress website from one hosting to another

 

By moving your wordpress website from one hosting to another hosting you need to move your files, your database and to make a new connection to the new moved database.

wordpress-logo-14064_500x210

1) Moveing files

The fastest way to move your files, particularly if your actual hosting provider uses cPanel is to compress all wordpress files using zip tool.
All your files will be compressed and are easily downloadable in order to be uploaded to the new hosting.

Now that yoy have the files, login into your new hosting account, upload the files and unzip them in root folder.

2) Moving Database

The database is located in phpMyAdmin (this is the interface), from here you need to export it as *.sql file (text file that contains querys).
In order to export the database, from your cPanel/WHM click on phpMyAdmin icon.
Click on your database ->Export->Go/Export.

A file is downloaded. This file needs to be imported in the new database.
IMPORTANT The new database must be created on the new hoting cPanel/WHM and a user must be created and assigned to that database.
Note: do not forget the new database name ,user and the user’s password.

3) Reconfigure database connection

In order to do this you need to open the wp-config.php file from your wordpress website files and to replace the credentials used at the 2′nd step.
ex:

define('DB_NAME', 'new_name');
/** MySQL database username */
define('DB_USER', 'new_user');
/** MySQL database password */
define('DB_PASSWORD', 'new_password');

ps: These steps are for changing the hosting, not changeing the domain or site url.
In order to do that click here.

by