
There are many reasons to change the web address of a WordPress website. You might be rebranding, moving from a subdomain to a primary domain, switching from HTTP to HTTPS, or moving your site from a staging environment to production. While WordPress makes changing your site URL fairly straightforward, doing it incorrectly can lock you out of your dashboard, break images and links, and hurt your search engine rankings. This guide explains how to change your web address in WordPress safely and effectively.
Get Help From AAMAX.CO
AAMAX.CO is a full-service digital marketing company that offers web development, digital marketing, and SEO services worldwide. Their team handles WordPress migrations, domain changes, and redesigns with careful planning to preserve search visibility and functionality. If you are rebranding or restructuring your website, hiring them for web design and development ensures the transition is smooth, redirects are mapped correctly, and your new address is ready to perform from day one.
Before You Begin: Back Up Your Website
Always create a full backup before changing your WordPress address. Back up both your website files and your database. Many hosting providers offer one-click backups, and plugins like UpdraftPlus or Duplicator make the process easy. A backup allows you to restore your site quickly if something goes wrong.
Understand the Two Key URL Settings
WordPress uses two settings to define its address:
- WordPress Address (URL): The location of your WordPress core files.
- Site Address (URL): The address visitors type to reach your website.
In most installations, both values are the same. They differ only when WordPress is installed in a subdirectory but served from the root domain.
Method 1: Change the URL in WordPress Settings
The simplest method is through the dashboard. Navigate to Settings, then General. Update the WordPress Address and Site Address fields with your new URL, then save changes. You will be logged out and redirected to the new address. This method works when your new domain is already pointing to your hosting server. If it is not, you may lose access to the dashboard until DNS is configured correctly.
Method 2: Define the URL in wp-config.php
If you cannot access the dashboard, you can set the URLs in your configuration file. Connect to your server through FTP or your hosting file manager, open the wp-config.php file, and add definitions for WP_HOME and WP_SITEURL with your new address above the line that says to stop editing. These values override the database settings. Note that the fields in the General settings will become uneditable while these definitions are present.
Method 3: Update the Database Directly
Advanced users can change the URL in the database using phpMyAdmin. Open the wp_options table (the prefix may differ) and edit the siteurl and home option values. This method is useful when other approaches fail, but it requires caution because database mistakes can break your site.
Update Internal Links and Media Paths
Changing the site URL does not automatically update links stored inside posts, pages, and widgets. Images and internal links may still point to the old address. Use a search and replace tool such as the Better Search Replace plugin or WP-CLI's search-replace command to update old URLs throughout the database. These tools handle serialized data correctly, which manual database edits do not. Always run a dry test first to preview changes.
Set Up 301 Redirects
To preserve search rankings and avoid broken links from external websites, set up permanent 301 redirects from your old address to your new one. If you are moving domains, configure redirects on the old domain's server, typically through the .htaccess file on Apache servers or the server configuration on Nginx. Redirect each old URL to its matching new URL rather than sending everything to the homepage. Plugins like Redirection can help manage page-level redirects.
Update Search Console and Analytics
After changing domains, add your new domain as a property in Google Search Console and use the Change of Address tool to notify Google of the move. Submit your updated XML sitemap. Update your Google Analytics property settings, advertising accounts, and any marketing tools that reference your old URL. Update your business listings and social media profiles as well.
Test Everything Thoroughly
Once the change is complete, browse your website extensively. Check pages, posts, images, forms, menus, and checkout flows. Use a crawler tool to identify broken links or redirect chains. Clear caches at the plugin, server, and CDN levels to ensure visitors see the updated site. Confirm your SSL certificate covers the new domain.
Common Mistakes to Avoid
Avoid changing your URL without a backup, forgetting to update hardcoded links, using temporary 302 redirects instead of permanent 301 redirects, and neglecting to inform search engines. Each of these mistakes can cause traffic losses that take months to recover. For complex sites, professional website development support reduces risk significantly.
Final Thoughts
Changing your web address in WordPress involves updating your site settings, replacing old URLs across the database, implementing proper redirects, and notifying search engines. With a careful, step-by-step approach and a reliable backup, you can move your site to a new address without losing functionality, traffic, or the trust you have built with your audience.