Moving your website from an old domain name to a new one is a lot like moving to a new house – it comes with a lot of headaches. Moving a website to a new domain may not be as simple as you think. It is an arduous task as it involves quite a few steps, including taking backups of your database and DNS records. In this article, we have laid out the steps involved in the process of moving your website to a new domain name. And these steps will help you complete the task without losing your visitors and search engine rankings!

Why Would You Want to Move Your Website to a New Domain?

There are a few reasons why. You may think that your domain name is outdated and doesn’t portray your business well anymore. You may want to change your domain name because you think you can find a domain name that is more SEO friendly. Maybe you have rebranded, and you have a new business name altogether. All good reasons! In this article we will help walk you through the process of moving your website to a new domain name with some high-level tips that will point you in the right direction.

Find a Hosting Provider to Help with the Migration

A trustworthy hosting provider will help you transition to the new domain name quickly and easily. You will need experts who can smoothly do this for you. There are a lot of hosting providers who do the transition for free when you buy a domain name from them.

When you move to a new domain name, make sure you get the required security updates and clean up your website and remove things you might not want. Some hosting providers offer free domain name registration, which means you can register the domain for free and also move your website to a new domain name as well. This way, the transition will be smooth, and you also do not have to spend a lot on it.

Back-Up All Your Website Files

If you do not find a hosting provider who can move your website to a new domain, you can do it yourself with the instructions provided here. Backing up your files is the most important (and the first) step. You should back up your files twice to ensure you do not lose them. You’ll want to do this in case something goes accidentally wrong during the process of moving your website to your new domain. Having two backups will provide that extra level of insurance in case the worst-case scenario happens. Remember to take backups of your static files and database. This applies to those using content management systems like WordPress as well.

Follow the steps below to back up your files.

  • Plugins will help you to back up files quickly and securely. When it comes to WordPress, there are a lot of plugins that will help you back up your WordPress website completely. UpdraftPlus is one of the most popular plugins that will let you back up your site. You can try other plugins like Duplicator, or VaultPress as well.
  • Then go to your cPanel (control panel). It will have tools that will help you back up your website. The Backup or Backup Wizard is what you will need to find. You can then back up your database and home directory.
find-backup-wizard-in-cpanel
  • You can use phpMyAdmin to export your database. You will also need to back up your static files for which you can use FTP clients like Cyberduck, WinSCP or File Manager on cPanel.
Now that you have a backup of all your files, make sure your new domain is all set to accommodate all the files of your website.

Move Your Files to the New Domain Name

The next step after backing up your files is moving your files to the new domain name. Before moving your files, make sure your new domain is ready to host your website. Start with checking the settings and DNS with the domain name registrar.

If your domain name registrar and your hosting provider are different, your DNS servers will help your domain name registrar know where all the files of your website are located. You will have to provide the DNS address you get from your web hosting provider to the registrar. Once the DNS information is added with your domain name registrar, changes will be made to your DNS. These changes will take effect in around 24 hours.

Once this is done, you will need to figure out and set up the space to place your files. You can create a new database using MySQL Databases or MySQL Database Wizard components. Note down the name of your database, password, and username if you use WordPress as your next step would be updating the wp-config.php file in the backup. In one of the two backups you have saved, update the wp-config.php file with the new information you just noted.

There are three ways to upload your database and backups. Here are the ways in which you can upload your database and backups of the static files to your new domain name. You can choose the one that is most convenient for you. Remember, you need to be careful about your static files as well as the database to ensure your website operates at optimal levels

  • cPanel – You can restore and upload your home directory by getting to the Backup Wizard app in cPanel.
  • Plugins – There are plugins that will help you restore your backup. Using plugins, you can also update your wp-config.php.
  • Manual setup – Using an FTP client, you can upload all the static files to the public_html folder of your domain. Followed by that, you can import your database tables to your new domain using phpMyAdmin.

Check for and Fix Broken Links and Create Redirects

Now that your new domain is almost ready, there are a few things you will need to do before it goes live. Check if your website is operating well. Check the WordPress backend to see if everything is normal and that your settings are correct.

Check for old broken links. You can go for a broken link checker to find and remove all the broken links from your website. You can use WordPress plugins like Broken Link Checker or free broken link checkers like brokenlinkcheck.com to check for broken links. Once you enter the name of your website and hit enter, a result will be generated. If you see that there are broken links, you can immediately take the required steps to remove them.

Similarly, see to it that your SSL is installed and is working fine. Having an SSL certificate is important for your security as well as your users’.

To ensure your visitors are not directed to your old domain, set up 301 redirects so that people who go to your old domain will be redirected automatically to your new domain. These redirects will tell your users and the search engine that the old webpage is no longer functional and that it has been moved to the new domain permanently. Setting up 301 redirects will also help in your SEO as you may not lose your search engine rankings. Edit the .htaccess file by connecting to your old website using FTP to set up 301 redirects. Once you set up the redirects, you can clear the cache and visit your old domain to check if the redirect is working fine. If you are redirected to your new domain, this means you have set up the redirect properly.

Notify Google About Your New Domain Name

Now that you have made all the changes, it is time to let Google know about your new address. This is important as you want Google to show your new domain in the search results. You can add your new domain to the Google Search Console and Google Analytics.

Create and upload a new XML file and request Google to reindex your website. This way, Google will replace all the old URLs it has cached with the new ones. Though you have added redirects, having Google update your URLs will help you send your visitors directly to the right URL. You can use plugins like XML Sitemaps to automatically generate sitemaps.

Conclusion

There may be a lot of reasons why you wish to move your website to a new domain name. As long as you follow all the important steps and have backups of your files, you need not to worry about losing your files while moving your website to a new domain. Once you complete all the steps, clear your cache to check if your website has successfully been moved.