Helps deferring offscreen background images and improves website speed by reducing HTTP requests .
Beoordelingen
5
Laatst bijgewerkt
March 31, 2024
Versie
1.0.7
Actieve installaties
400
LazyLoad Background Images

This plugin will delay the loading of background images in your website and thus helps boosting the website loading time by reducing total number of HTTP requests.

Quick Notes & Links

  1. Do not lazyload background images which are peresent above the fold because this will increase time to First Contentful Paint(FCP) metric and affect the speed of your website .
  2. Background images that are added using inline CSS e.g, <p style=" background-image: url( path/to/background-img.jpg )" > </p> are lazyloaded by this plugin by default .
  3. No dependencies required for this plugin to work.
  4. No extra HTTP request
  5. Add the selectors of the elements that have background images in the plugin settings page or add lazyload-bg class to the element .
  6. WordPress Tips and Tricks By Proloy Bhaduri
  7. Buy me a Coffee

Works smoothly with almost every page builders

Exclude certain inline background images from lazy loading using filter hook lazyload_inline_bg_excludes

add_filter(‘lazyload_inline_bg_excludes’,function($exclude_keywords){ $exclude_keywords = [ ‘bg-image.jpg’, ‘class-name’, ‘id’, ‘or any unique keyword that the element with background image has’ ]; },10,1);

Note: Add the above code to the functions.php file of your active theme/child theme or using a code snippets plugin.

Gratisop Creator abonnement
Door te installeren, ga je akkoord met de Servicevoorwaarden van WordPress.com en de voorwaarden voor plugins van derden.
Actieve installaties
400
Getest tot
6.5.5
Deze plugin kan worden gedownload, zodat je hem op je zelf-gehoste WordPress-installatie kan gebruiken.