How do you fix a critical error on this website?

You’ve come to the right place if you are facing the problem “there is a critical mistake on this website.” This is the best place to look for a fix. As a web developer, I have faced this problem many times, not only on my website but also on my clients’ websites.

This problem has been solved successfully every time. This is usually due to using the wrong themes, plugins, or PHP versions. It is important to identify the root cause of this problem.

You’ll know what to do once you have identified the problem. There has been a critical mistake on this website. Let’s look at the details, which will allow you to understand the cause and best solution.

What is “There has been a critical error on this website” and its causes

If you’ve ever received the warning “There’s been a critical mistake on this website,” don’t worry; I’ve got you covered! I’ll break down all the possible causes so you know what is happening.

The use of bad themes and plugins is a common cause. The seemingly innocent additions to your website can cause havoc behind the scenes. I recommend using premium themes such as Astra, Divi Kadence, and others.

The PHP version, as well as the memory limit, can also be a problem. Compatibility issues can arise when using an outdated PHP version. PHP’s memory limit is 32MB, which is the standard memory limit.

It’s as if you run out of space when your website reaches its PHP memory limits. The website can’t perform the tasks that it is supposed to, leading to a critical error. Your site is saying, “Hey! I’m not able to do this. I need more RAM!”

The other two major causes are malware and the cache of the website. All these problems can be easily solved if you follow the guidelines I will discuss below. Let’s get started.

How to Solve Website Errors – 8 Effective Ways

Here are eight effective ways to fix the “critical error” on this website problem. It’s important to start with the first solution, “checking the site theme,” and then progress onwards.

Check the Theme

When one of my clients or I encounter the “there was a critical mistake on this website” problem, I first check the theme. If you want to avoid issues, a good theme is important. It directly impacts the user experience and can cause errors.

Some themes may be badly coded, lacking proper updates, or conflicting with other elements of your website. If a theme has been coded haphazardly or contains errors, this can have ill effects on your website’s operation.

How can you avoid such a mishap? It’s as simple as choosing a theme from reputable resources. Choose free themes or premium and developed by authors you trust who maintain them. You can easily change the WordPress theme using cPanel.

Login to cPanel.

Select ” File Manager”.

Choose “Public_HTML,” “WP Content,” and “Themes,” and then click “Save.”

Choose the ” Upload ” option from the ” Themes ” file.

Download the zip file and extract it into the same folder.

After extracting the “zip file,” delete it.

You’ve changed the theme successfully.

Three WordPress themes are recommended to create your website!

Deactivate Faulty Plugins

The plugin is next in line to cause problems. Not all plugins cause problems, but certain ones can. This is the primary reason why I only install necessary plugins. You may have more problems if you use more plugins.

Try to recall the plugins you downloaded within the last few days. Recently downloaded plugins usually cause this critical error. Please remove the plugin from cPanel after you have discovered it.

Login to your website’s cPanel.

Find the Public_HTML file by selecting ” File manager”.

Choose “Plugins” or ” Wp content.”

Find the plugin that you wish to remove and delete it.

If you do not know which plugin is causing the problem, then deactivate them all. Due to the error, it is impossible to access your WordPress dashboard. The only way to do this is through cPanel.

Click on ” file manager” in the cPanel.

The ” WP content” file can be found by clicking on ” Public_HTML.”

Rename the folder “plugin” to “plugin XXX.”

Check your website to see if it is working.

Rename the file from “plugin XXX ” to “plugin” again.

Increase PHP Memory Limit

PHP memory limits in WordPress are the maximum amount of memory PHP, the scripting engine that powers WordPress can utilize when executing scripts. WordPress has a default memory limit of 32MB to ensure compatibility.

PHP cannot handle the workload when the script exceeds this limit. This leads to “memory exhaustion”. This condition of exhausted memory triggers “There has been an error on this site.” The easy way to solve this problem is to increase PHP’s memory.

You can access your cPanel.

Please open the file wpconfig.php by selecting it.

Edit this file by adding the code at the end: define(‘WP_MEMORY_LIMIT,’ ‘128M’);

Save your changes and test the website.

Clear website cache

Clearing the cache is a good way to troubleshoot if visitors are reporting strange behavior or errors on your website. This has helped me solve the problem of “there was a critical mistake on this website” many times.

Login to your hosting’s cPanel.

Click on “LiteSpeed WebCache Manager.”

Select “Flush All” from the “Flush LS cache” section.

Try to log into your website after clearing the cache using the “Flush All” option.

Follow the other solutions if you still see the error.

Check the simple caching process if you are using Cloudways to fix this WordPress error.

Update PHP Version

The WordPress PHP Version is the PHP version that your WordPress website currently uses. It’s vital to update your PHP version for the security of your site.

The latest PHP versions may not have the functions necessary to support the new WordPress themes and plugins. The mismatch can cause conflicts and errors.

Login to the WordPress dashboard.

Choose ” Tools Site health ” from the list of options.

Scroll down and select ” server ” from the ” info ” tab.

Check the PHP version in the server settings.

Update your version as soon as you can using cPanel. PHP 8.2 is the current version. It may be different when you read this guide. Always check for updates.

If you wish to update all your websites, select the ” Multi PHP Manager” option.

If you only have a single site, select ” Select the PHP version.”

Select the most recent PHP version from the drop-down menu.

Click ” Apply” after selecting the latest version.

Note: Cloudways users can easily update or change the PHP version.

Fix Error Logs

The error logs can be very helpful to website administrators and developers in diagnosing and solving problems. The WordPress error logs contain any warnings or errors that are generated during the PHP script execution on your site.

Check your error logs in cPanel.

Find the ” error log ” file in the ” public_HTML ” folder.

Check the last few entries in the error log file.

The main error can be seen in the last entries of the logs.

Please solve the problem after you have found it. I don’t know what the problem is, so I can’t talk about the solution. If you are not an expert in this field, I recommend that you seek professional help.

Leave a Reply

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