
Most webpages typically have several CSS and JS files. We list the most common ones below:ġ) The Combined File May Potentially be Very Large in File Size Why is Combining CSS/JS Files Potentially Bad?Ĭombining CSS/JS files may reduce the round trip time required for such requests, but there are other potential drawbacks associated with file combination. This results in faster downloads of requests for websites on HTTP/1.1, but requires more server resources as too many requests can overload your server. With HTTP/1.1, the browser can re-use the same TCP connection via Keep Alives to send multiple requests sequentially however, browsers often open multiple TCP connections in order to send more requests to your server (to retrieve more page assets). WordPress (or any other CMS) can also make this worse, as most plugins will add additional CSS/JS files.īrowsers have a maximum limit for how many concurrent requests can be sent at the same time (e.g., 6 for Google Chrome) so as not to overburden your server.

While modern browsers are quite smart in how they handle them, they still pose an issue, particularly if you have multiple CSS/JS files as there are more opportunities for render-blocking to occur. When the browser needs to fetch your page assets from your origin server, a TCP connection is opened to facilitate network transfer of requests and resources.Įxternal CSS/JS files are considered render-blocking by nature – they block page rendering or block other resource downloads. To understand why CSS/JS combination makes sense for HTTP/1.1 pages, let’s talk about how the protocol works. Why Does CSS/JS Combination Make Sense for HTTP/1.1 Pages?


This is a beneficial recommendation for websites on HTTP/1.1 (especially back in the day when it was prominent) as the protocol had a limited number of connections. Many plugins offer the option to combine your CSS/JS files.
