Optimize your WordPress page loading times with a simple tweak

I have recently enchanced my WordPress optimization guide with seven new tips and one of them includes moving your JavaScripts to footer of the page when possible. Why is this important?

When the browser loads the page, it loads the files as they appear meaning, your html, then css, images etc. If the javascript code is in the header, they will load before any of the other files listed below them. Since most JavaScript code is ready to execute only when the page is fully loaded, it makes sense to move all JavaScript code to the footer.

The page will load in similar amount of time, but the user will have the impressions of the page loading faster as all relevant visual elements are loaded first.

This practice is also confirmed by Yahoo Extreme Web Performance team.

So what I did is I created a plugin that will move all the properly configured JavaScript code to the footer.

Here is the link to the plugin page: Footer JavaScript WordPress plugin.


About this entry