Main Menu

How to Fix the WordPress connection timeout

One of the common WordPress error is the ‘connection timed out’ which is caused by an overburdened shared server. The main causes are heavy plugins, theme function issues, and exhausted PHP memory limit.

How to Fix It?

This error can be fixed very easily in different ways:

First possibility is to increase the memory limit of PHP  in wp-config.php. If you are using shared hosting you may have to ask your hosting provider to increase your memory limit. This allows you to run heavy plugins successfully.

The second way is to increase the maximum execution time in your php.ini file. However this is not a WordPress core file, so if you are not sure how to edit it, contact your hosting provider to increase your maximum execution time.

PHP Parameter

Default Value

Recommended Value

Description

memory_limit

128M

256M or higher

Max memory PHP can use

max_execution_time

30 seconds

60 seconds or more

Max time script can run

max_input_time

60 seconds

120 seconds

Max time to parse input data

Another way is to first deactivate all the plugins and reactivate them one-by-one to see which plugin is causing the problem and then carefully remove the one that is causing the trouble.

The last method that you can adapt to resolve the problem is to switch to a default WordPress theme to identify if there is any problem caused by the theme.

Solution

Pros

Cons

When to Use

Disable Problematic Plugins

Easy and quick

May disable needed functionality

If plugin conflict is suspected

Increase PHP Memory

Improves performance

Needs hosting permission

When memory limit is low

Check DNS Settings

Fixes domain resolution issues

Requires DNS knowledge

If DNS errors detected

Upgrade Hosting Plan

More resources and stability

Additional cost

If hosting limits reached

Category: Web Hosting Tutorials

Write Comment