The process of moving WordPress to a new web server can be a quick and easy process. The general steps for the migration of both WordPress and WordPress MultiSite are generally the same. There are specific nuances based on specific situations. For example, if the domain name is being changed, extra steps will need to take place.
Also, if the transfer is because of a recent site purchase an extra step is needed. The domain hosts(s) and web host(s) in question can vary the steps, and also the Operating System of the server can change the process. Here are some general steps for moving WordPress that should work in most typical situations.
The first step is to change domain ownership but only if the WordPress move is the result of an acquisition. The steps here will differ based on the domain host being used. To simplify the process I suggest not moving domain registrars during this process, as that can be done at a later date.
For example, if your desired domain registrar is GoDaddy, and the domain is currently hosted at Namecheap, it is often easier to just create a free Namecheap account and have the current owner “push” the domain to your newly created account.
Keep in mind though, that domain ownership changes will lock the domain from transfer to a new registrar for a time. So, if moving to a new registrar is critical in the short term, it’s best to do it immediately. It just complicates a process that can be straightforward when making a purchase of a WordPress site. When performing the domain push, ask the seller to keep the name servers the same for the time being to limit down time.
- Next, export the MySQL database content of the current WordPress install. This is usually done from phpMyAdmin which can be launched from CPanel. Some plugins can perform this task from the WordPress admin, however I have no recommendations here.
- Next, download all files and folders of the current WordPress install. This can be done through FTP (or more preferrably SFTP), or through HTTP with a web-based app. Compression can be done first if using a web-based application for downloading.
- On the “new” server, create an “add-on” domain, which will create a folder in the “public_html” folder (in most cases), and map the domain to that folder.
- Create an empty MySQL database. Assign a user to the database and make note of the database name, database user name, database password, and server name.
- Modify the wp-config.php file from the downloaded WordPress files. Edit the database name, database user name, database password, and server name. The server name will likely stay as “localhost” unless working with GoDaddy, or a similar host (or a remote database server).
- Upload all files and folders to the newly created, domain-mapped folder on the “new” server.
- Modify the name servers for the domain name to point to the new location. If using a host with CPanel, the name servers, usually 2 of them, can be found in the “Account Information” section near the bottom left of the main CPanel page (scroll way down). Make note of the IP Address as well while you are there. We’ll use that shortly.
Domain name propogation: Up To 72 Hours
When changing the name servers for a domain, a waiting period takes place. The process could take minutes or several hours, even up to 2 or 3 days. Not everyone around the world will be viewing the web site at the new location at the same time. In general, this process is actually very quick, especially when dealing with .com domains.
When changing name servers for a .info though, the process could take awhile longer. You can hunt down a free “domain propogation checker” tool on the web and enter the domain name. The result will be the IP Address that is “mapped” to that domain. If the IP Address matches what shows in the “Account Information” section, you’re in business.
This still doesn’t mean that everyone in the world is currently mapped to the new server but this does signify that the process is under way. Some people will “add” to the name servers for the domain (in the final step above), rather than “replace” them. They say this guarantees no down time, and in theory it seems that would be the case. Just remember to remove the old ones after a couple days, or at least change the priority order in the beginning in case you forget. Don’t forget to delete the files, database, and account on the old server after you are confident that the WordPress site is being served from the new location for much, or all, of the world.