There Has Been a Critical Error on This Website: What to Do?
There Has Been a Critical Error on This Website: What to Do?

There Has Been a Critical Error on This Website: What to Do?

Stefan Mikic
Stefan Mikic
Development
10
 min
 mins
5 Mar
2025
Table of content

WordPress users are no strangers to the message saying: ‘There has been a critical error on this website. Please check your site admin email inbox for instructions.’ Now, before you go into a full panic mode, relax and take a deep breath. Help is on the way. 

More often than not, you can fix the problem by reinstalling or deactivating a simple plugin or clearing the site’s cache. Sometimes, you need to dig a bit deeper than that. Stay tuned as we explore what causes this error, how to prevent it from plaguing your website, and how to fix it. 

{{cta}}

What Does “There Has Been a Critical Error on This Website” Mean?

The critical error in WordPress message signals that a fatal PHP error has occurred, preventing your website from loading. In other words, a code on your site, be it a plugin, theme, or WP itself, is broken, so the requested page can’t be generated. 

In WordPress versions before the 5.2 one, this error led to the so-called “white screen of death” — just a simple blank page. To reduce the initial shock of that blank page, WP opted for the error message “There has been a critical error on this website. Please check your site admin email inbox for instructions”. Together with the message, a link to the WordPress debugging guide is provided. 

Admins will also get an email (sent to the address set in your WordPress settings) with a link to your website, the link to the WP login, and a link to enter Recovery Mode via a token. The Recovery Mode allows users to log into wp-admin with plugins/themes temporarily disabled so you can troubleshoot the issue. 

Once you’ve logged in through the link, you’ll see a lot of information about what caused the critical error in the first place. The most common reasons are: 

  • One or more plugins failed to load properly
  • One or more themes failed to load properly
  • PHP Errors
  • Issues with the database 
  • Hosting issues 
  • Core WP files corrupted 

It’s also possible that the error was caused by malware inside your WP. A hacker could have inserted the code, or your hosting provider may have taken the site down for security reasons, so it pays to run a full security scan to make sure you are in the clear. 

How to Fix the Critical Error on Your WordPress Website

When you see a critical error message on your WP site, know that the push has come to shove. Luckily, you don’t need to be a developer to fix the problem. Here’s how you can do it. 

Step 1: Check Your Email for Debug Information

Remember the email we mentioned? That’s where you look first. Inside the email, usually titled “Your Site is Experiencing a Technical Issue”, are the links to the Recovery Mode as well as info on which specific file or plugin is causing the error. 

You’ll also see the line of code that’s the culprit, be it a part of a theme or a plugin. That information is usually at the bottom of the email. 

Step 2: Enable Debug Mode in WordPress

It’s a fairly smooth ride when you get the email with the instructions. However, when you don’t get one or it doesn’t tell you where the problem lies, things get tricky. That means you must activate WordPress’ debug mode to get errors to a log file without messing up your website. In other instances, you can use the debug mode to display the errors on a live website, but since it’s down, the log file is where you get the information. 

Here’s how you enable the debug mode: 

  1. Log into your server via FTP or SSH (Secure Shell);
  2. Locate and edit the wp-config.php file in your site’s root file;
  3. Find the following line: /* That's all, stop editing!  Happy blogging. */ or the line that says: define('WP_DEBUG', false);
  4. Replace the line: define('WP_DEBUG', false) with: 
    1. define( 'WP_DEBUG', true );
    2. define( 'WP_DEBUG_DISPLAY', false );
    3. define( 'WP_DEBUG_LOG', true );
  5. Reload your site to trigger the error again;

Now, all errors will be available under a file titled debug.log, found in your /wp-content/ directory.

Step 3: Deactivate Plugins and Themes

The most common issue that leads to “There has been a critical error on this website” is the one with plugins and themes. If you received the email from WordPress, you’ll already know which plugin or theme is causing the issue, so you can deactivate it and look for an alternative. On the other hand, manual deactivation is a bit more complicated than that. You’ll have to deactivate them all. 

  1. Access the WordPress area; 
  2. Go to the wp-content folder;
  3. Locate Plugins > Installed Plugins;
  4. Right-click the Plugins folder and choose the “Rename” option;
  5. Change the name of the folder so that WordPress can’t find it; 
  6. This will deactivate all of them;

You can now check the site to see if the plugins were indeed the problem. To find out which one, rename the folder back to “Plugins” and then rename each plugin’s folder one by one back to its original name. Refresh the site after each reactivation until you’ve discovered which one is responsible for the error message. 

If it wasn’t the plugins, then the active theme could be causing the critical error. You should then try switching to one of the default WordPress themes. Go to Appearance > Themes and activate a default one. 

In case you don’t have access to the dashboard, you’ll need to use FTP and go to /wp-content/themes/ and delete all folders found there. It’s prudent to first make a backup by downloading them to your computer. Now, upload the default theme folder to give your site a theme and reload. If the theme was the issue, your website should be working properly now. 

Step 4: Increase PHP Memory Limit

The PHP memory limit refers to the amount of RAM a single PHP script can consume. When this limit is exceeded, a critical error can crop up. To rule this out, you can increase the limit. Here’s how:

  1. Access the site using FTP;
  2. Open the wp-config.php folder again;
  3. Insert a line: define('WP_MEMORY_LIMIT', '256M') before the last one;
  4. Save;

This action will effectively raise the memory limit for WordPress to 256 MB​, which is enough for any plugin to run and fix the critical error issue. 

Step 5: Check for Corrupt Core Files and Reinstall WordPress

If the “There has been a critical error on this website” message persists, it’s time to turn your attention to core files. The good thing is that you can manually reinstall WordPress core without messing up your content. Here’s how you do it. 

  1. First, back up your website’s database and files. If you can’t access the database, check out this guide to fixing the WP database connection. 
  2. Get the latest WP version from the official WordPress site. 
  3. Using FTP, upload the wp-admin and wp-includes folders to your server, overwriting the existing folders. Don’t overwrite the wp-content folder or the wp-config.php file if you don’t want to delete your themes, plugins, and uploads. 
  4. Load the site again. 

If the problem was with the core WordPress files, this should fix it. 

Step 6: Restore a Backup of Your Website

When the white screen of death is at your website’s door, the fastest way to fix it is to restore a backup version. This will help you roll back to the previous working version of the site. Getting access to backups depends on the way they were stored in the first place. If your host provides backups, log into your hosting account and restore the site files from there. In other instances, a backup plugin could have been used.

Note that restoring to a previous version may lead to the loss of some content or settings, so make sure to use this option as a last resort. 

Step 7: Upgrade PHP Version

Outdated PHP versions can also cause a critical error on your WordPress site. Any WP website requires PHP version 7.4 or greater. The latest PHP version is 8.4. You can see the version your site is powered on by visiting the Tools > Site Health page. Switch to the “Info” tab and click on the ‘Server’ tab to see the information about your server, including the version of PHP. Depending on your hosting account, there will be different ways of updating the PHP version, so make sure to contact your hosting provider. 

How to Prevent Future Critical Errors

Prevention is better than cure. The same goes for critical errors on your WordPress website. You can significantly reduce the probability of hitting a snag like this by doing the following: 

  • Change Your CMS — Patching plugins and troubleshooting PHP can eat up your time. No doubt about it. If you are getting more of those than your share, then switching to a different CMS is the answer. The best option there — Webflow. Migrating WordPress to Webflow as your CMS of choice brings all-in-one hosting and security features, native features that require no plugins that can cause the issue, and top-of-the-line performance and scalability.  
  • Backup your site regularly — Always have a recent backup of your site files and database. This will help you restore the site quickly in case of an emergency. 
  • Update your PHP version, plugins and themes — Make a habit of regularly updating plugins/themes and PHP versions. Outdated software is prime for errors and conflicts; you don’t want that. 
  • Keep the WordPress Core updated — Usually, known bugs and errors with WordPress are fixed with the latest software updates. Make sure your site runs on the latest core version of WP. Note that there can be issues with updating WordPress as well. However, most of the time, it has to do with a slow internet connection or a simple software bug. 
  • Monitor your site’s performance — Keep an eye on your site’s error logs and performance. Sometimes, recurring smaller errors (visible in the debug.log or host error logs) can hint at a problem in the making before it reaches that “critical” stage. Any warnings regarding plugins or anything else should be handled as soon as possible. 

{{cta}}

Final Thoughts

WordPress errors happen. It happens more often than most WP users would like to admit. A faulty plugin, a bad update, or a server issue, and suddenly, you’re staring at the dreaded "There has been a critical error on this website" message. The good news? It’s fixable. Usually, a simple disabling of plugins and themes or increasing the PHP memory limit will do the trick. 

However, if debugging plugins, managing updates, and fixing crashes is starting to feel like a full-time job, maybe it’s time to ditch WordPress altogether. If you’re thinking about making the switch to Webflow, Flow Ninja can handle the migration for you — seamlessly and without any downtime. Contact us now for more information. 

Stefan Mikic

Stefan Mikic

Stefan is the CTO at Flow Ninja.

More about 
Stefan Mikic
Free Ebook
Scalability issues
Speed issues
Security issues
SEO issues
Get for free

Navigating Common WordPress Problems: A Marketer's Guide

Learn more about the most common problems marketers face when using WordPress and find out how to solve them.

Scalability issues
Speed issues
Security issues
SEO issues
Download for free

Your go-to Webflow
resources library

Growing a Webflow project is hard. We make it easy.

Grow my project
Mihajlo Djokic Account ExecutiveUros Mikic CEO of the Flow Ninja
Get a free consulting call with our experts

Get your free resource

Enjoy your free resource!
❤️
Oops! Something went wrong while submitting the form.