Voxfor - All rights reserved - 2013-2025
We Accepted





Are you encountering the “Maximum Execution Time Exceeded” when updating a WordPress plugin or theme? So, how to fix a fatal error if the maximum execution time is exceeded?
This problem will appear when a PHP script runs for too long, surpassing the maximum execution time limit set by your hosting server. You can fix the WordPress error of “increase the maximum execution time“. This limit helps prevent the overuse of server resources. I’ll show you how to fix this error easily.
When dealing with the “Maximum Execution Time Exceeded in WordPress” issue, it’s essential to consider the security of your website. Implementing robust security measures, such as DDoS as a service, can not only help protect your database but also ensure uninterrupted access and prevent potential attacks that might lead to connection errors.
The maximum execution time exceeded occurs because PHP, the programming language behind WordPress, imposes a time limit on how long a script can run.
The safety measure is designed to prevent servers from being overwhelmed by long-running scripts, which could degrade server performance or lead to crashes. Hosting providers set different time limits, usually ranging from 30 to 60 seconds. When a PHP script on your site exceeds this set time, it triggers the maximum execution time seconds exceeded error.
This error ensures that no single process can monopolize server resources indefinitely, maintaining overall server health and performance.
How to fix a fatal error when with maximum execution time is exceeded? Despite being called a ‘fatal error,’ this is one of the most common and easy-to-fix WordPress errors.
Opting for managed WordPress hosting can simplify the process of resolving errors like ‘Max Execution Time Exceeded’ with professional support and automatic optimizations. Find out how to order managed WordPress hosting.
Here are several methods to resolve it:
Method 1: Use WordPress Recovery Mode
If the error occurs, WordPress can display a ‘This site is experiencing technical difficulties‘ error. You may also have been emailed a link to log in using ‘Recovery mode.’ You can deactivate or delete the offending WordPress theme or plugin here.
Method 2: Edit Your .htaccess File
If you can’t access your WordPress dashboard, manually edit your .htaccess file by adding a simple line of code. Use an FTP client or your hosting dashboard’s File Manager to access this file, located in the same directory as your /wp-content/ and /wp-admin/ folders. Add the following code at the bottom:
php_value max_execution_time 300
Save and upload the file. If the error persists, try increasing the value to 600 seconds.
A php.ini file, a configuration file of PHP settings. If it isn’t present, create one in your main folder through the FTP client or File Manager. Add the following line:
max_execution_time = 60
Save and upload the file to your server.
Editing your .htaccess file can be easier with a Cpanel lifetime license. Access your wp-config.php file in your main directory through the FTP client or File Manager. Add the following line before the ‘That’s all, stop editing! Happy blogging.’ comment:
define(‘WP_MAX_EXECUTION_TIME’, 300);
Setting a custom maximum execution time for your site helps manage processes more effectively. Start with 300 seconds and increase if necessary.
When your database is bloated, it can slow down your site, and if that’s the case, you’ll get this error. Any time you add data to a database, you have to optimize it to remove unwanted items regularly.
Poorly coded plugins can cause execution timeouts. Deactivate all plugins to verify if the error disappears. If it does, reactivate them one by one to identify the culprit. If you can’t access the admin area, you can deactivate plugins without wp-admin access.
Once identified, contact the plugin author for support and consider using well-reviewed plugins from trusted sources. If these methods don’t resolve the issue, contact your hosting provider for assistance.
The simplest approach to check your current maximum execution time value is to install the phpinfo WordPress plugin. This plugin provides comprehensive details about your PHP configuration, including the maximum execution time setting.
If your hosting provider restricts changes to the maximum execution time, consider these options:
By exploring these options, you can effectively manage and optimize your site’s performance within the constraints of your hosting environment. Learn more about handling server-related errors in our post on how to fix SSH connection refused errors.
Prevention is always better than cure, and this holds for WordPress. Encountering the ‘max execution time exceeded‘ error can be exhausting, especially when you rely on the fastest-managed WordPress hosting to keep your site running smoothly.
If you encounter website downtime due to the max_execution_time error, taking preventive measures is vital.
Here are some ways to prevent this issue:
If you believe a plugin is causing the timeout, you can determine the problematic one through elimination.
This method is effective for consistent errors. Intermittent errors are more challenging to pinpoint.
1. Troubleshoot Your WordPress Theme
Although it’s uncommon, a WordPress theme might have a script complex enough to cause a timeout. If troubleshooting plugins doesn’t help and the error occurs during theme updates, your theme might be the issue. You can choose a suitable and affordable WordPress hosting for your site.
If the error continues with the default theme, the theme is not the problem. If the error disappears, your theme’s script is timing out. Contact the developer or upgrade to a theme like Astra that avoids bloated scripts.
2. Ask Your Web Host to Increase max_execution_time
If your WordPress site has grown and scripts frequently time out, consider upgrading your hosting plan or asking your host to increase the execution time.
Large sites may run scripts that slow down over time. Discussing this with your host can help you find a suitable solution.
3. The PHP Time Limit in WordPress
In most cases, poorly designed plugins exceeding the PHP time limit cause max_execution_time errors in WordPress. Following the steps to disable and test plugins or increase the PHP time limit should resolve these issues.
If other factors are causing timeouts, you can now use these tools to check and troubleshoot them.
Resolving the ‘Fatal error: Maximum execution time of 30 seconds exceeded’ in WordPress is crucial for maintaining a stable and efficient website. This error, triggered when PHP scripts exceed the server’s time limit, can disrupt updates and functionality. Fortunately, addressing this issue is straightforward with the methods outlined in this guide.
For persistent issues, consulting your hosting provider ensures tailored solutions that align with your server environment. Also, you can secure your site using suitable DDOS protection. Hope you know now how to fix fatal errors. Maximum execution time exceeded. For more details on preventing plugin conflicts, refer to our guide on how to fix WordPress’s failed import media error.
We hope this guide is helpful!
Jessica Miller
Clear guide! Fixed my max execution error.