How to Reinstall WordPress Without Losing Data

How To Reinstall Wordpress Without Losing Data

There are +455 million websites online that use WordPress as a CMS, and issues can arise with it. Sometimes when you’re reinstalling WordPress, you can lose all of your data. It can be really frustrating and time-consuming to restore everything. That’s why I’m here to guide you on how to reinstall WordPress without losing data.

In this article, you’ll learn:

  • Create a Backup
  • How to reinstall WordPress without losing data

Let’s start with creating a backup.

Create a Backup

Before you begin the process of reinstalling WordPress without losing data, you’ll need to create a backup of all the content on your site. It includes all the media, posts, plugins, themes, and the database.

Step 1: Installation

Start off by going to the “Plugins” section and clicking the “Add New” option.

Go To “Plugins” And Click The “Add New” Option

Search and install the “UpdraftPlus WordPress Backup” plugin.

Search And Install The &Quot;Updraftplus Wordpress Backup&Quot; Plugin
Search And Install The “Updraftplus Wordpress Backup” Plugin

Once the installation has concluded, stay on the page and click the “Activate” button.

Activate The &Quot;Updraftplus Wordpress Backup&Quot; Plugin
Activate The “Updraftplus Wordpress Backup” Plugin

Step 2: Creating Backup

Now go to the “Settings” and click the “UpdraftPlus Backups” option.

Go To &Quot;Settings&Quot; And Click On The &Quot;Updraftplus Backups&Quot; Option
Go To “Settings” And Click On The “Updraftplus Backups” Option

Click the “Backup Now” button to create the backup of the site.

Click The &Quot;Backup Now&Quot; Button
Click The “Backup Now” Button

Ensure that you check the boxes regarding the website and click the “Backup Now” button.

Create The Backup
Create The Backup

The backup for the website will be ready with all the plugins, themes, uploads, and database.

All The Files Are Backed Up
All The Files Are Backed Up

You can download all of them one at a time by clicking the option and clicking the “Download to your computer” button.

Download One At A Time
Download One At A Time

How to Reinstall WordPress Without Losing Data

There are several methods you can use to reinstall WordPress without losing data. Some of them are extremely simple, and the others are a bit intricate; however, no need to worry. I’ve got your back and will guide you through all of the processes of reinstallation.

Let’s start with the simplest one, which requires no more than 2 steps.

Method 1: Use the Dashboard

This is the easiest method that you can use for the reinstallation process. It doesn’t require any kind of plugins or extensive web development knowledge.

All you need to do is go to “Dashboard” and click the “Updates” option.

Go To The Dashboard And Click The &Quot;Updates&Quot; Option
Go To The Dashboard And Click The “Updates” Option

After that, you’ll see the “Re-install” button.

Note: The reinstall button will display the latest version of WordPress, so it may differ depending upon when you’re using this guide.

Click The &Quot;Re-Install Version&Quot; Button
Click The “Re-Install Version” Button

Once you press the button, it’ll reinstall WordPress without losing data or any of your vital information.

This Is How You Can Reinstall Wordpress Without Losing Data
This Is How You Can Reinstall Wordpress Without Losing Data

To be honest, this is the only method that I prefer, and you should also only use this method. The reason for it is that if you use any other method, then there are bound to be some issues that arise sooner or later.

Method 2: Using the WP Reset Plugin

If for some reason, the above-mentioned method doesn’t work for you, there is another simple method that you can use. You can use the WP Reset plugin to reset your site to its original state.

The main benefit of using this plugin is that you can control what things you want to remove from your site during the reinstallation process. Meaning you can reset and reinstall WordPress without losing data.

Step 1: Installation

It’s a given that before you start the reinstallation process, you’ll need to install the WP Reset plugin. 

Go to “Plugins” and click the “Add New” option.

Go To The &Quot;Plugins&Quot; And Click The &Quot;Add New&Quot; Option
Go To The “Plugins” And Click The “Add New” Option

Search and install the “WP Reset” plugin.

Search And Install The &Quot;Wp Reset&Quot; Plugin
Search And Install The “Wp Reset” Plugin

After the installation process, click the “Activate” button.

Activate The &Quot;Wp Reset&Quot; Plugin
Activate The “Wp Reset” Plugin

Now that the installation process for the plugins has concluded, let’s move on to the reinstalling process for WordPress.

Step 2: Reinstalling WordPress

First, go to “Tools” and click the “WP Reset” option.

Go To &Quot;Tools&Quot; And Click The &Quot;Wp Reset&Quot; Option
Go To “Tools” And Click The “Wp Reset” Option

Go to the “Reset” section.

Go To The &Quot;Reset&Quot; Section
Go To The “Reset” Section

Next, you’ll scroll down and see a section labeled “Site Reset.” Before you reset anything, you’ll need to make sure that you create a snapshot of the current site.

Note: It isn’t necessary if you’ve already created a backup of the site, but it is highly recommended.

Click the “Create snapshot” button.

Click The &Quot;Create Snapshot&Quot; Button
Click The “Create Snapshot” Button

Now, you’ll give a name to the snapshot and click the “Create snapshot” button.

Enter The Name For The Snapshot And Click The &Quot;Create Snapshot&Quot; Button
Enter The Name For The Snapshot And Click The “Create Snapshot” Button

Once you’ve created a snapshot, type in “reset” in the space provided and click the “Reset Site” button.

Type In &Quot;Reset&Quot; And Click The &Quot;Reset Site&Quot; Button
Type In “Reset” And Click The “Reset Site” Button

It’ll make sure to reset the website to its original state. You also have the option to select what other aspects of the site you want to reset, such as content, plugins, themes, etc.

The free version of this plugin is somewhat limited, but it gets the job done. If you want to get the full benefit of the plugin’s features, then you’ll need to buy it from their site.

Method 3: Using cPanel

If for some reason, the dashboard method doesn’t work for you and you don’t want to use a plugin for the reinstallation process due to it being used for hacking purposes, then there is another way to reinstall WordPress without losing data.

Keep in mind that this method is quite lengthy and can get complicated at some points. So just follow each of the steps carefully, and hopefully, you shouldn’t face any issues.

Step 1: Export the XML File

For this step, you first need to open the dashboard of your site. After that, go to “Tools” and click the “Export” option.

Go To &Quot;Tools&Quot; And Click The &Quot;Export&Quot; Option
Go To “Tools” And Click The “Export” Option

Next, you’ll need to select the “All content” option.

Note: You can also choose specific options if you need to remove some of the unnecessary things.

Click On The &Quot;All Content&Quot; Option
Click On The “All Content” Option

After that, scroll down and click the “Download Export File” button.

Click The &Quot;Download Export File&Quot; Button
Click The “Download Export File” Button

After that, you’ll see that an XML file has been downloaded with the name of the site on it.

The File Is Downloaded With The Website Name
The File Is Downloaded With The Website Name

This XML file will keep the necessary information of your site secure. It will be used at the end when you’ve completely reinstalled WordPress.

Step 2: Create a Zip File for the Content

Now you’ll go to the dashboard of cPanel and click on the “File Manager” option.

Click The &Quot;File Manager&Quot; Option
Click The “File Manager” Option

You’ll be able to see a folder by the name of “public_html,” which contains all the necessary files for your website.

Note: If you have more than one site on cPanel, then you’ll first need to identify the folder of the website, and then you’ll be able to see the “public_html” folder.

Click On The &Quot;Pubic_Html&Quot; Folder
Click On The “Pubic_Html” Folder

Here you’ll see a collection of files and folders. Locate the “wp-content” folder and right-click on it. A menu will appear from which you’ll click the “Compress” option.

Right-Click On The &Quot;Wp-Content&Quot; And Compress It
Right-Click On The “Wp-Content” And Compress It

Next, you’ll select the “Zip Archive” option and click on the “Compress Files” button.

Choose The &Quot;Zip Archive&Quot; Option And Click The &Quot;Compress Files&Quot; Option
Choose The “Zip Archive” Option And Click The “Compress Files” Option

A box will appear, which you close.

Click The &Quot;Close&Quot; Button
Click The “Close” Button

After successfully creating the zip file, you’ll need to keep it secure in another folder.

Step 3: Create a Temporary Folder and Move the Zip File

Go out of the “public_html” folder and click on the “Folder” option on top of the screen. You’ll see a box in which you’ll first enter the name of the folder and then click on the “Create New Folder” button.

Create A New Folder That Will Be Temporary
Create A New Folder That Will Be Temporary

Now go back and right-click on the “wp-content.zip” file. From the menu, click on the “Move” option.

Right-Click On The &Quot;Wp-Content.zip&Quot; File
Right-Click On The “Wp-Content.zip” File

A box will appear where you’ll type in the destination of the zip file. Type in the name of the temporary folder that you created and clicked the “Move Files” button.

Type In The Temporary Folder Directory And Click The &Quot;Move Files&Quot; Button
Type In The Temporary Folder Directory And Click The “Move Files” Button

The file will be moved to the temporary folder that you created.

The Zip File Is In The Temporary Folder
The Zip File Is In The Temporary Folder

Step 4: Downloading the wp-config.php File

You might be asking yourself, “Why this file?” The reason behind it is that it has all the necessary information regarding your username, password, hosting, database, etc. You’ll need it when you’re about to reinstall WordPress.

Go back to the “public_html” folder and right-click on the “wp-config.php” file. From the menu, click on the “Download” option. 

Download The &Quot;Wp-Config.php&Quot; File
Download The “Wp-Config.php” File

Note: You can also download the file by simply double clicking on it.

Step 5: Delete All the Files on the Site

This is one of the terrifying step of the entire process. Go to the “public_html” and select all the files by clicking on the “Select All” checkbox.

Select All The Files By Clicking The Checkbox
Select All The Files By Clicking The Checkbox

Right-click on the selected files and click on the “Delete” option.

Right-Click On The Selected Files And Click The &Quot;Delete&Quot; Option
Right-Click On The Selected Files And Click The “Delete” Option

A box will appear on the screen. Click the “Skip the trash and permanently delete the files” and click the “Confirm” button.

Click The Checkbox And Click The &Quot;Confirm&Quot; Button
Click The Checkbox And Click The “Confirm” Button

All of the files will be deleted, but don’t worry; we’ve already secured the wp-content.zip file, which means that you can reinstall WordPress without losing data.

Step 6: Uploading and Extracting the Setup File

Go to the official WordPress website and click on the “Get WordPress” button on the top right corner of the screen.

Go To The Wordpress Website And Click The &Quot;Get Wordpress&Quot; Button
Go To The Wordpress Website And Click The “Get Wordpress” Button

On the next page, click on the “Download WordPress” button.

Note: The button also displays the version of WordPress you are about to download.

Click On The &Quot;Download Wordpress&Quot; Button
Click On The “Download Wordpress” Button

After downloading the latest version of the file, open the cPanel and open the “public_html” folder. Now click on the “Upload” option.

Click The &Quot;Upload&Quot; Button
Click The “Upload” Button

You’ll be redirected to another page where you’ll click on the “Select File” button.

Click The &Quot;Select File&Quot; Button
Click The “Select File” Button

Upload the zip file of the WordPress setup. Select the setup and click on the “Open” button.

Upload The Setup File
Upload The Setup File

Once the upload has concluded, right-click on the setup and click on the “Extract” option.

Extracted The Uploaded Setup File
Extracted The Uploaded Setup File

Select the path and click the “Extract Files” button.

Click The &Quot;Extract Files&Quot; Button
Click The “Extract Files” Button

A WordPress folder is now present in the selected folder. Open the folder and select all of the files and folders.

Open The &Quot;Wordpress&Quot; Folder
Open The “Wordpress” Folder

After selecting all of the files and folders, right-click on them and click on the “Move” option.

Move All Of The Files Out Of The Folder
Move All Of The Files Out Of The Folder

You’ll see a box with the pathway where you want to move the files. All you have to do is to remove “WordPress” from the pathway and click the “Move Files” button.

Remove The &Quot;Wordpress&Quot; From The Directory And Click The &Quot;Move Files&Quot; Button
Remove The “Wordpress” From The Directory And Click The “Move Files” Button

After moving all of the files and, select the “WordPress” folder & the setup zip file.

Select The Empty Folder And The Zip File
Select The Empty Folder And The Zip File

After selecting both of them, you can delete them.

Right-Click And Click On The &Quot;Delete&Quot; Both Of Them
Right-Click And Click On The “Delete” Both Of Them

Step 7: Reinstall WordPress

Open the website, and you’ll see the entire installation process of WordPress will start. Here you’ll select the language for the website and click the “Continue” button.

Select The Language And Click On The &Quot;Continue&Quot; Button
Select The Language And Click On The “Continue” Button

After that, it’ll provide the introductory message, and you’ll click on the “Let’s go!” button.

Click The &Quot;Let's Go!&Quot; Button
Click The “Let’S Go!” Button

On the next page, it’ll ask you to enter the username, hosting, database, etc. For this, you’ll open the “wp-config.php” file that you previously downloaded and use the credentials provided in that file.

After entering all the details, click the “Submit” button.

Enter The &Quot;Wp-Config.php&Quot; Credentials And Click The &Quot;Submit&Quot; Button
Enter The “Wp-Config.php” Credentials And Click The “Submit” Button

After that, you’ll go through the same installation process as always. After that, you’ll need to import the previously exported XML file.

Step 8: Importing the XML File

Open the dashboard after the reinstallation process. Go to “Tools” and click on the “Import” option.

Go To &Quot;Tools&Quot; And Click On The &Quot;Import&Quot; Option
Go To “Tools” And Click On The “Import” Option

Go to the bottom and look for the “WordPress,” and click on the “Run Importer” option.

Click The &Quot;Run Importer&Quot; Under The &Quot;Wordpress&Quot; Option
Click The “Run Importer” Under The “Wordpress” Option

Click the “Choose File” button.

Click The &Quot;Choose File&Quot; Button
Click The “Choose File” Button

Select the file XML field and click the “Open” button.

Upload The Previously Downloaded Xml File
Upload The Previously Downloaded Xml File

After the XML file is uploaded, click on the “Upload file and import” button.

Click The &Quot;Upload File And Import&Quot; Button
Click The “Upload File And Import” Button

On the next page, select the author you want to import and click the “Submit” button.

Import An Author And Click The &Quot;Submit&Quot; Button
Import An Author And Click The “Submit” Button

Step 9: Moving the Content Back

Before you move back the content, you’ll first need to delete the wp-content folder that was created due to the new setup.

Go to the “public_html” folder and then right-click on the “wp-content” folder. After that, click on the “Delete” button.

Delete The &Quot;Wp-Content&Quot; Folder Created Due To The Setup
Delete The “Wp-Content” Folder Created Due To The Setup

Now you’ll open the temporary folder where you previously moved the wp-content.zip file. Right-click on the “wp-content.zip” and click on the “Move” option.

Move The Previously Zip File Back To The &Quot;Public_Html&Quot; Folder
Move The Previously Zip File Back To The “Public_Html” Folder

In the box that pops up, enter the directory where you want to move the zip file.

Enter The Directory And Click The &Quot;Move Files&Quot; Button
Enter The Directory And Click The “Move Files” Button

After moving the file, you’ll need to extract it.

Extract The Zip File
Extract The Zip File

Just click the “Extract Files” button, and you’ll be done.

Click The &Quot;Extract Files&Quot; Button
Click The “Extract Files” Button

Finally, the entire process of reinstalling WordPress without losing data has concluded. I told you that it does have a lot of steps, and it can be very complicated for an average website owner, but this method is more of a case “if you want to, you can” kind of situation.

Conclusion

You can use any of the above-mentioned methods to reinstall WordPress without losing data. However, the method you want to use depends on your choice.

The first two methods are the simplest ways to reinstall WordPress, and those are my preferred choice. However, if you feel like taking a risk, then you can also use the third method; however, be prepared for a long and complicated ride.

If you know another way to reinstall WordPress without losing data, then tell us in the comment sections down below. 

Related Posts

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Subscribe to our Monthly Newsletter

Get monthly updates of WordPress tips, tricks, and tutorials in your email.

Thanks. You have successfully subscribed.

Pin It on Pinterest