Categories
HTML

How to fix: Native Lazy loading of iframe or image not working

You can add loading="lazy" attribute to any image, iframe tag element in your HTML code to enable native lazy loading feature. But it sometimes, may not work. There is one simple but important factor listed below, that you need to keep in mind to make sure that it works perfectly.

You have to add proper width and height attributes to the img or iframe tags, to make sure that the lazy loading works without any layout shifts or any other noticeable issues.

By Murali Kumar

I am a Full Stack Web Developer with over 12 years of experience. I love WordPress & WooCommerce.

If you need help of a WordPress developer for your website, Get in touch now!.

Leave a Reply

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