Some redirects and slow response in GT Metrix

Here is an analysis of one of my websites

[type or paste code here](https://gtmetrix.com/reports/cumsejoaca.ro/7YQan8SU/)

I use cloudflare DNS with CDN/Proxy included and all the requests are served by cloudflare. Unfortunately there are some redirects and some Waitings of over 1 second just to receive the website domain name.
Why is this reply/response from cloduflare so slow?

You can see from the waterfall in that test, that the largest wait is for the dynamic responses from the server. The initial redirect from apex to www is slow, you could do it within Cloudflare with a Page Rule (cumsejoaca.ro/* → Target URL https://www.cumsejoaca.ro/$1) or a Bulk Redirect/Dynamic Redirect.

The load of the actual document on www is slow as well, if your site is static and has no dynamic html, you could enable caching of html on it: Improving Time To First Byte (TTFB) With Cloudflare
Customize Caching · Cloudflare Cache (CDN) docs

Cloudflare’s not being slow, your origin is being slow. All of the cached responses for assets as shown in the waterfall are super quick. You can click on each item in the waterfall to expand it and see “cf-cache-status”, If it’s “HIT” it was served from Cloudflare’s cache. If it’s Dynamic, it’ll never be cached, there’s a list of other statuses here: Default Cache Behavior · Cloudflare Cache (CDN) docs

2 Likes

Thank you for great insights.
Somehow I succeed with Page Rule and I still don’t know where it came from, but now it’s working properly.
Regarding static website I already use a cache plugin.
Where exactly can I enable caching for HTML, you mean from my cache plugin or from cloudflare?

Nice, that page rule will help.

From Cloudflare yea, as long as your website html is static and you don’t have any login functionality for users or anything dynamic like that. You can exclude specific directories like wp-admin if needed:
Check out:

Cloudflare is going to be way faster at serving cached html, especially if you have a lot of users, and ones not close to your origin web server, as they have locations everywhere that can quickly serve your website from cache.

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.