Build Your Own Blog Like This One

Building a Blog Has Never Been so Easy! Mobile Optimized and Easy -to-add
4 Ways to Safely Update WordPress without Losing Data

4 Ways to Safely Update WordPress without Losing Data

WordPressIt is the most used CMS in the world and, therefore, the one that receives the most computer attacks throughout the network. According to sucuri.net, 90% of the sites created with this CMS and that requested cleaning with this platform, experienced infections.

One of the main causes of this security flaw is the lack of maintenance and not because of the system kernel itself. Wordpress has an important community that acts quickly in the face of any vulnerability detected in the system.

However, it will be difficult to make use of the fixes if proper updates are not made on a regular basis. Below are 4 ways you can update Wordpress to improve the security and performance of your website.

1.- Update Wordpress Through the Administration Panel

Log in to the WordPress administration panel, with your usual username and password.

Within the menu of the WordPress administration panel you will find an option called Updates or Updates, which will show notifications in case there is one available.

Clicking on it will show the version of Wordpress available at the top, as well as a link that says Please, update now or Please, update now. By clicking on it, the platform will guide you to a new screen.

At the top you will find a warning, which refers that before updating you must make a backup of the site. Click on the backup your database and files link or back up your database and files.

When you do, your site will immediately go into maintenance. This means that if someone wants to access your website at that time, Wordpress will indicate that the page is not available due to scheduled maintenance and that they should check the site again in a few minutes.

At the moment when Wordpress finishes with the backup, it is necessary to press a click on the Update now button. The platform will indicate the steps that it performs in the process and when it is finished, it will send a new screen with a report of all the errors and security aspects corrected by this action.

This is one of the safest ways to update Wordpress.

2.- Update Wordpress via FTP

This step requires FTP client software. The most used is filezilla, which you can download for free from its page and is very easy to use, you only require the data of your FTP user and password provided by your hosting provider.

You'll also need to make sure you've backed up your site, just in case something doesn't go as expected.

First download and install the FTP client on your computer. Then go to the wordpress official site and download the latest version available.

When the download is complete, you will notice that the file is compressed. Use special software to unzip this file on your computer like Winrar, Winzip or something similar.

After unzipping, delete the wp-config-sample.php file and the wp-content folder. Next, connect via FTP to your server.

When doing so you will notice that there are two windows, one in which the files of your computer are located, located on the left side and called Local Site, while the Remote Site that is located on the right side shows the directory of your hosting.

Now find the root directory of Wordpress on your Remote Site and delete the wp-includes and wp-admin folders. If you use Filezilla, you will only have to select them, press the right button and choose the Delete option.

Next, find the wp-includes and wp-admin directories on your local Server or machine, and upload them to your hosting. To do this, it will be necessary to select both folders, press the right mouse button and choose the Upload option.

Select the remaining files found in the Wordpress folder on your local machine, and upload them to the remote Server as well. This will start a process of replacing the files, so a window will appear asking if you want to overwrite these files, choose the respective option and click OK.

3.- Update Wordpress through SSH

The first thing to do is connect to your hosting via SSH and when doing so, it is necessary to locate the root directory of Wordpress. If you have installed Wordpress inside the public_html folder then you will need to access it.

For this, type the command cd public_html. Then, enter the wp core check-update command to check if there is an update available.

If there are no updates, the message returned by the instruction will be Success: WordPress updated successfully. Otherwise, it will show you the details of the update file.

To start the update write the command wp core update. In this way, the website will start the update process.

At the end, it will be necessary to update the database, the theme and the plugins that you have updated. This must be done by executing the following instructions one by one:

wp core update-db

wp theme update --all

p plugin update --all

4.- Update Wordpress through cPanel

Wordpress has a function that will allow you to make constant updates, without having to constantly check their availability. For this it is necessary to include a line of code in the wp-config.php file.

To carry out the procedure in this way, you will have to access your hosting account and locate the File Manager in cPanel. In the files section, find the public_html folder and then the wp-config.php file.

Select the file and click on the File Manager Edit button. Now locate the line that indicates the statement define('WP_AUTO_UPDATE_CORE', false); change it to define('WP_AUTO_UPDATE_CORE', true); and click on Save.

This is a safe way to update. If you want to update the themes and plugins you can also do it in the Updates section of the administration panel.

Conclusion

Wordpress updates are a necessary practice to keep your website not only operational, but also working optimally while minimizing the risk of computer attacks.

There are 4 ways to perform these updates:

  1. Through the WordPress administration panel.
  2. Via FTP.
  3. By the WP-CLI using SSH connection.
  4. With automatic updates.

NOTE: It is no less a case of reminding you of the vital importance of keeping third-party Plug-ins or Complements developed for WordPress and that you have installed on your website to their most recent versions.

If you have any questions about any of these options, consult the Technical Support team, they will gladly come to your aid. ;-)

Search