Today:October 20, 2021

Defer parsing of Embedded Videos

When we use videos Like Youtube, Wistia, Vimeo, etc. Webpage speed will suffer a lot. Google has recently announced Google Search ranking is purely based on the PageSpeed.

Here is an easy way to defer your video that uses scripts.

Below is sample YouTube video Embed Link :

Change the above code a bit to apply a trick.

Now we need to use small Javascript code to load the video without any issue.

above javascript code will set the src=”” URL from copying the original video link from data-src=”” attribute.

That’s It. Now your page will load even faster. See how your site performs using GTMatrix



Leave a Reply

Your email address will not be published. Required fields are marked *

19 − thirteen =