> ## Documentation Index
> Fetch the complete documentation index at: https://kb.hosting.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Changing the website URL in Joomla

> Learn how to change the URL setting for a Joomla website in this article.

This article describes how to change the URL for a Joomla website. You may need to do this, for example, if you migrate an existing Joomla site to a new server, and the site does not display correctly.

## Changing the website URL

To change the URL setting for a Joomla site, you must modify the *configuration.php* file. This file contains many site configuration settings for Joomla.

To do this, follow these steps:

1. Using your preferred text editor, open the *configuration.php* file in the directory where you installed Joomla.

2. Locate the line that begins as follows:

```
public $live_site =
```

3. Edit the line with the correct site URL. For example, if your site were located at *[www.example.com](http://www.example.com)*, you would type the following:

```
public $live_site = 'http://www.example.com';
```

<Warning>
  **Important**

  If the **\$live\_site** setting is blank, do not change it. Only change it if a domain name is already defined.
</Warning>

4. Locate the two lines that begin as follows:

```
public $log_path =
public $tmp_path =
```

5. If necessary, edit the paths so they match the complete path to the Joomla installation in your *public\_html* directory.

6. Save your changes to the *configuration.php* file.

## Related articles

* [Optimizing Joomla](/docs/optimizing-joomla)

* [Troubleshooting database connection errors in Joomla 3.0](/docs/troubleshooting-database-connection-errors-in-joomla-30)

* [Enabling SSL for Joomla](/docs/enabling-ssl-for-joomla)
