PHPackages                             automattic/jetpack-lazy-images - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. automattic/jetpack-lazy-images

AbandonedArchivedJetpack-library[Utility &amp; Helpers](/categories/utility)

automattic/jetpack-lazy-images
==============================

Speed up your site and create a smoother viewing experience by loading images as visitors scroll down the screen, instead of all at once. Modern browsers now support lazy loading, and WordPress itself bundles lazy loading features for images and videos. This feature will consequently be deprecated in November 2023.

v3.0.1(2y ago)529.3k3GPL-2.0-or-laterPHPPHP &gt;=7.0

Since Aug 25Pushed 1y ago1 watchersCompare

[ Source](https://github.com/Automattic/jetpack-lazy-images)[ Packagist](https://packagist.org/packages/automattic/jetpack-lazy-images)[ RSS](/packages/automattic-jetpack-lazy-images/feed)WikiDiscussions trunk Synced 1w ago

READMEChangelog (1)Dependencies (6)Versions (98)Used By (0)

Jetpack Lazy Images
===================

[](#jetpack-lazy-images)

Speed up your site and create a smoother viewing experience by loading images as visitors scroll down the screen, instead of all at once.

Caution

This package is abandoned. WordPress Core now uses browsers' native lazy loading, and the code in here conflicts with the Interactivity API added in Gutenberg 16.6.

Usage
-----

[](#usage)

```
/*
 * Initialize lazy images on the wp action so that conditional
 * tags are safe to use.
 *
 * As an example, this is important if a theme wants to disable lazy images except
 * on single posts, pages, or attachments by short-circuiting lazy images when
 * is_singular() returns false.
 *
 * See: https://github.com/Automattic/jetpack/issues/8888
 */

add_action( 'wp', array( 'Automattic\\Jetpack\\Jetpack_Lazy_Images', 'instance' ) );
```

Development
-----------

[](#development)

Running tests requires working `svn`, `composer` and `pnpm` commands.

Once these are installed, you install the composer dependencies by running:

```
$ composer install --ignore-platform-reqs
```

### Generate minified JavaScript

[](#generate-minified-javascript)

The JavaScript file can be minified from the root of the Jetpack repository:

```
$ cd ../../
$ pnpm build-packages
```

### Run PHP unit tests

[](#run-php-unit-tests)

On a local development environment run:

```
$ composer phpunit
```

### Lint PHP source code

[](#lint-php-source-code)

The PHP code can be linted from the root of the Jetpack repository:

```
$ cd ../../
$ composer phpcs:compatibility packages/lazy-images
$ composer phpcs:lint packages/lazy-images
```

Using this package in your WordPress plugin
-------------------------------------------

[](#using-this-package-in-your-wordpress-plugin)

If you plan on using this package in your WordPress plugin, we would recommend that you use [Jetpack Autoloader](https://packagist.org/packages/automattic/jetpack-autoloader) as your autoloader. This will allow for maximum interoperability with other plugins that use this package as well.

Security
--------

[](#security)

Need to report a security vulnerability? Go to  or directly to our security bug bounty site .

License
-------

[](#license)

jetpack-lazy-images is licensed under [GNU General Public License v2 (or later)](./LICENSE.txt)

###  Health Score

40

—

FairBetter than 86% of packages

Maintenance29

Infrequent updates — may be unmaintained

Popularity29

Limited adoption so far

Community25

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~18 days

Recently: every ~75 days

Total

80

Last Release

747d ago

Major Versions

v1.5.1 → v2.0.02021-08-31

v2.3.2 → v3.0.02024-02-07

### Community

Maintainers

![](https://www.gravatar.com/avatar/7c5869ecbb8e0eac7e8b8e0f3cf7bdd8d5fcdc4abc10a72281872c53f8639d44?d=identicon)[automattic](/maintainers/automattic)

![](https://www.gravatar.com/avatar/11609890f6e7a840715f4cfc9622d77ea64b7dfc024df5643fbf8471a18c00f3?d=identicon)[kraft](/maintainers/kraft)

![](https://www.gravatar.com/avatar/5326730499ec14e274f51b9bcc39db6aac0fb38b33849715aae0e2587a2b93df?d=identicon)[jeherve](/maintainers/jeherve)

![](https://www.gravatar.com/avatar/6e220e167e341c28b1aa10bf0bb0374999068329f8683d3187ee3cf6749b8837?d=identicon)[dereksmart](/maintainers/dereksmart)

---

Top Contributors

[![anomiex](https://avatars.githubusercontent.com/u/1030580?v=4)](https://github.com/anomiex "anomiex (171 commits)")[![jeherve](https://avatars.githubusercontent.com/u/426388?v=4)](https://github.com/jeherve "jeherve (55 commits)")[![kraftbj](https://avatars.githubusercontent.com/u/88897?v=4)](https://github.com/kraftbj "kraftbj (30 commits)")[![samiff](https://avatars.githubusercontent.com/u/15803018?v=4)](https://github.com/samiff "samiff (27 commits)")[![zinigor](https://avatars.githubusercontent.com/u/374293?v=4)](https://github.com/zinigor "zinigor (22 commits)")[![sdixon194](https://avatars.githubusercontent.com/u/33553323?v=4)](https://github.com/sdixon194 "sdixon194 (13 commits)")[![coder-karen](https://avatars.githubusercontent.com/u/16754605?v=4)](https://github.com/coder-karen "coder-karen (12 commits)")[![bindlegirl](https://avatars.githubusercontent.com/u/1242807?v=4)](https://github.com/bindlegirl "bindlegirl (9 commits)")[![ice9js](https://avatars.githubusercontent.com/u/8056203?v=4)](https://github.com/ice9js "ice9js (5 commits)")[![sergeymitr](https://avatars.githubusercontent.com/u/1341249?v=4)](https://github.com/sergeymitr "sergeymitr (4 commits)")[![nateweller](https://avatars.githubusercontent.com/u/10933065?v=4)](https://github.com/nateweller "nateweller (4 commits)")[![gogdzl](https://avatars.githubusercontent.com/u/37049295?v=4)](https://github.com/gogdzl "gogdzl (3 commits)")[![gmjuhasz](https://avatars.githubusercontent.com/u/36671565?v=4)](https://github.com/gmjuhasz "gmjuhasz (3 commits)")[![zaerl](https://avatars.githubusercontent.com/u/167611?v=4)](https://github.com/zaerl "zaerl (3 commits)")[![haqadn](https://avatars.githubusercontent.com/u/3737780?v=4)](https://github.com/haqadn "haqadn (3 commits)")[![tbradsha](https://avatars.githubusercontent.com/u/32492176?v=4)](https://github.com/tbradsha "tbradsha (3 commits)")[![brbrr](https://avatars.githubusercontent.com/u/5654161?v=4)](https://github.com/brbrr "brbrr (2 commits)")[![gravityrail](https://avatars.githubusercontent.com/u/51896?v=4)](https://github.com/gravityrail "gravityrail (2 commits)")[![nunyvega](https://avatars.githubusercontent.com/u/16329583?v=4)](https://github.com/nunyvega "nunyvega (2 commits)")[![ouikhuan](https://avatars.githubusercontent.com/u/4074459?v=4)](https://github.com/ouikhuan "ouikhuan (2 commits)")

---

Tags

jetpack

### Embed Badge

![Health badge](/badges/automattic-jetpack-lazy-images/health.svg)

```
[![Health](https://phpackages.com/badges/automattic-jetpack-lazy-images/health.svg)](https://phpackages.com/packages/automattic-jetpack-lazy-images)
```

###  Alternatives

[automattic/jetpack

Jetpack supercharges your self‑hosted WordPress site with the awesome cloud power of WordPress.com

3623.2k](/packages/automattic-jetpack)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
