plainJS

Libraries / UI

lazySizes

High performance and SEO friendly lazy loader for images (responsive and normal), iframes and more, that detects any visibility changes triggered through user interaction, CSS or JavaScript without configuration.

No-build verifiedStable0 dependenciesScript tagTypes bundledMIT

Facts

Facts fetched 2026-10-30 by the directory sync (GitHub, npm, jsDelivr, deps.dev). Nothing here is typed by hand.
Size7.7 KB minified, 3.4 KB gzipped (lazysizes.js)
LicenceMIT
Dependenciesnone
Last releasev5.3.2, March 2021
Last activity2024-04-03 (Stable)
Stars17,712 on GitHub
Formatsclassic script (global lazySizes); TypeScript types in the package
CDN hits100.6 million a month on jsDelivr
npm downloads828,710 a month
GatesG1 passed (no runtime dependencies); G2 passed (loads in a browser as it is); G3 passed (no compile-only entry points); G4 passed (open-source licence); G5 passed (not archived or deprecated). Smoke test on v5.3.2 in headless Chromium, 2026-10-30

Load it

Pin the version. The hash is computed from the file jsDelivr serves, so a changed file fails to load instead of running.

htmlscript tag, with SRI
<script src="https://cdn.jsdelivr.net/npm/[email protected]/lazysizes.js"
        integrity="sha384-VGO3fNubjkDnHoL+VxwENWvJ+IdaoW+DTAw4BWca49uAh5e+5O6n2i4lsw/iSQw/" crossorigin="anonymous"></script>
Advertisement

Entry 96 in the directory. Facts refreshed monthly; last run 2026-10-30.