There are various reasons why you may decide to move your website to a new domain. You could be unsatisfied with the service offered by your domain host or you may need to move to a domain that can accommodate your expanding website. In any case, changing your domain name is not a simple process. Before you transfer your website to a new domain, you need to first backup all the data on your current domain server and then upload your data files to the new domain server.
Be prepared for the worst
First create a full backup of your site and then download all the content on your hosting server. This will protect you from accidents so that you can easily restore your original site using the backup copy in case you make any mistakes. Another reason why you need to create a full back up is that you require a copy of the site to be able to transfer your website; you will be required to upload the contents of your website to the new domain server.
The challenge is knowing what needs to be backed up. In the case of a WordPress site, you will make a copy of two parts: the database and the static files. The database includes the contents you have created in your web pages. The database consists of tables where your data is stored; the static files including WordPress files, CSS files, and theme files, are what make up your site. You will require both parts because if you only have static files your site will end up looking like the old site but without posts or pages. On the other hand, if you only have databases you may transfer all your content, but will be forced to configure all your WordPress settings.
To download both databases and static files, you can use a plugin that creates the backup. Once you install the plugin, configure settings and go to the backup menu then select the complete backup option. This allows you to make a copy of both the static files and the databases. Once you finish the backup, you can download a copy of the backup or save it in the cloud. The disadvantage of using plugins to backup data is the fact that most of them are not free.
Another option is to use the CPanel back up functionality. Most hosts provide access to Cpanel. First login to your CPanel and then search for the Database Wizard normally located in the file section of the dashboard. Select backup and the type of back up you would like. Carefully follow the data backup procedure to avoid making mistakes. As much as you think you might require a full backup, do not click on it because you will not be able to restore a full back up when you need to move content to your new domain. Instead, select partial back up. You will require the home directory, which has the static files and the MySQL databases containing the databases. Select any of the two and then download. Repeat the procedure for the remaining part.
Setting up the new domain
You will be ready to move to your new domain after backing up your data. Register your new domain and look for the domain name server (DNS) options within your new domain’s DNS server. This tells the registrar where the new site is hosted. Next, obtain the addresses from your new hosting provider. Most providers send you an email once you register with them containing at least two or more server addresses in it. Add these addresses as custom DNS servers then save the changes. It may take a few hours for the changes to take effect. To confirm if the changes have taken place, enter your new domain in a DNS check tool to see which servers pop up. If you see the new address in the result then the changes have successfully been saved.
Uploading the old site
The backup of your files and databases from the old site will allow you to upload them in the new domain. First, create a new database and then click “MySQL Database Wizard” in the CPanel on the Databases section. Choose a database name, preferably something that relates to the site, then enter it into the wizard and click “create database”. You will be asked to create a user for the database. Create one and choose a password that you should record and keep in a safe place. In addition, you will be required to specify the privileges that the user has in the database. Thereafter, edit your wp-config file, which requires a new database name and user name. Open the static files in the backup and find the wp-config.php files. Open the file in a text editor and then enter the database name, password, and username.
Start uploading the contents in the backup using a plugin. The same plugin you used to back up can be used to restore a site. First, install a blank WordPress copy. Then install the plugin and click on the restore function. You will be directed through the restoration process. Upload the backup file and enter the database information. Once the setup is done, allow the plugin to upload content. You will be able to see the content in your new site once you finish uploading it to the new domain.
You may still have to check on a few things once you finish moving your site to the new domain. Look for broken links because it is likely that you did not fix the old broken link. Enter your home page on online broken link checkers and insert the security code. Run the tool and it will display the list of broken links so that you can fix them. Look through the pages manually. Visit various pages on your site to see how they look and if you notice any problem, fix it immediately. Ensure that the WordPress settings have not changed. Go through all the setting panels and ensure everything is just as it was before.
Moving a website to a new domain requires careful planning and preparation. It is important to backup your website data and files before the move. Although some people may prefer to move their websites to new domains on their own, it may be important to consult an IT technician to help you with the move.