If you are transferring a website to Webstix, there are a few things we need in order to get your website set up on our hosting.
- We need a zip file of the website files (from your current hosting) and then an export (or “dump”) of the database. With the zip file, what’s better is a “tar” file because file permissions can be preserved.
- We need FTP access (or better yet, control panel access) for your account, we canthen login and grab the files – or maybe your host is providing you with the files to send to us.
- We need your WordPress Dashboard login (username and password – along with the Dashboard login URL).
You can securely submit FTP info and your WordPress login info here:
How Do You Transfer a Website From One Host to Another?
Often, people want to move their website to another website host. The process can be simple but there can also be some snags, which can take more time and they have to be worked through. I’ll go over the basic process to transfer a website here.
1. Get all the Files and Database from the Current Host
You want the most recent version of the website, so it’s best to get them from the live website. For this to happen, we will need both FTP access and access to the control panel so that we can get a copy of the database if the website runs on a database.
The best way to grab the files on the current host is to create a tar file with permissions preserved. A tar file is kind of like a zip file but without compression. It basically puts everything into one file. Once you have a tar file, you typically zip it up using the gzip program (Linux). With permissions preserved, you don’t have to later set all the necessary permissions when you unzip it.
Many websites today are made with PHP and run on Linux with MySQL as the database. A good tool to use to get the database dump is PHPMyAdmin. Most hosting control panels (like cPanel or Plesk) give you access to this tool. From there, you do an export that you can either download or save to a folder on the server. This is basically a text file with SQL commands in it. This file can be gzipped as well if it’s large.
When you’re done here, you should have both a zip file of all the files on the server and a database dump file.
2. Create the Space on the New Hosting Account
This might already be done for you but probably not. How to do this will depend on which hosting control panel you are using. Some common website hosting control panels are cPanel and Plesk.
You will need to set up the domain, create an FTP account and then also set up a database.
When you set up the database, you’ll need a separate username, password and database name. Make sure you also set the permissions so that the database user you just created has permissions to use the database.
3. Move Everything Over
You can now use FTP (use an actual FTP program, not your web browser and things will work a LOT more smoothly for you) your zip file and the database dump file (actually, depending on your hosting control panel, you might be able to do your database import without FTP-ing the database dump file over but it’s a good idea to put it on the new host so that you always have it there as a backup – and I like to move it into a private folder so that nobody can find it).
Using your hosting control panel (or SSH access if you have it), you can unzip your zip file (or tar.gz file). All the file permissions should be preserved, so they shouldn’t be an issue. If it unzips fine, then you can delete the zip file.
5. Import the Database
Use a tool like PHPMyAdmin (or else some MySQL console commands using SSH) and import the database. Use the database dump file, which has SQL commands in it. Make sure it imported fine. If not, then you may have to do another export from the old website host.
Next, you’ll want to test the website. Your host might give you an aliased subdomain to test with or possibly a dedicated IP address (not too typical). Optionally, you can set your computers hosts file so that you can see the website on the new host.
7. Make it Live!
And then finally, you can change your domain’s DNS settings to either change the DNS servers or else modify the DNS records on your current DNS host and have the “A” record point to the IP address on the new host. If you have a “www” subdomain set up as an “A” record, then you should change that record, too. If the “www” subdomain is set up as a CNAME, then you shouldn’t have to change it.
It make take DNS a few hours or maybe even a day to update all over the web.
Don’t forget to change back your hosts file if you did that.
That’s roughly what needs to be done to move a website from one website host to a new one. This page is not meant to be comprehensive but just serve as a guide for those who are wondering what is involved in this process. There are a bunch of details to keep track of. Also, make sure you use good, secure passwords when setting up FTP accounts and database passwords.
And the fun can even continue. You may be waiting and still not see your website. You may also run into a situation where you need to change your office network’s internal settings in order to see the new website within your office network. This happens often.
If you need help moving your website, then feel free to contact Webstix Maintenance.