How to move WordPress site from localhost to live host

Live your Local Wordpress site

In our past articles we have portrayed how to introduce WordPress on localhost utilizing MAMP OR XAMPP and how to move live WordPress sites to localhost. At the point when you begin fabricating a site, it might likewise be important to manufacture a site on localhost and afterward move the substance to a live server in the wake of everything working fine. Here and there you may likewise do intermittent testing and advancement on localhost site and afterward move the progressions to the live server. In any case it bodes well to see how to move WordPress localhost site to live server with the goal that you can utilize your neighborhood duplicate to reestablish the substance of the crisis.

Here a Two Method To Move Site.

  1. Manual Method
  2. Using Plugins

Here I only discuss manual methods. I will give another article for plugin based just because i strongly recommend you to do manual methods or one more main point must keep a local copy of your live site. This will help you to move the content to the live server when required. Also, you can do the updates and testing on the localhost and then deploy on the production server without facing problems.

Manual Method

manual method, we will show you how to manually move WordPress from local server to your live site.

Live your Local WordPress site on Live Server

Some steps we follow.

  1. Export Local Database.
  2. Upload Local File to live server using  FTP
  3. Create New database on your live server using phpMyAdmin. 
  4. Import the local database tables to the live database utilizing phpMyAdmin on live server.
  5. Replace Site URLs of localhost connections to live site’s connections. 

1.Export Local Database.

Simply goto your local server phpmyadmin section and select database and export.

Live your Local WordPress site

Then you got a two option Custom or Quick

Live your Local WordPress site

I recommend to choose Quick option  then click the go button then you see the downloaded  file of .sql extension.

2. Upload Local File to Live Server Using FTP

To move your WordPress records, open your FTP customer. I am using FileZilla FTP customer here. Setup FileZilla with host or user name or password. At that point, Upload all the files in the correct goal distiation. For instance, in the event that you need to have the site on mysite.com, at that point transfer all files in the public_html index.

Live your Local WordPress site

3. Create Database on Live Server

While your FTP customer is transferring your WordPress files, you can begin bringing in your database to the live server. Most WordPress facilitating suppliers offer cPanel to deal with your facilitating account, so we’ll tell you the best way to make a database utilizing cPanel. 

To start with, you have to sign in to your cPanel dashboard and icon on the MySQL Databases symbol which can be found in the databases segment.

Live your Local WordPress site

On the next step, create a database by entering a project name for your database and clicking the Create Database button.

Live your Local WordPress site

After creating your own project name database, redirect to the MySQL Users section and create or add an existing user to the database.

Live your Local WordPress site

After adding the user, cPanel will redirect you to set MySQL security selection for that user. Simply give all access to the user by making sure all lists of boxes are checked, and then click the Make Changes button.

Live your Local WordPress site

4. Import Local Database to Live Server

The following stage in the process is to import your WordPress database local database file to live database server. 

Go to your cPanel dashboard, look down to the databases list and on phpMyAdmin. 

This will take you to phpMyAdmin where you need to tap on the database you made in Back Step PhpMyAdmin will show your project database without any tables. 

click on the Import tab in the top menu. On the import page, click on the Choose File button on the bottom and afterward select the local database file you save in the first Step.

Finally , press the Go button at the base of the page. PhpMyadmin will currently import your WordPress database.

Live your Local WordPress site

5. Replace site url

Now you need to change the site URL in your project database, so that it will connect with your own live WordPress site.

In the phpMyAdmin section select  your own project database, look for the wp_options table in your database that we just imported.

select the table next to wp_options or the link that you see in the sidebar to open the page with a list of fields within the wp_options table then click on the edit button. See screenshot below:

Live your Local WordPress site

When you click the edit field, an edit field window will appear. In the input box for option_value, you will see the URL of your local project install probably something like: http://localhost/imnoorfahad. Carefully insert your new site url in this field, for example: https://imnoorfahad.in

Save the field by clicking the Go button.

Live your Local WordPress site

As you have seen, it is not that tough to move a WordPress site from localhost to a live server. It takes only a few steps to do all manually. 

Ideally now your live site is ready for action easily. Make certain to look at your site to ensure that everything is filling in true to form. In the event that you notice any mistakes, you can connect me at @iMnoorfahad for help troubleshooting.

If you liked this article, then please subscribe to our YouTube Channel for useful videos. You can also find us on Twitter and Facebook.

About the author

Noor Fahad

I am a PHP and VueJs developers over 3 years. I have worked on many small and big projects. And I like to contribute over the internet to help other developers. Follow me on any Social Network @iMnoorfahad

Write a Reply or Comment

Your email address will not be published. Required fields are marked *

No Comment

This post has not been commented yet.

The Webography