This article will show you a simple tool to instantly speed up your site just by adding one line of code to it.
In today’s world, optimisation of the web site is a difference between high converting place and no converting place. Amazon researched that just by removing 100ms of your site load time, adds 1% of conversions.
In Amazon’s World, 1% is a huge amount of money, but on smaller websites it can also make a difference!
How does it work? It preloads a page right before a user clicks on it. Yes, you read it right, it achieves a speed up of your site by anticipating what a user browsing your site will click.
Before a user clicks on a link, he/she hovers the mouse over that link. When a user has hovered for 65 ms, instant.page starts preloading at this moment, leaving on average over 300 ms for the page to preload.
Another option is to preload when the user starts pressing the mouse on a link, right before releasing it. This makes for virtually zero unused requests while still improving page loads by 80 ms on average.
And this is working on mobile devices too. A user starts touching the link before releasing it, leaving on average 90 ms for the page to preload.
Pages are preloaded only when there’s a good chance that a user will visit them, and only the HTML is preloaded, being respectful of your users’ and servers’ bandwidth and CPU.
It uses passive event listeners and requestIdleCallback so that your pages stay smooth. It respects data saver mode. It’s 1 kB in size and loads after everything else. And it’s free and open source (MIT license).
Even we are using it here on Codeforest!
How to speed up your site now?
As simple as copy and paste, just copy and paste below snippet of code to you footer section of the site, just before the closing </body> tag:
<script src="//instant.page/3.0.0" type="module" defer integrity="sha384-OeDn4XE77tdHo8pGtE1apMPmAipjoxUQ++eeJa6EtJCfHlvijigWiJpD7VDPWXV1"></script>
There are plenty of resources available on how to speed up your site around the web, you should follow them too, but this is really a quick win for everybody: your users will enjoy browsing your site and you will enjoy the conversion boost …