First load takes a long time

Is there anything to do about the first discourse load taking a long time? (around 3s)
It seems that with SSO it’s even 6-7s.

I only found topics that mentioned EmberJS solving it but nothing has changed despite being on one of the latest versions.

1 Like

The initial load time on a Discourse site (with an empty cache) is typically 2–5 seconds, and with SSO, a 6–7 second load is not unusual because the SSO round-trip adds at least one extra HTTP request.

When SSO is used, the first load requires a redirect to the SSO provider and back. If the SSO provider is slow, the entire login process can be slower for first-time or logged-out users.

Load times can also be dependent on connection speed and device performance on the user side.

Ensuring that your Discourse server is adequately provisioned in terms of CPU, memory, and network speed can sometimes help improve performance, as low resource availability can lead to poor load times.

2 Likes

Thank you @SaraDev for your reply.

Is there any plan to improve this?

from my experience TTFB is pretty large so the user feedback from a UX perspective is pretty bad.

Similarly, I find that the caching time is possibly too short? If I leave a discourse site for a few hours and comeback it refreshes the entire SPA as if it’s a first load, so it’s another 5-6 seconds to wait.