Your WordPress website met some common errors. No troubleshooting method worked.
As a last resort, reinstall WordPress to fix the issue!
However, this should be your last option and before you opt to reinstall WordPress, first try to identify the error source and then fix it.
If nothing seems to solve the issue, uninstalling and then reinstalling WordPress will definitely bring relief.
Here is a quick WordPress tutorial showing step-by-step ways to easily reinstall WordPress.
In this guide, you will learn:
- How to reinstall WordPress without losing content – the automatic way
- How to reinstall WordPress without losing content – the manual way
- How to reinstall WordPress with all content lost
- Uninstall WordPress entirely and then reinstall it
Create a Backup
Before you proceed to any reinstalling method, first backup your website.
You have three options to backup your site:
- In your PC storage
- Remotely on any cloud storage service
- Using backup plugins
Backup data is not required for the reinstalling process. This is just a precautionary measure taken to secure all the website content in case something goes wrong.
Reinstall WordPress Automatically (2 Steps)
Method 1 can only be used when you have access to your site's admin dashboard.
It is effortless to reinstall WordPress using this method as all the processes are run automatically.
Reinstalling WordPress From Admin Dashboard
Follow the workable steps below to reinstall WordPress directly from the admin dashboard.
Step 1: Go to Dashboard → Updates
This opens the WordPress updates page, which informs you about any available updates. Here you can also check which plugins or themes need updating and can also manually set auto-updating.
Step 2: Scroll down to the Re-install Now button and select it.
This is it. It will take a few seconds, and WordPress will be reinstalled with all the contents safe in their places. You will be prompted to the “Welcome to WordPress” page showing you the latest features in the updated WordPress version.
Reinstalling WordPress Manually (No Content Lost)
Sometimes you can't access the WordPress dashboard due to some unknown error.
This will mean that you have to reinstall the website using:
- An FTP client (we recommend Filezilla) or
- WP-CLI (Command Line Interface tool)
Note: The latter method is designed for developers. If you are a beginner, you can try reinstalling WordPress with an FTP client.
Method 1: Reinstalling WordPress from FTP
Like the one above, this method keeps all your existing content, themes, and plugins safe. It only reinstalls the core WordPress files, so you may diagnose the issue that is causing the error.
Follow this quick step-by-step below:
Step 1: Go to WordPress.org and download the latest version of WordPress from there.
WordPress is downloaded as a zip file.
Extract the zip file to your PC, which opens all the folders of your WordPress site.
Step 2: Delete the wp-content folder keeping all the other folders as it is.
The wp-content folder is deleted to keep all your previous plugins and current theme unchanged on your site.
To delete this folder, simply navigate to the sub-folder named ‘wp-content' and right-click on it. Go down to the delete option and click on it.
Step 3: Download and install an FTP client named FileZilla.
Open the installed file to fill in credentials that include:
Connect to your website by clicking on Quickconnect.
Step 4: FileZilla shows local files on your PC on the left side.
Scroll down to the root WordPress directory (the location where WordPress was installed initially). This folder is usually the Public_html folder/Public folder.
Note: WordPress can be installed in any other location too. You must know where exactly it was installed.
Open all contents of WordPress (which excludes the wp-content folder as you deleted it).
Select all the files and right-click to open the drop-down menu.
Select upload from this menu.
Next, what appears on your screen is a warning displaying ‘The target file already exists.'
Choose overwrite (from the action menu) → Ok.
You have successfully reinstalled the core WordPress software using FTP.
Method 2: Reinstalling WordPress from WP-CLI
WP-CLI is a Command Line Interface tool that lets users manage their WordPress site using commands.
You can only use this method when your hosting server gives you access to SSH (Secure Shell)
Good WordPress hosting services make accessing your website remotely a simple task. One that supports the SSH protocol allows users to run commands on their remote machines. The encryption of data ensures secure file transfer.
Follow the guide below.
Step 1: Install WP-CLI.
Step 2: Enter the following command to reinstall WordPress core
wp core download –skip-content –force
What Does This Command Mean?
These commands are alternate to performing all the steps in the reinstalling methods advised above.
Wp core download: It downloads all the WordPress core files.
Skip content: It skips themes and plugins when downloading the WordPress core. This is the same step you performed manually in the FTP client method. You deleted the wp-content folder to keep the default themes and plugins from overriding.
Force: It makes sure all files (except plugins and themes) are overridden.
Reinstalling WordPress Manually (All Content Lost)
This method will delete every existing content from your website.
You will be left with a new website, which will be completely blank.
DO NOT USE this method if you want some part of your website to remain undeleted.
The warning above clearly states that your website will be entirely deleted using this method to reinstall WordPress. Proceed with this step if you want a new website and need the old content.
However, if you have made a backup of your WordPress website, you can restore your website with a change of mind.
Reinstalling a WordPress website by deleting all the data includes three simple steps:
- Remove WordPress software by deleting all WordPress files
- Erasing the entire WordPress database
- Fresh reinstall of WordPress
Let's visit each step in detail.
Step 1: Delete all WordPress Files via FTP Client.
Connect your WordPress website using FTP client (preferably FileZilla) and locate the folder where WordPress files are stored. It will most probably be lying in the public_html file.
Select all the subfolders using Ctrl+A (Cmd for Mac) and click delete.
You no longer have the WordPress software with you.
Step 2: Erase all WordPress Database using cPanel
- Login to your cPanel. The interface of cPanel enlists all existing MySQL databases.
Search for the database you want to delete and click on ‘Remove Database.'
Now you have wiped out your website thoroughly!
This is an optional step. You can create a new database when you create a new WordPress site. But this can be a problem if the host puts a restriction on the number of databases that a user can have at one time.
Again, we remind you that this method will completely reset your WordPress website, and you will be left with a blank slate. We can't stress enough how sure you need to be about losing all your WordPress data.
All your settings and content are present in the database. Deleting all the existing files means you are starting afresh.
Alternatively, Use Plugins to Delete the Database
WordPress literally has a plugin for every purpose, from security plugins that keep track of all malicious activities on your site to database reset plugins.
Simply go to the plugins option under the main dashboard menu and navigate to add new.
Type in “Database Reset” and install and activate any of the plugins that come enlisted.
For the plugin ‘WP Database Reset', follow the instructions below.
How to Delete a database using the WP Database Reset plugin?
Tools → Data Reset → Select all tables → Reset tables.
This plugin reset the WordPress database tables back to their default settings in a one-click process. You can skip those tables that you don't want to delete. For example, you want the user to be saved with you. Simply click on Remove next to the user tables option.
Just as these plugins make the process of deleting the database super-fast, they are not reliable. There are two reasons why going for the first method to delete the database rather than plugins is a better choice:
- If someone wants to reinstall WordPress, it can be because he can't access the dashboard panel. Using a plugin to delete databases is an option only when one has access to the dashboard.
- Sometimes plugins are incompatible with other plugins and cause new errors.
Step 3: Fresh WordPress Installation
You have uninstalled WordPress successfully. No trace of your old website remains. The last step is to install the latest version of WordPress again from WordPress.org.
Once you set up the new website, install the themes and plugins, and start adding new content to your website.
We hope this guide helped you to reinstall WordPress without any problem.
Here is a quick revisit to the reinstalling methods we discussed in our post:
Methods in which no content is lost include:
- Reinstall WordPress automatically using the dashboard
- Reinstall WordPress using FTP
- Reinstall WordPress using WP-CLI
The method in which all content is lost, but a backup saves you.
- Uninstall all WordPress core files and reinstall WordPress from scratch.
There is no doubt that if you have access to a dashboard, then using the first method (automatic reinstalling WordPress using dashboard) should be your primary choice. This step takes no time and doesn't require one to know a lot about the functioning of WordPress.
However, if an error is obstructing access to the dashboard, we recommend using the FTP client method. You may use the WP-CLI option too, but this method is specially crafted for developers who are experts at command line usage.
We will await your valuable feedback.