How to Increase PHP Time Limit for a WordPress Site?

What Is The PHP Time Limit?

The PHP Time Limit is the amount of time that your site will spend on a single operation before timing out. When an operation reaches the time limit set, then it will return a fatal error that looks like this:

Fatal error: Maximum execution time of xx seconds exceeded...

The default value for PHP time limit on most hosts for the PHP Time Limit is 30 seconds. You can increase this limit by following any of the methods mentioned below.

1. Increasing PHP Time Limit via PHP.ini file

max_execution_time = 300;

2. Alternative to editing PHP.ini through wp-config.php

set_time_limit(300);

3. Modifying the .htaccess file

max_execution 300

P.S: 300 in the above code samples mean 300 seconds. Feel free to change this to any appropriate number.

If you face any trouble just check this for solution

1 reply on “How to Increase PHP Time Limit for a WordPress Site?”

Leave a Reply

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