Do these 3 things before closing this tab:
1Repair Windows errors before they cause bigger problems2Scan for outdated or missing drivers - takes under a minute3Clear out junk files and repair common Windows errorsPut loading="lazy" on each thumbnail’s <img> when it starts outside the initial viewport. Keep images likely to appear immediately—including a hero or likely Largest Contentful Paint (LCP) image—eager, and reserve space with image dimensions so the directory does not jump as thumbnails load.
Use native lazy loading for offscreen thumbnails
For a directory rendered as ordinary HTML, add the attribute directly to the thumbnail image:
As an Amazon Associate I earn from qualifying purchases.
<a href="/listing/example">
<img
src="/images/example-thumbnail.jpg"
alt="Example site preview"
width="320"
height="200"
loading="lazy"
>
</a>
The browser defers fetching an image marked lazy until it considers the image close enough to the viewport. The value is a browser hint, not a way to set an exact pixel threshold. Browser behavior and loading distance can vary. MDN explains lazy loading; its loading property reference documents the lazy and eager values and a dynamically created image-list example.
The Tool Desk
Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Keep visible and important images eager
Do not mark every image lazy indiscriminately. Images visible as the page first renders should generally load eagerly, especially a hero image or another likely LCP candidate. If shared code applies lazy loading to all images, explicitly leave initially visible thumbnails eager. The number of rows above the fold changes with viewport size, so check realistic mobile and desktop layouts rather than assuming a fixed row count. web.dev’s guidance on lazy loading covers the initial viewport and LCP considerations.
#1 Best Overall
- HTML CSS Design and Build Web Sites
- Comes with secure packaging
- It can be a gift option
Reserve the thumbnail’s space
Give each image a width and height, or otherwise reserve space using its aspect ratio. The browser can then lay out the directory before the image data arrives, reducing layout shifts. Without reserved space, a lazy image may have zero dimensions, which can also interfere with deciding when it approaches the viewport. See MDN’s <img> reference.
Apply the attribute in responsive and dynamically rendered directories
Responsive images with <picture>
When a <picture> element supplies responsive sources, put loading="lazy" on its child <img>, not on <picture>:
Rank #2
<picture>
<source media="(min-width: 800px)" srcset="/images/example-large.webp">
<img src="/images/example-small.webp" alt="Example site preview" width="320" height="200" loading="lazy">
</picture>
The selected source can change with the viewport, but the loading attribute belongs on the image element. See web.dev’s responsive images guide.
Windows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallCrashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minuteImages added by JavaScript
Set the property on each created image before adding it to the document. For example:
Rank #3
const img = document.createElement("img");
img.src = "/images/example-thumbnail.jpg";
img.alt = "Example site preview";
img.width = 320;
img.height = 200;
img.loading = "lazy";
const link = document.createElement("a");
link.href = "/listing/example";
link.append(img);
document.querySelector(".directory").append(link);
For images that should load immediately, use img.loading = "eager" or omit the lazy setting. MDN describes the loading property as widely available across browsers since March 2022; check your actual supported browser set if older browsers are in scope.
Choose native loading or custom visibility logic
For ordinary offscreen thumbnails, native loading="lazy" is the simple default and usually avoids needing a JavaScript library. Choose Intersection Observer when the interface needs custom behavior tied to an element entering or leaving an intersection—for example, a bespoke loading state or work beyond the browser’s built-in image deferral. Older scroll, resize, or orientation-change approaches require extra event-handling code; use them only when native loading and Intersection Observer do not meet the requirement.
Rank #4
Troubleshoot thumbnail loading
- Images appear late even though they are visible: Check whether initially visible images were marked lazy. Make those images eager, and verify the layout at mobile and desktop viewport sizes.
- Rows jump when thumbnails appear: Provide valid intrinsic
widthandheightvalues or reserve the correct aspect-ratio space in CSS. - An image inside
<picture>does not defer: Confirmloading="lazy"is on the child<img>, not the<picture>. - Code reports completion before all thumbnails are ready: Do not treat the window
loadevent as proof that every lazy image has loaded. For a specific image, inspect its Booleancompleteproperty; it indicates whether the image has finished loading or is ready to use. - Images load sooner or later than expected: That distance is controlled by the browser and may vary. The attribute does not provide a precise scheduling threshold; use Intersection Observer if custom intersection-driven behavior is necessary.
Or skip the browser setup
If your directory workflow needs screenshots of the pages rather than manually managed thumbnail assets, ScreenshotNeo provides a website screenshot API and MCP server. One GET request can return a PNG, JPEG, WebP, or PDF. Its capture can accept cookie and consent banners and remove 60+ known consent platforms, newsletter popups, and chat widgets before taking the shot; each step can be turned off.
Example cURL request, using the documented API at ScreenshotNeo’s documentation:
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
Bot checks or CAPTCHAs, blank pages, timeouts, failed loads, and cache hits cost nothing; each response says which outcome occurred in the X-Page-Verdict and X-Billed headers. Its MCP server offers take_screenshot, get_page_info, and capture_pdf for Claude, Cursor, and other MCP clients. The Free plan includes 1,000 shots per month with no card; paid plans start at $5 for 3,000 shots.
Sign up for ScreenshotNeo’s free plan to get 1,000 screenshots a month without a card.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.
Free tools Windows power users keep installed
One-click scans. No signup required.




