YSlow: Put JavaScript at bottom

Recommendations

Lighthouse
Metrics
Audits
PageSpeed (Legacy)
YSlow (Legacy)

Overview

Move scripts to the bottom of pages to ensure other resources don't block.

How does your site score on this recommendation?

Details from Yahoo!

JavaScript scripts block parallel downloads; that is, when a script is downloading, the browser will not start any other downloads.

If you serve your images from multiple hostnames, you can get more than two downloads to occur in parallel. While a script is downloading, however, the browser won't start any other downloads, even on different hostnames.

Summary

JS
Medium
Moderate

YSlow recommends:

To help the page load faster, move scripts to the bottom of the page if they are deferrable.

An alternative suggestion is to use deferred scripts. The DEFER attribute indicates that the script does not contain document.write, and is a clue to browsers that they can continue rendering. Unfortunately, Firefox doesn't support the DEFER attribute. In Internet Explorer, the script may be deferred, but not as much as desired. If a script can be deferred, it can also be moved to the bottom of the page. That will make your web pages load faster.

Read More

Related PageSpeed Recommendations

Cookie Policy

By clicking "Allow All" you agree to the storing of cookies on your device to enhance site navigation, analyze site usage, and assist in our marketing efforts. View cookie details

Deny Allow All
×