apachewebserverpagespeedgoogle-pagespeedmod-pagespeed

What are the round-trips google mentions in the pagespeed insights tool?


Google says it had to make 5 network round trips and that only 18% of the content above the fold could be viewed after the first 3 round trips.

How can I improve this?

Thank you.


Solution

  • In Pagespeed’s docs this term is used multiple times in different contexts that is indeed a bit confusing

    Network roundtrips

    From wikipedia:

    In telecommunications, the round-trip delay time (RTD) or round-trip time (RTT) is the length of time it takes for a signal to be sent plus the length of time it takes for an acknowledgement of that signal to be received.

    So it’s more about the TCP protocol. From the docs:

    If the amount of data required exceeds the initial congestion window (typically 14.6kB compressed), it will require additional round trips between your server and the user’s browser. For users on networks with high latencies such as mobile networks this can cause significant delays to page loading

    2 recipes from the same page:

    To make pages load faster, limit the size of the data (HTML markup, images, CSS, JavaScript) that is needed to render the above-the-fold content of your page

    and

    Structure your HTML to load the critical, above-the-fold content first

    Above-the-fold content is the screen that can be seen without scrolling

    More details on mobile analysis and 3 round trips

    Due to this TCP behavior, it is important to optimize your content to minimize the number of roundtrips required to deliver the necessary data to perform the first render of the page. Ideally, the ATF content should fit under 98KB - this allows the browser to paint the page after just three roundtrips to have plenty time budget for server response latency and client rendering.

    Blocking roundtrips

    From another docs page:

    This section describes the round trips required to load the page’s render-blocking resources, the total bytes used by the page, and how it compares to the median number of round trips and bytes used in the dataset. It can indicate if the page might be faster by modifying the appearance and functionality of the page.

    It’s not clear whether it means networking round trips that are calculated as above or simply additional calls required to load the blocking resources.

    In any case you can fix it by eliminating render-blocking resources like synchronous javascript calls (more here)