Step-by-Step Guide to Changing Your WordPress Site URLs

Introduction to URLs in WordPress

The URLs are fundamental to the structure of any website, as they not only affect navigation, but also SEO and user experience. In WordPress, changing URLs may be necessary for a variety of reasons, such as improving site organization, search engine optimization, or simply because the domain name has been changed.

This article will walk you through a detailed process for making changes to your WordPress site URLs, ensuring that you don't lose traffic and internal links along the way.

Preparations before changing URLs

Before proceeding to change URLs, it is crucial to take some steps to avoid problems. Here is a list of preparatory steps:

  • Make a backup copy: Before making any significant changes, it is essential to have a backup of your site, including the database and files.
  • Check internal links: Make sure that all internal links are working properly and are up to date.
  • Plan the new structure: Design how you want the new URLs to look, with readability and SEO in mind.

Making a backup copy

To perform an effective backup, you can use plugins such as UpdraftPlus o BackWPupwhich make the process easier. When using these plugins, be sure to store the backup in a safe place, such as in the cloud, to avoid loss.

Changing URLs in WordPress settings

Once you have taken the necessary precautions, it is time to make the change in the WordPress configuration.

Go to Settings > General in the WordPress administration panel. Here you will be able to modify the following options:

  • WordPress address (URL): Change the URL if you are moving WordPress to a new domain or subdirectory.
  • Site address (URL): This is the URL that visitors will see. Make sure it matches the new WordPress address.

After making these changes, be sure to save the changes you have made.

Redirecting old URLs to new URLs

Changing URLs can cause broken link problems if you don't perform proper redirects. To do so, follow these steps:

Use of plugins for redirecting URLs

There are several plugins that facilitate the management of redirects, such as Redirection y Yoast SEO. These plugins allow you to create 301 redirects easily. A 301 redirect is a way to tell search engines that a URL has permanently changed.

To create a redirection using the Redirection plugin, follow these steps:

  • Install and activate the Redirection plugin.
    Step-by-Step Guide to Changing Your WordPress Site URLs
    Download our web maintenance guide Free of charge!
    Free guide for freelancers and small businesses that want to avoid surprises and improve their web performance.
  • Go to Tools > Redirection.
  • In the "Source URL" field, enter the old URL.
  • In the "Destination URL" field, enter the new URL.
  • Click on "Add redirection".

Repeat this process for all URLs that need to be redirected.

Update links in the content

After changing URLs and setting up redirects, it is critical to update all links within your content. This includes:

  • Links in entries and pages.
  • Links in navigation menus.
  • Widgets and other site elements.

To facilitate this task, you can use a plugin such as Better Search Replacewhich allows you to search and replace old URLs with new ones in the entire database.

Example of search and replace

If you have changed your domain from www.antiguositioweb.com a www.nuevositioweb.comYou can configure Better Search Replace as follows:

Search for: www.antiguositioweb.com
Replace by: www.nuevositioweb.com

This will update all links on your site automatically, preventing users from encountering broken links.

Verification of changes and final adjustments

Once all the changes have been made, it is important to verify that everything is working properly. Perform the following checks:

  • Access the new URLs to make sure they load correctly.
  • Use analytics tools like Google Search Console to monitor 404 errors and make sure redirects are working properly.
  • Check the performance of your site in speed tools to make sure there are no loading problems.

If you encounter problems, check redirects and links to identify and correct them.