How to Transfer a Website to a New Domain

[ad_1]

Everyone hates moving. Whether it’s across town or across the country, the act of packing up your belongings and making sure everything ends up in your new home is taxing. That’s also true for transferring your website from one web hosting service to another. Unlike moving in the real world, you may have no clue how to move blog posts, images, video, and other content to the new domain. Don’t fret; we’re here to walk you through the necessary steps to make the process as simple as possible.
The Best Web Hosting Services

1. Back Up Your WebsiteWe assume that you’ve already found a new web host and domain name for your site. Now, you must pack everything for the move. In this case, that means backing up your website. There are three main ways to do this.The WordPress MethodIf you’re working with a WordPress-powered website, you need a WordPress plug-in to wrap up everything. All-in-One WP Migration, Duplicator, and UpdraftPlus are just three of the many options. These easy-to-use plug-ins let you backup your WordPress site with just a few clicks. Using Duplicator, for example, you should: Click “Packages” and then “Create New.” This creates a package containing all your site and WordPress elements. It also includes an installer. Download the site archive package.The cPanel MethodYou can also use a website’s control panel to backup files. Many popular web hosts use cPanel, for example, to manage files. Here’s how to do it:Within cPanel, navigate to the “Files” section and click “Backup Wizard.” Make partial backups of your home directory, MySQL databases, and email forwarders. In an odd wrinkle, you don’t want to create a full backup, because you can’t restore from it.The FTP MethodIf you’re familiar with working in a site’s backend, you could backup your site files via File Transfer Protocol (FTP) and phpMyAdmin. This method is also useful if you are moving large files. You can perform an FTP backup with any FTP client—we recommend FileZilla, an excellent piece of free software. Make sure to install the FileZilla Client, and not the FileZilla server.In addition, you’ll need to have the old site’s sign-in credentials. Here’s how to do it:Sign in with the FTP client—or use the File Manager built-in to many control panels—and download the contents of the “Public_HTML” folder. Then you’ll want to find phpMyAdmin; it’s usually in your control panel’s “Databases” section. Click the “Export” tab, “Quick” as the Export method, and “SQL” as the format. Click “Go.” Doing so creates a database file that automatically downloads to your PC. 

(Credit: FileZilla)

2. Check Your DNS SettingsDid you acquire a new domain name from an independent domain registrar? Did the new domain come as part of a web hosting package? Regardless, make sure that your domain name system (DNS) settings are correct before transferring files. A DNS record ties your domain name to your website and server. These DNS records are usually an IP address, a subset of four numbers (104.17.210.9, for example). There are also general nameservers that come in URL form. You’ll get these from your web hosting provider. If your registrar and web host are the same, you can skip this step. If not, you must add that information to your domain name registrar. Here’s how to do it:Log onto your new domain server account and check the server details. This will be in a different spot for each hosting provider. This should include your DNS record and nameservers.Log onto your domain registrar and edit the DNS record and nameservers to match your new domain.Wait, as it can take 24-48 hours for the process to work.3. Transfer Files to a New DomainThis step is essentially the reverse of the first step. You’ll need an archive of all the files from your original site’s directory, as well as the database, which tells your web server where all the content goes. It’s important to make sure both are in the right place.First, make sure the new website already has a database. (For WordPress sites, this will usually be wp-config.php.) Then, using phpMyAdmin, import the archive file’s content into the existing database. Select the “Import” options in phpMyAdmin, choose the file on your PC, and click “Go.” This should import all the database entries from your old site into the new one. Now, you can transfer your site files.How to Transfer Files Using WordPressYou’ll need to use the installer and archive package you downloaded in the first step. If you installed the All-in-One WP Migration plugin, for example, do so in your new server. Use an FTP client or the built-in File Manager to connect to your new web hostClick the installer to begin the restoration process. UpdraftPlus and similar plug-ins may have a clone or migrate option that lets you restore everything from a file on your PC.How to Transfer Files Using cPanelIf you went the cPanel route, simply go to the Backup Wizard on your new domain and restore your site from the previously created files. This is the “no muss, no fuss” option.How to Transfer Files Using FTPUse an FTP client or the site’s built-in File Manager to connect to your new web host. Upload the files from your old site’s home directory archive to the new host’s home directory. Upload your database files.4. Make Sure to Redirect PagesIf you want traffic heading to your old domain to make its way to your new one, you need to redirect the old site to the new site. Otherwise, people will see a 404 Page Not Found error when they try to reach your site at the old domain. You can set up a 301 redirect in .htaccess to get traffic to the correct URL. Follow these steps to set up your redirects:Use FTP or the File Manager to connect to your old domain’s registrar or hosting account. Edit the .htaccess file. This will be in your home directory or in the same directory as your wp-admin folder for WordPress users. Open the .htaccess file and add the following code:#Options +FollowSymLinksRewriteEngine onRewriteRule ^(.*)$ http://www.mydomain.com/$1 [R=301,L]Replace “mydomain.com” with your new domain name.Now, your old domain name should redirect to your new one. If it doesn’t, you should contact your old hosting service’s tech support team for assistance.5. Fix Broken LinksIf you did everything right, the new site’s links should work. However, some links may break and Google may penalize you for it (you don’t want that!). So use Dead Link Checker, Dr. Link Check, or w3C Link Checker to discover those broken links. You must fix each dead link one by one, editing their locations by hand. It’s worth the effort, though.6. Let Google Know About the Site TransferNow let Google know about your new home! This is especially important if you’ve performed 301 redirects to your new site. You can do this using some of Google’s own tools. 

Recommended by Our Editors

If you’re using the Google Search Console with your old domain, click the gear icon, and select “Change of Address.” Input your new domain name here, and let Google handle the search traffic redirect.You’ll also want to have an XML sitemap for your new domain. If you’re using WordPress, here’s how to make that happen.Install the Yoast SEO plugin. The plugin will automatically create an XML sitemap at: http://newsite.com/sitemap_index.xml. That’s it!If you’re not using a WordPress-powered site, there are other options. Visit XML-Sitemaps.com to generate one for your new website. Download the file created, and then use an FTP client or File Manager to upload the file to your site’s home directory. The file should be “sitemap.xml,” meaning its URL will be: http://newsite.com/sitemap.xmlThen, under Google Search Consoles, click on “Sitemaps” under the “Index” section. Then you can add whichever URL above and click “Submit.” Now, Google can crawl your website with ease.7. Check Your SiteThe last step is the easy one: Check your new domain! Take time to click around your site to ensure all the posts, images, and videos are in their correct locations. Fix any missing items on your backend. Tell your community about the domain change if you have a fairly popular site. You may have service interruptions as the migration process moves forward, so it’s good to let your visitors know why. Regardless, welcome to your new home on the web.For more on web hosting, check out The Best Courses for Learning How to Build Websites. Once your site is live, use these 10 Easy But Powerful SEO Tips to boost traffic.Mike Williams contributed to this story.

5 Things You Need to Know About Web Hosting

Like What You’re Reading?
Sign up for Tips & Tricks newsletter for expert advice to get the most out of your technology.

This newsletter may contain advertising, deals, or affiliate links. Subscribing to a newsletter indicates your consent to our Terms of Use and Privacy Policy. You may unsubscribe from the newsletters at any time.

[ad_2]

We will be happy to hear your thoughts

Leave a reply

Megaclicknshop
Logo
Compare items
  • Total (0)
Compare
0
Shopping cart