Skip to main content

What is lazy loading?

lazy loading

Written by Julia

Lazy loading refers to a web design technique that improves the performance and loading speed of an online store. In simple terms, it means that instead of loading all the images, videos, and other media on a webpage at once, the webpage loads only the content that is currently visible to the user on their screen.

Here's how it works:

  1. When a customer visits your store, the webpage initially loads the text and basic structure of the page.

  2. As the user scrolls down the page, additional content, such as images and videos, is loaded on-demand. This means that only the items within the user's immediate view are loaded, and the rest are loaded as the user scrolls further down.

The benefits of lazy loading include faster page loading times, reduced bandwidth usage, and a smoother user experience. It prevents the entire webpage from slowing down due to the simultaneous loading of all media elements, especially on pages with a lot of images or videos. This can help improve the overall performance of your online store and keep customers engaged.

How TinySEO adds lazy loading

TinySEO adds the native loading="lazy" attribute to <img> tags in your theme's Liquid files. It doesn't lazy load videos or other media.

TinySEO skips an image when:

  • it already has a loading attribute

  • its class, or its parent element's class, contains logo, banner, slideshow or tiny-no-lazy

To keep an image from lazy loading, add the tiny-no-lazy class to the image or its parent element.

Did this answer your question?