Unfortunately, there is no automatic way to transfer a site from one hosting account to another.
In order to move the site, it is necessary to download the files, databases and information from hosting account1 and after that to upload them to other hosting account2.
To successfully transfer a site from one hosting account to another, you can follow these guidelines:
1. Move the content / files on the site.
1.1. You need to know where the files are located on the site in hosting account.
If your website is a major domain hosting account and have not applied any redirects then the main directory where the files are located is:
The same goes for parked domains - the directory is public_html:
If the site is Addon domain in the hosting account then the directory could be understand as accessed through the Control Panel cPanel -> Addon Domains/Addon domains.
1.2. Preparation for the transfer of files / directories.
Content could be archived in advance - directly from the hosting account. When you make a backup of directories and files, you will transfer only one file, which will significantly speed up the transfer procedure.
Archived content could be made directly through the Control Panel cPanel -> File Manager - open the desired directory, choose Select all, then Compress.
After compress the selected files/directories – in the account will appear file archive.
1.3. The actual transfer of the content.
The transfer of files/file archive can perform in Control Panel or cPanel or via FTP client (program).
The recommended and most convenient way is by using an FTP program:
FileZilla - uploaded through FTP
(Connect with hosting account1, download local files/file archive. Then connect with hosting account2 and upload files/file archive.)
Once you upload the file archive in hosting account2, in the same way you can extract - through cPanel -> File Manager -> Extract
2. Move the databases (if there are databases)
It is possible that the site/sites have one or more databases.
Existing databases could be seen through cPanel -> MySQL Databases:
It is necessary to make the export of data (databases) by hosting accoun1.
Then, to make the import of such data (pre-created databases) in hosting account2.
Import/export database in control panel cPanel
Import/export database via SSH
Prior to the import of data it is necessary to creat databases in hosting account2.
3. Setting of the system/site hosting account2 after successful transfer
As databases in the hosting account1 have names of species account1_dbname and in hosting account2 names will be in the form account2_dbname, it will be necessary in the configuration of the system/site to make correction of data connection to SQL Server.
If for the website is used complete system, then the configuration file is:
Sample parameters from configuration file of WordPress system:
// ** Connection with MySQL ** //
Note if you will use another name (domain name) in hosting account2 for the site, then you will be required to complete updating of data in databases.
For example, if the name of the site is hosting accoint1 is my-domain.com, you will use my-other-domain.com then in hosting account2, and it will need all the records in the database containing "my-domain.com" to replaced by "my-other-domain.com".
4. Transfer of mails /letters to the domain.
Before starting with the transfer of the letters it is necessary in account2 to create email accounts.
Correspondence, if available hosting server, is located in the directory home/cpanelname/mail/my-domain.com
For each e-mail account created on the domain, there is a subdirectory in the directory mail, with the name of the email account.
For example, for email account [email protected] correspondence is located in the directory: home/cpanelname/mail/my-domain.com/office
Moving may be carried out in the same manner as the transfer of the files/content.
5. Targeting domain to the new account
It is recommended that after you have moved the site of the new account to test whether everything is working correctly. You can do this by using the hosts file on your computer.
Where to find my FTP account details and DNSs?
After making sure that everything is okay, it remains only to change the DNS records of the domain. It is necessary to ask the DNS servers that meet the new hosting account.
Note that the period of full refresh of DNS lasts 2-48 hours, then the domain will be charged correctly by the new hosting account.