Support » Installing WordPress » The REST API encountered an error

  • Hi Guys

    Same problem as other people, my sites are now painfully slow on the backend after the 6.4 upgrade, getting the error below on a Plesk Server.

    When testing the REST API, an error was encountered:REST API Endpoint:
    REST API Response: (http_request_failed) cURL error 28: Operation timed out after 10001 milliseconds with 452 out of 2274 bytes received

    Any guidance would be a massive help at this point.



Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter tinpeas


    Thanks for this, does anyone know if a fix is being pushed. Not really looking forward to rolling back 90 websites.

    Hy william here. It looks like you’re encountering a cURL error 28, which is a timeout issue. This could be due to various reasons, and here’s a step-by-step approach to resolve it:

    1. You can try increasing the cURL timeout value in your WordPress installation. This can be done by adding the following code to your theme’s functions.php file or in a custom plugin:

      add_filter(‘http_request_timeout’, function($timeout) { return 30; // Increase the timeout value to 30 seconds or adjust as needed });
    2. Verify that your server has sufficient resources (CPU, memory) to handle the increased load. If your server is running out of resources, it can cause timeouts.
    3. Deactivate your plugins one by one and check if the issue persists. Sometimes, a poorly coded or incompatible plugin can cause timeouts.
    4. Switch to a default WordPress theme (like Twenty Twenty-One) to see if the problem persists. If the issue is theme-related, you might need to contact the theme developer for support.
    5. Ensure that Plesk is properly configured and that there are no restrictions on outgoing connections or timeouts that could be affecting cURL requests.
    6. If none of the above steps resolve the issue, contact your hosting provider’s support. They can check server logs and provide insights into any server-side issues.

      Remember to back up your site before making any changes. If the problem persists, reaching out to your hosting support is crucial, as they can provide specific insights into server-related issues. Let me know how it goes.
      I did same with another client website and issue was resolved here is his website link:
    Thread Starter tinpeas


    Thanks William, however the good news is the 6.4.1 update fixed the issue in all cases.

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.