WordPress Snippets

How to Disable Lazy Load in WordPress

By ThemesDNA1 min read

Share:

The lazy-loading images feature was introduced with WordPress 5.5. With this change, both servers and user agents will use a lot less bandwidth. Before, images further down the page would load right away, even if the user never scrolled to see them. But this might make some websites less user-friendly because images might not show up right away.

Do you also have issues with the lazy load feature in WordPress and need to disable it? You can insert the below code into your theme's functions.php file to prevent WordPress from adding the lazy-load attribute to all images and iframes.

// Disable Lazy Load Feature from WordPress
add_filter( 'wp_lazy_loading_enabled', '__return_false', 1000 );
Premium WordPress themes One-time payment   /   Lifetime updates

Ready to Build?

Get the ThemesDNA bundle.

Get all premium ThemesDNA themes with lifetime updates and unlimited website usage for a one-time payment.

  • 56 premium themes
  • Lifetime updates
  • Unlimited websites
  • No renewals

The complete premium theme bundle

$75

One payment. No renewals.

Get the ThemesDNA Bundle — $75