Make WordPress Core

Opened 8 months ago

Closed 8 months ago

#56273 closed feature request (wontfix)

Disable lazy load

Reported by: pierreto's profile Pierreto Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Media Keywords:
Focuses: performance Cc:



Like many here, I would like to deactivate the lazy load and I am sad that new functions are imposed on us that lower the page speed score and that we have to waste time each time to find a solution to deactivate it.
Maybe there is a real intention to harm those who are not programmers.

Finally, like the others, I used the solution that doesn't work anymore.

As far as I understand, we have to add this code in function.php of the template to disable again this damn lazy load.

function skip_lazyloading_on_first_three_archive_images( $omit_threshold ) {
    if ( is_home() || is_archive() ) {
        return 3;
    return $omit_threshold;
add_filter( 'wp_omit_loading_attr_threshold', 'skip_lazyloading_on_first_three_archive_images' );

Why not create a checkbox to enable or disable the lazy load in the wordpress settings?

Or maybe someone will have to create a plugin to disable one of the new useless or complicated function like "classic editor", classic widger", classic no lazy load ?

Change History (7)

#1 @johnbillion
8 months ago

  • Component changed from General to Media
  • Keywords reporter-feedback added

Thanks for the report @Pierreto. Rather than making silly claims that the contributors to WordPress are intending to harm users, why don't you explain what exactly the problem is that you're seeing and hopefully someone here can help you out. We're all trying to make WordPress better so your website is faster. Disabling lazy loading will not make your website faster, but adjusting the threshold at which it operates may well do. So please, let us know what the problem is and we'll see if we can fix it.

#2 follow-up: @Pierreto
8 months ago

This is not a silly remark, there are new features that have a negative impact on webmasters.

As for the widgets, impossible to control them before finding the "Classic widget" plugin.

Forcing to add plugins, when you want to have the minimum, is not an evolution.

It's as if a gap was forming between the webmaster and those who work on the program

With the lazy load and an average connection, you have to wait before the image appears, in general, the reader will see only an empty space.

The question is simple, how to disable lazy load!

I tried to answer the post on the new lazy load where several people ask, like me, how to disable this option that penalizes people who do not have an ultra fast connection.

And google page speed:
"The Largest Contentful Paint image had a delayed load
Images above the waterline that have a delayed load are rendered later in the page lifecycle, which can delay Largest Contentful Paint.

#3 in reply to: ↑ 2 @audrasjb
8 months ago

Hello and welcome to WordPress Core Trac!

Thank you for opening this ticket and sorry to hear that you have issues with your WordPress installation.

It is very unlikely that this kind of option will be added in the interface, because if we do that, so all the features should also have an enabling/disabling option. This would be against the WordPress philosophy:

But when that kind of feature is released, the WordPress Core team always provide a technical way to disable it. Lazyload can be disabled entirely with 3 lines of PHP. And plugin authors are welcome to create plugins to handle that. It is really easy to find a plugin for disabling lazyload in the plugin repository. These plugins generally doesn't load more than a few lines of PHP, so this is not a problem to use it to disable a feature you don't want.

Replying to Pierreto:

And google page speed:
"The Largest Contentful Paint image had a delayed load
Images above the waterline that have a delayed load are rendered later in the page lifecycle, which can delay Largest Contentful Paint.

This issue has been addressed in ticket #53675 (WordPress 5.9): "Omit lazy-loading attribute on first content image/iframe".

A devnote has even been published to explain how it works:

The issue is probably that your theme doesn't handle it properly. Do you reproduce the issue with a bundled theme?

#4 @audrasjb
8 months ago

  • Version 6.0 deleted

#5 @audrasjb
8 months ago

  • Focuses performance added

#6 @Pierreto
8 months ago

Thank you for your explanation.

I finally installed a new plugin, "Disable Lazy Load", with Classic Editor and Classic Widgets.

How many plugins should I install to cope with future changes in WordPress?

The future will tell us!

I must be a too classic webmaster

#7 @audrasjb
8 months ago

  • Keywords reporter-feedback removed
  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from new to closed

Since I don't see any issues that weren't covered in this ticket, I am closing it as wontfix , because for now, we don't have any reason to remove this feature from Core (see the above comments), and because there is an effective way for users to disable this, with or without code.

Feel free to reopen the ticket if there is anything else to address.

Thank you

Note: See TracTickets for help on using tickets.