1. Knowledge Base
  2. >
  3. Results
  4. >
  5. WordPress Home Fix

WordPress Home Fix

If the links in your WordPress site show the wrong domain, redirect to another site, or are missing images or styling, this is typically due to an improperly configured URL in the database for your WordPress blog.

To resolve the issue, you will need to update your domain in WordPress; this update will also be necessary to make your blog display and function properly with your temporary web address or secure web address.

HostGator recommends making a full cPanel backup before making any major changes to your account.

Jump to a Section:


Update WordPress Domain with Softaculous

You can use Softaculous for WordPress simple administration management. You can easily modify database entries in a comprehensive environment, allowing you to change the target domain of your installation in just a few steps.

  1. Log in to your cPanel.
  2. Look for the Software section, then click on Softaculous Apps Installer.

    cPanel - Software - Softaculous Apps Installer Icon

  3. This will open the Softaculous interface. At the top of the page, it will present you with options for your installed scripts. Click on the Installations box.

    cPanel - Softaculous Apps Installer - Installations

  4. Locate the domain for which you want to edit the installation and click the pencil  Softaculous Edit iconicon.

On this page, you will have the option to edit a number of settings for the installation.

Installation Details

This section displays information and where you can edit your installation details, such as the Directory, URL, Database information, and auto upgrade settings.

HostGator Softaculous Installation Details


Update WordPress Domain with Database Access

To update an improperly configured WordPress domain or a secure web address for your WordPress domain via your database, follow the steps below:

  1. Log in to your cPanel.
  2. Check the wp-config.php file in the appropriate directory to get the WordPress database name.
    1. Navigate to the Files section, click the File Manager icon.

      HostGator cPanel File Manager

    2. Find the line:
      define('DB_NAME', 'username_wrdp1');
    3. Copy or remember the database name (i.e., username_wrpd1).
    4. Exit the File Manager and return to cPanel home.
  3. In the Databases section of cPanel, click on the phpMyAdmin icon.
  4. In the left menu, click on the plus (+) button to expand the list of database names.
  5. Click on the database name that is associated with the WordPress blog.

    phpMyAdmin edit domain URL listed for siteURL
  6. In the left menu, click on the wp_options table.
  7. In the option_name column, look for the Siteurl and Home variables.

    phpMyAdmin editing siteurl
  8. Change those variables to the correct address for your blog.
    1. Click Edit on the far left of the option name.
    2. On the next page, place the full URL for your site into the large text box in the option_value field.

      Where to add full URL to change siteurl in database
    3. Click Go.

If you wish for your WordPress to work with your domain name, be sure to change the siteurl and home database values to your normal domain if they are, for some reason, not already set to this.


Update WordPress Domain through WP-Admin

This method cannot be used if you cannot access the WP-Admin section of your WordPress installation.

WordPress allows users to update their domain name through the administrative access panel; however, this should be done with caution. This method is best for users who wish to update the domain before a directory change.

To change a WordPress domain through WP-Admin:

  1. Visit http://example.com/wp-admin/ and log in with your admin username and password. (Be sure to replace example.com with your working domain name.)
  2. In the left menu of the dashboard, click Settings.
  3. Under General Settings, in the WordPress address (URL) field, enter the new domain.
  4. In the Site address (URL) field, enter the new domain again.
  5. Click Save Changes at the bottom of the page.
WP-Admin Lost Password
If you've lost or forgotten your WP-Admin username or password, navigate to the login page (http://example.com/wp-admin/ ) and click the Lost your password link.
You will receive a prompt to enter your username or email address. WordPress will send a reset password email to the email on file for that username. Follow the instructions in the email to reset the password.

Update WordPress Domain via File Manager or FTP

If you are unable to update your WordPress domain using the methods above, you can alternatively try the following:

  1. In cPanel, go to File Manager or connect via FTP.
  2. Navigate to your WordPress directory.
  3. Edit the wp-config.php file.
  4. Update (or add) the following lines to the code:
    define("WP_SITEURL","desired url address");
    define("WP_HOME","desired url address");
    Note: Make sure to change 'desired url address' to the new URL.
  5. Save the changes.