October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk6 min

Puppeteer Infinite-Scroll Screenshots Have Blank Images? How to Fix Them

Puppeteer’s full-page option does not load an infinite feed for you. Scroll deliberately, verify content and image readiness, then capture.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

If a Puppeteer full-page screenshot shows blank or missing images, first make the page load the content: scroll through it in bounded steps, wait for the site’s items to appear, and check that the requested images actually loaded before capturing. fullPage: true captures the page’s rendered state; it does not make an infinite-scroll site fetch every item or guarantee that lazy images are ready.

Why infinite-scroll screenshots have blank images

Many pages defer images or other content until an element approaches the viewport. A full-page screenshot changes the capture area, but it does not necessarily perform the scrolling that triggers those behaviors. As a result, the screenshot can include blank areas, omit later items, or capture images before they render. The remedy depends on how the specific site loads content.

As an Amazon Associate I earn from qualifying purchases.

Puppeteer’s current documentation, version 25.12.0, describes full-page screenshots and page interactions; older GitHub reports document similar symptoms, but those reports from 2017–2018 are historical examples, not proof of a current Puppeteer-wide defect. See the Puppeteer screenshots guide, page interactions guide, and historical issues about lazy-loaded full-page screenshots and images rendering after capture.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use a bounded scroll-and-check workflow

  1. Navigate without assuming the page is complete. domcontentloaded is a useful starting point, but it does not mean all deferred content or images have loaded.
  2. Scroll in viewport-sized increments. This brings lazy-loaded elements into view and can trigger infinite-scroll requests. If possible, wait for the site’s actual new-item signal, such as a changed item count or a loading indicator disappearing.
  3. Stop on a real, bounded condition. Prefer an expected item count or a known end marker. If neither is available, use a maximum scroll count and require document height or item count to remain stable across several passes. A height that stops changing is only a fallback: some pages append content without changing height immediately.
  4. Check image readiness. For HTML images, wait for completion and inspect naturalWidth if successful loading matters. Handle failed images explicitly rather than treating completion as success.
  5. Capture only after the intended state is ready. Return to the top if the screenshot should begin there, then call page.screenshot({fullPage: true}).

Runnable Puppeteer example

This CommonJS example uses a bounded scroll loop and waits for HTML images at the end. Set url, MAX_SCROLLS, and REQUIRED_STABLE_PASSES for the target page. A site-specific item-count or end-marker check is more reliable than document height alone; add one when the site exposes a useful signal.

#1 Best Overall
Philips 24 Inch Computer Monitor FHD 100Hz VA VESA Flicker-Free, 241V8LB | 1920×1080 LED Monitor, 4ms GtG, Adaptive Sync, HDMI 1.4, Tilt Adjust, Low Blue Light, 4yr Advance Replacement Warranty
  • CRISP CLARITY: This 23.8″ Philips V line monitor delivers crisp Full HD 1920x1080 visuals. Enjoy movies, shows and videos with remarkable detail
  • INCREDIBLE CONTRAST: The VA panel produces brighter whites and deeper blacks. You get true-to-life images and more gradients with 16.7 million colors
  • THE PERFECT VIEW: The 178/178 degree extra wide viewing angle prevents the shifting of colors when viewed from an offset angle, so you always get consistent colors
  • WORK SEAMLESSLY: This sleek monitor is virtually bezel-free on three sides, so the screen looks even bigger for the viewer. This minimalistic design also allows for seamless multi-monitor setups that enhance your workflow and boost productivity
  • A BETTER READING EXPERIENCE: For busy office workers, EasyRead mode provides a more paper-like experience for when viewing lengthy documents
const puppeteer = require('puppeteer');

(async () => {
  const url = 'https://example.com';
  const MAX_SCROLLS = 40;
  const REQUIRED_STABLE_PASSES = 3;
  const browser = await puppeteer.launch({ headless: true });

  try {
    const page = await browser.newPage();
    await page.goto(url, { waitUntil: 'domcontentloaded', timeout: 30000 });

    let previousHeight = 0;
    let stablePasses = 0;

    for (let i = 0; i < MAX_SCROLLS && stablePasses < REQUIRED_STABLE_PASSES; i++) {
      await page.evaluate(() => window.scrollBy(0, window.innerHeight));

      // Network quiet is a signal, not proof that the page is visually ready.
      try {
        await page.waitForNetworkIdle({ idleTime: 500, timeout: 5000 });
      } catch (error) {
        if (error.name !== 'TimeoutError') throw error;
        // Continue to the explicit bounded checks below; record this timeout in production.
      }

      const height = await page.evaluate(() => document.documentElement.scrollHeight);
      if (height === previousHeight) stablePasses++;
      else stablePasses = 0;
      previousHeight = height;
    }

    const imageResults = await page.evaluate(async () => {
      const images = [...document.images];
      await Promise.all(images.map(img => {
        if (img.complete) return Promise.resolve();
        return new Promise(resolve => {
          img.addEventListener('load', resolve, { once: true });
          img.addEventListener('error', resolve, { once: true });
        });
      }));
      return images.map(img => ({
        src: img.currentSrc || img.src,
        loaded: img.complete && img.naturalWidth > 0
      }));
    });

    const failedImages = imageResults.filter(image => !image.loaded);
    if (failedImages.length) {
      console.warn('Images that did not load:', failedImages);
    }

    await page.evaluate(() => window.scrollTo(0, 0));
    await page.screenshot({ path: 'page.png', fullPage: true });
  } finally {
    await browser.close();
  }
})();

The example is a starting pattern, not a universal completion detector. In production, add an overall deadline and a site-specific completion check; the loop’s cap limits scrolling but does not replace a total runtime limit. Puppeteer’s page.evaluate() documentation explains that page evaluation can return a promise. Its page.waitForNetworkIdle() documentation describes a network-quiet wait, and the options documentation specifies a 500 ms default idle interval. Quiet network activity does not prove every image has rendered.

Adapt the readiness check to the page

HTML images, including failed loads

img.complete becomes true whether an image loaded successfully or failed. Use naturalWidth > 0 when success matters, and decide whether a failed asset should stop the capture, be logged, or be accepted as a known placeholder. The example logs failed images so they are visible instead of silently treating them as ready. This image-state check is a practical browser-side recommendation, not a guarantee made by Puppeteer.

Rank #2
Philips 22 Inch Computer Monitor FHD 100Hz VA VESA Flicker-Free, 221V8LB | 1920×1080 LED Monitor, 4ms GtG, Adaptive Sync, HDMI 1.4, Tilt Adjust, Low Blue Light, 4yr Advance Replacement Warranty
  • CRISP CLARITY: This 22 inch class (21.5″ viewable) Philips V line monitor delivers crisp Full HD 1920x1080 visuals. Enjoy movies, shows and videos with remarkable detail
  • 100HZ FAST REFRESH RATE: 100Hz brings your favorite movies and video games to life. Stream, binge, and play effortlessly
  • SMOOTH ACTION WITH ADAPTIVE-SYNC: Adaptive-Sync technology ensures fluid action sequences and rapid response time. Every frame will be rendered smoothly with crystal clarity and without stutter
  • INCREDIBLE CONTRAST: The VA panel produces brighter whites and deeper blacks. You get true-to-life images and more gradients with 16.7 million colors
  • THE PERFECT VIEW: The 178/178 degree extra wide viewing angle prevents the shifting of colors when viewed from an offset angle, so you always get consistent colors

CSS backgrounds and other visual content

The document.images check does not inspect CSS background-image resources. For those, wait for the relevant resource or an application-specific ready marker. Charts rendered to canvas, shadow-DOM content, images inside nested scroll containers, and API-driven “Load more” buttons also need their own trigger and completion signal. Scrolling the window will not necessarily scroll a nested container.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Choose the completion signal deliberately

Prefer, in order, a known target item count or end marker, a site-specific loading-state transition, and then a bounded stability fallback such as unchanged height over multiple passes. Arbitrary fixed sleeps are less deterministic: they may waste time on a fast page and still be too short on a slow one.

Rank #3
Dell 24 Monitor - SE2426H - 23.8-inch FHD (1920x1080) 144Hz 1ms Display, in-Plane Switching (IPS) Technology, AMD FreeSync™, TÜV 3-Star 2X HDMI, Tilt
  • Clear visuals. Fluid motion: A 144Hz refresh rate and 1ms MPRT deliver smooth, tear‑free motion across work, gaming, and streaming for clearer, more fluid viewing.
  • Eye comfort: TÜV Rheinland 3‑star* certification reduces harmful blue light while preserving stunning color quality without compromise. *TÜV Rheinland 3-star eye comfort certification.
  • Wide viewing angle: Get consistent views across a wide 178° /178° viewing angle.
  • In-Plane Switching (IPS): See excellent color accuracy and consistency across wide viewing angles with In-plane Switching (IPS) technology.
  • Ultra-thin bezels: Maximize your viewing experience with thin bezels.

Why network idle alone is not enough

waitUntil: 'networkidle2' and page.waitForNetworkIdle() describe network activity, not successful visual rendering. Some pages keep connections open and never reach the desired quiet period; others become quiet before images, fonts, charts, or application work are complete. Use network idle as one signal alongside the actual content condition and image checks. If the wait times out, record or handle that result rather than swallowing it and assuming the page is ready.

Troubleshoot the remaining blank areas

  • Later items never appear: the page may require more scrolling, an end-marker check, a click on “Load more,” or scrolling a nested container. Verify the item count as the loop runs.
  • Items appear, but HTML images are blank: inspect currentSrc, complete, and naturalWidth. A failed request is not fixed by taking another screenshot; investigate the asset request and page-specific conditions.
  • Only background images are missing: the HTML image check does not cover them. Wait for the relevant background resource or a site-specific ready signal.
  • The network-idle wait times out: persistent requests can prevent network quiet. Treat the timeout as an observable outcome, then use a bounded target-specific readiness check instead of extending the wait indefinitely.
  • The screenshot is still inconsistent: animations, fonts, canvas, cross-origin resources, and site behavior can affect capture. Check those separately and use a completion marker the page actually provides.
  • The script runs too long: reduce unnecessary scroll cycles by checking for the expected item count or end marker, while keeping a maximum scroll count and overall deadline.

Or skip the browser setup

ScreenshotNeo is a website screenshot API and MCP server. Its one-call API can capture a URL as an image or PDF:

Rank #4
Sale
Samsung 27" Essential S3 (S36GD) Series FHD 1800R Curved Computer Monitor | 100Hz, Game Mode, Advanced Eye Comfort, HDMI and D-sub Ports (LS27D366GANXZA)
  • CURVED FOR ENHANCED ENGAGEMENT: An immersive viewing experience with a curved monitor that wraps more closely around your field of vision; It creates a wider view, enhancing depth perception and minimizing peripheral distraction
  • SMOOTH PERFORMANCE FOR SEAMLESS CONTENT: Stay in the action when playing games, watching videos, or working on creative projects; The 100Hz refresh rate reduces lag and motion blur so you don't miss a thing in fast-paced moments¹
  • MORE GAMING POWER: Gain the edge with optimizable game settings; Color and image contrast can be adjusted to see scenes more vividly and spot enemies hiding in the dark; Game Mode adjusts any game to fill the screen so you can view every detail²
  • KEEP IT EASY ON THE EYES: Care for your eyes and stay comfortable, even during long sessions; Advanced eye comfort technology certified by TÜV reduces eye strain by minimizing blue light and reducing irritating screen flicker²
  • INCREASED VERSATILITY: Connect to more; Plug devices straight into your monitor for increased flexibility, making your computing environment even more convenient
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

See the ScreenshotNeo API documentation for parameters. Cookie and consent banners are accepted before capture and 60+ known consent platforms, newsletter popups, and chat widgets can be removed; each step can be turned off. Bot checks, blank pages, timeouts, failed loads, and cache hits are not billed, with the response indicating the page verdict and billing status. Its MCP server gives AI agents screenshot, page-info, and PDF-capture tools. The Free plan includes 1,000 shots a month with no card; paid plans start at $5 for 3,000 shots. Sign up for 1,000 free screenshots a month, with no card required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Frequently Asked Questions

Does fullPage: true scroll through an infinite feed?

No. It requests a full-page capture of the rendered page; it does not guarantee that the site’s scrolling behavior has appended all future items.

Why can an image be complete but still blank?

The browser’s complete property can also be true after a failed load. Check naturalWidth when you need to distinguish a successfully loaded image.

Best Value
Sale
Sceptre New 22-Inch Gaming Monitor, FHD 1080p, Up to 144Hz, HDMI, DisplayPort, Built-in Speakers, Machine Black (E225W-FW144 Series, 2026)
  • 【INTEGRATED SPEAKERS】Whether you're at work or in the midst of an intense gaming session, our built-in speakers provide rich and seamless audio, all while keeping your desk clutter-free.
  • 【EASY ON THE EYES】 Protect your eyes and enhance your comfort with Blue-Light Shift technology. This feature reduces harmful blue light emissions from your screen, helping to alleviate eye strain during long hours of use and promoting healthier viewing habits.
  • 【WIDEN YOUR PERSPECTIVE】Our sleek minimal bezel design ensures undivided attention. The nearly bezel-free display seamlessly connects in a dual monitor arrangement, delivering an unobstructed view that lets you focus on more at once, completely distraction-free.

Will this exact loop work on every site?

No. Sites that use nested scrollers, CSS backgrounds, canvas, shadow DOM, or a load-more control need a trigger and readiness check suited to that implementation.

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.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Outdated Drivers Are Slowing You DownFree scan - exact matches

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.