My webpage loads far too slowly

My webpage loads far too slowly. Not all the time. Sometimes it occurs, and eventually it stops on its own. Please assist me in solving it.

Hi @mehedimax62

Since Cloudflare acts as a reverse proxy, we might affect the TTFB for a site. There are a few HTTP requests that add up to the total TTFB:

  1. Cloudflare successfully negotiating a connection with your origin.
  2. Cloudflare sending a request on the connection.
  3. The origin generating a response.
  4. Cloudflare receiving the response.

Essentially, you may see a larger TTFB because we don’t send data back until after we have connected to your web server and it has responded.
The difference is usually no more than a few milliseconds, but more details on Cloudflare and TTFB can be found here:
Are you measuring what matters? A fresh look at Time To First Byte

You can use Cloudflare Observatory to run tests and check the real user monitoring (RUM) data.
This page can help you understand the results of the tests.

If you’re seeing the TTFB is unusually high on dynamic resources (CF-Cache-Status is not HIT, see Cloudflare cache responses):

  1. Follow the customize the cache guide to make sure that any resource that can be cached appropriately is cached. You can review the Cache Analytics on the Cloudflare Dashboard to check for cache performance and potential improvements.
  2. Make sure your origin web server is performing well: you might need to check with your website administrator or hosting provider.

If you’re seeing a high TTFB on cached resources (CF-Cache-Status is HIT) or on resources hosted on Cloudflare (through Workers or Pages for example), please share the following information with us so we can further investigate:

  • The output from running the following command:
curl -svo /dev/null -w "Connect: %{time_connect} \n TTFB: %{time_starttransfer} \n Total time: %{time_total} \n" https://<HOSTNAME>
  • The output of the following webpage in a browser: http:///cdn-cgi/trace

  • An MTR or traceroute to <HOSTNAME> from an affected device

  • Any information from any other tools showing the high TTFB value: please provide details on how did you measure or where did you get the information

Please let us know if you have any further questions or issues by replying to this e-mail or ticket.

1 Like