This tutorial will show you how to move your Joomla website from localhost to the live server.
This tutorial assumes you have installed template on your localhost, modified it to your needs and now you wish to move your website to the live host.
Backup. First, make sure a backup of your local installation has been done. We have video tutorial that will show you how to do full website backup.
Copy Files and Directories of Your Local Joomla Directory to the Live Server.. Using your FTP software, upload the entire content of your local site installation to the the live /public_html/ directory on your server. You can check this instruction on how to upload files to server via FTP.
Copy the Contents of the MySQL Database. In Joomla all site content is stored in site database. You need to export your localhost database:
Open your database in PhpMyAdmin tool. On your local system, PhpMyAdmin tool URL will normally be http://localhost/phpmyadmin.
Select the database you would like to export in the upper right-hand list and click Export at the top.
Under Export Method you will be suggested to choose between the two options: Quick export and Custom export. Select Custom export and click Go.
You will get the message prompting you to save backup file on your computer.
You can check our video tutorial on backing up a database for more details.
When export is done, please do the following:
Create the database on your live server.
Open your database in PhpMyAdmin tool on your live server.
Click Import in the top tool bar.
Browse your backup file and click Go.
After the database is successfully uploaded, you should see its tables by clicking on the database name.
Our video tutorial on importing sample data dump file will show you how to upload database backup file.
Adjust the Joomla configuration file.
The last thing you will need to do is to adjust the Joomla configuration file in order to match the database, website URL, log and tmp directory paths.
Open configuration.php file in any text editor on your computer.
You can locate configuration.php file in your live server Joomla root installation folder.
Find the following lines for the database settings:
public $dbtype = 'mysql'; public $host = 'localhost'; public $user = 'database_user'; public $password = 'password'; public $db = 'database_name'; public $dbprefix = 'jos_';
Enter your new database details to the code above.
Then locate the following line:
public $live_site = ‘domain.com';
Where domain.com is your new site URL.
Finally, edit the path for logs and tmp directory. They can be adjusted by editing these lines:
public $log_path = '/home/username/domains/domain.com/public_html/joomla/logs'; public $tmp_path = '/home/username/domains/domain.com/public_html/joomla/tmp';
Change tmp_path and log_path URLs. Local host and live server path differs.
Feel free to check the detailed video tutorial below: