Transfer or Upload the WordPress site to Live Server

Don’t worry about moving your WordPress site to a Live Server.

We will guide you with step by step instructions to move your WordPress site to server using the right tools.

There are two ways to move the localhost website to a server:

  1. Manually
    1. using cPanel
    2. using FTP
  2. using Plugins (recommended)

 

  1. Manual Migration

 

In manual migration, there are two methods; you can use either cPanel or FTP to your files to the online server. The above said methods are not recommended by us because you have to edit the files and database for the both method in the end. Sometimes it leads to error and risk.

 

1.Migration Process using cPanel

If you want to upload your WordPress using cPanel, follow the below steps:

 

  • First you have to zip the website folder from localhost
  • Log into your cPanel
  • Go to File Manager
  • You will see the public_html, open it.
  • Click the upload button in the top of the folder view
  • Upload screen will be shown, upload the zip file which was generated on the localhost then click Upload/Submit button.
  • After the zip file uploaded successfully, extract the zip file by clicking the Extract button after selecting the zip file.

 

2. Migration Process using FTP

You can access File Manager in cPanel by using FTP client like FileZilla, winSCP, Tranmit, etc. Here we are using FileZilla. You will need FTP credentials to access your web hosting account.

 

If you want to upload your WordPress using FTP, follow the below steps:

  • Install and Open FileZilla on your localhost computer. Enter your Hostname, Username, Passport, Port and Click Quickconnect button.
  • After the successful connection made, Select public_html folder from the right side panel which shows the live server filesystem.
  • Open the localhost website folder from the left side panel which shows the local system filesystem.
  • Then Select the files and folder which you want to upload, right click the mouse and hit upload from the popup list. Upload process will take sometimes to complete.

After the above anyone methods, we have to upload the database from the localhost to online server. The below steps is the instruction to upload the database to online.

  • Open the phpmyadmin from the localhost to access the MySQL or MariaDB, enter the credentials to login.
  • Select your database and click the Export button.
  • In the Export page, choose Quick method and SQL Format from the list
  • Click Go and save the file by the giving the name.
  • Then Go to cPanel, select the MySQL Database from the Database group.
  • Create a new database by entering the database name and click Create.
  • You have to create a new user and to give all access privilege to the user.
  • Open phpmyadmin from the cPanel and select the database which was created by you.
  • Click Import button and select your file by clicking Choose file button
  • Press Go

After the Import, Open the imported database then open the wp_options table, search for siteurl and home fields on the table, double click the siteurl row option_value column to edit, replace the localhost URL with your site URL.

For example,  localhost URL  http://localhost/blog/ replace with your site URL https://myblog.com

Then you have to replace the localhost URL with your site URL in one more table wp_posts using the below MySQL query

UPDATE wp_posts SET post_content = REPLACE(post_content, ‘localhost/yoursitename/’, ‘yoursitename.com’);

Now the database part is over, next you have to configure the WordPress files.

Open the wp-config.php file from your cPanel File Manager or double click the wp-config.php file from the right side panel of your FTP client, change the database name, username and password in wp-config.php file and then save and upload it.

Next, you need to login your WordPress and go the Settings à General. In Permanentlink, update with your site URL and Click Save.

You have successfully migrated WordPress from localhost to online server. You can now visit your website

 

  1. Migration using WordPress Plugins

You can upload your localhost site to online server using WordPress Plugin like All-in-One WP Migration, Duplicater, etc. This method is most convenient and easy method. Here we are using All-in-One WP Migration Plugin.

Go to localhost WordPress admin page

  • Click Plugins à Add New.
  • Search for All-in-One WP Migration Plugin
  • In the list, you will see the Plugin and Click Install Now
  • After the Installation, Click Activate button
  • After the Activation success, you will the see the All-in-One WP Migration plugin in the left pane and Click it.

 

Using this Plugin, you can Export, Import and Backups your site.

 

  • Click Export in the left pane.
  • Export Site screen will be displayed, then Click Export To button

 

There will be the list shown after you clicked the Export To button, it is option where to store the export file in local system or FTP or Dropbox , etc.

 

  • Select the File from the list to store the file in local system.
  • There will be popup screen displayed; it shows the progress of Export process.
  • After the process completed, you will see the Download button with size of the file.
  • Click Download button, file will be downloaded in local system.

Then Go to Live WordPress admin page,

  • Click Plugins à Add New.
  • Search for All-in-One WP Migration Plugin
  • In the list, you will see the Plugin and Click Install Now
  • After the Installation, Click Activate button
  • After the Activation success, you will the see the All-in-One WP Migration plugin in the left pane and Click it.
  • Click Import button
  • In the Import Site screen, click the button Import From à
  • Choose the file which was exported by you from localhost.
  • Warning message will be displayed for already old WordPress content will be deleted after the Import Process
  • Click Proceed.

 

The Importing process will be displayed. After the Import process successful, you will see the success message.

You have successfully migrated WordPress from localhost to online server using All-in-One WP Migration plugin. You can now visit your website

 

Leave a Reply