Driver FixRecommendedSound, Wi-Fi or graphics acting up? Check drivers firstFind missing or outdated drivers fast.Check DriversHalloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan Now×
Skip to content
World desk7 min

How to Capture Full-Page Screenshots for a Batch of URLs

Loop through URLs, capture each page with `fullPage: true`, and save to unique paths. Runnable Playwright and Puppeteer examples include failure reporting and a URL-to-file manifest.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To capture full-page screenshots for a batch of URLs, iterate through the URL list, open each page in Playwright or Puppeteer, and call its screenshot method with fullPage: true. Save each image to a unique path and record which URL produced it. Neither library’s cited documentation describes a built-in batch command: the loop, filenames, and per-URL error handling are your application’s job.

What a full-page screenshot captures

A full-page screenshot extends beyond the visible viewport to capture the page’s scrollable extent. In Playwright, the option belongs on page.screenshot(): await page.screenshot({ path: 'screenshot.png', fullPage: true }). Puppeteer provides the corresponding fullPage screenshot option; pass path to save the image. PNG is Puppeteer’s default image format. See the Playwright screenshot guide and Puppeteer ScreenshotOptions.

As an Amazon Associate I earn from qualifying purchases.

For batches, your code supplies the iteration: navigate to a URL, capture that page, and write the result to a distinct file. Playwright documents creating multiple page instances, but the cited documentation does not provide a single batch-capture command. See the Playwright Page API.

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

Capture a URL batch with Playwright

Install Playwright and its Chromium browser in your project before running this example. It processes URLs sequentially, creates the output directory, gives each file an index and sanitized hostname, and writes a JSON manifest linking source URLs to output paths. A failed URL is recorded and does not stop later captures.

#1 Best Overall
Sale
Epson Workforce ES-50 Compact & Lightweight Mobile Document Scanner | For Computers including PC and Mac Receipt and Document Scanner USB Powered
  • PORTABLE SCANNER FOR USE ON-THE-GO — The fastest and lightest mobile single-sheet-fed compact document scanner in its class¹
  • QUICK DOCUMENT SCANNING ― This Epson ultra-fast scanner scans a single page as quickly as 5.5 seconds²; Windows and Mac compatible
  • VERSATILE PAPER HANDLING ― Portable scanner scans documents up to 8.5 x 72 in; Also easily digitizes receipts and ID cards to make accounting, bookkeeping, and organizing simpler
  • INTUITIVE, HIGH-SPEED SOFTWARE — Epson ScanSmart Software³ is a smart tool allowing you to easily scan, review, and save; Stay organized easily with the help of this Epson scanner
  • EASY SETUP — USB-powered connect to your computer for quick and simple scanning; No batteries or external power supply required to operate portable document scanner; Standard Connectivity: USB 2.0
import { chromium } from 'playwright';
import { mkdir, writeFile } from 'node:fs/promises';

const urls = [
  'https://example.com/',
  'https://playwright.dev/docs/screenshots',
];

const outputDir = 'screenshots';
const navigationTimeoutMs = 30_000;

function safeHost(url) {
  return new URL(url).hostname.replace(/[^a-z0-9.-]/gi, '_');
}

await mkdir(outputDir, { recursive: true });
const browser = await chromium.launch();
const manifest = [];

try {
  for (const [index, url] of urls.entries()) {
    const filename = `${String(index + 1).padStart(3, '0')}-${safeHost(url)}.png`;
    const path = `${outputDir}/${filename}`;
    const page = await browser.newPage();

    try {
      const response = await page.goto(url, {
        waitUntil: 'load',
        timeout: navigationTimeoutMs,
      });
      if (!response) throw new Error('Navigation returned no main-resource response');
      if (!response.ok()) throw new Error(`HTTP ${response.status()}`);

      await page.screenshot({ path, fullPage: true });
      manifest.push({ url, path, status: 'saved' });
      console.log(`Saved ${url} to ${path}`);
    } catch (error) {
      const message = error instanceof Error ? error.message : String(error);
      manifest.push({ url, path: null, status: 'failed', error: message });
      console.error(`Failed ${url}: ${message}`);
    } finally {
      await page.close();
    }
  }
} finally {
  await browser.close();
  await writeFile(`${outputDir}/manifest.json`, JSON.stringify(manifest, null, 2));
}

This is an implementation pattern, not a guarantee that every site will render all content as intended. A navigation reaching load does not establish that a site’s delayed, animated, lazy-loaded, or authenticated content is ready for capture. Adapt the waiting condition to the page and your requirements.

Why the filename and manifest matter

Do not use a raw URL as a filename: URLs can contain characters that are awkward or invalid on a filesystem, and different URLs can collide after sanitization. The indexed hostname makes the example’s filenames filesystem-friendly and distinct within one run. The manifest preserves the exact URL-to-file mapping, including failures. For repeated runs, add a timestamp or another run identifier to avoid overwriting earlier output.

Choosing how failures affect the batch

The example continues after a per-URL failure and records its message in the manifest. If partial results are not useful in your workflow, change the catch block to rethrow and stop the batch. In either case, keep cleanup in finally blocks so an individual page and the browser are closed when an error occurs.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #2
Sale
Brother DS-640 Compact Mobile Document Scanner, (Model: DS640)
  • FAST SPEEDS - Scans color and black and white documents a blazing speed up to 16ppm (1). Color scanning won’t slow you down as the color scan speed is the same as the black and white scan speed.
  • ULTRA COMPACT – At less than 1 foot in length and only about 1. 5lbs in weight you can fit this device virtually anywhere (a bag, a purse, even a pocket).
  • READY WHENEVER YOU ARE – The DS-640 mobile scanner is powered via an included micro USB 3. 0 cable allowing you to use it even where there is no outlet available. Plug it into you PC or laptop and you are ready to scan.
  • WORKS YOUR WAY – Use the Brother free iPrint&Scan desktop app for scanning to multiple “Scan-to” destinations like PC, Network, cloud services, Email and OCR. (2) Supports Windows, Mac and Linux and TWAIN/WIA for PC/ICA for Mac/SANE drivers. (3)
  • OPTIMIZE IMAGES AND TEXT – Automatic color detection/adjustment, image rotation (PC only), bleed through prevention/background removal, text enhancement, color drop to enhance scans. Software suite includes document management and OCR software. (4)

Capture a URL batch with Puppeteer

If your project already uses Puppeteer, use the same workflow: loop over URLs, navigate, call the screenshot method with fullPage: true, and save to a unique path. Here is a sequential example with per-URL failure reporting and a manifest:

import puppeteer from 'puppeteer';
import { mkdir, writeFile } from 'node:fs/promises';

const urls = [
  'https://example.com/',
  'https://pptr.dev/api/puppeteer.screenshotoptions',
];
const outputDir = 'screenshots';
const navigationTimeoutMs = 30_000;

function safeHost(url) {
  return new URL(url).hostname.replace(/[^a-z0-9.-]/gi, '_');
}

await mkdir(outputDir, { recursive: true });
const browser = await puppeteer.launch();
const manifest = [];

try {
  for (const [index, url] of urls.entries()) {
    const path = `${outputDir}/${String(index + 1).padStart(3, '0')}-${safeHost(url)}.png`;
    const page = await browser.newPage();

    try {
      await page.setDefaultNavigationTimeout(navigationTimeoutMs);
      const response = await page.goto(url, { waitUntil: 'load' });
      if (!response) throw new Error('Navigation returned no main-resource response');
      if (!response.ok()) throw new Error(`HTTP ${response.status()}`);

      await page.screenshot({ path, fullPage: true });
      manifest.push({ url, path, status: 'saved' });
      console.log(`Saved ${url} to ${path}`);
    } catch (error) {
      const message = error instanceof Error ? error.message : String(error);
      manifest.push({ url, path: null, status: 'failed', error: message });
      console.error(`Failed ${url}: ${message}`);
    } finally {
      await page.close();
    }
  }
} finally {
  await browser.close();
  await writeFile(`${outputDir}/manifest.json`, JSON.stringify(manifest, null, 2));
}

Puppeteer’s screenshot options document both fullPage and path; PNG is the default format. Check the current ScreenshotOptions documentation for the version installed in your project.

Choose Playwright or Puppeteer

The documented capability is similar for this task, so choose the library that already fits your project, language, and browser setup. The available documentation establishes full-page screenshot support in both; it does not establish a universal winner for speed, reliability, or cost.

Rank #3
Sale
Epson Workforce ES-400 II High-Speed Color Duplex Desktop Document Scanner | For Computers including PC and Mac with Auto Document Feeder and Image Adjustment Tools
  • FAST DOCUMENT SCANNING — Document scanner with feeder allows you to speed through stacks with a 50-sheet Auto Document Feeder (ADF); Efficient office scanner to help you scan more productively
  • INTUITIVE, HIGH-SPEED SOFTWARE — Quickly scan with this desktop document scanner; Epson ScanSmart Software lets you easily preview scans, email files, upload to the cloud, and more; Plus, automatic file naming saves even more time
  • SEAMLESS INTEGRATION — Easily incorporate your data into most document management software with the included TWAIN driver; Office document scanner integrates seamlessly with business workflows
  • EASY SHARING — Duplex scanner allows you to scan straight to email or popular cloud storage2 services like Dropbox, Evernote, Google Drive, and OneDrive for simple storage and sharing
  • SIMPLE FILE MANAGEMENT — Scanner allows the creation of searchable PDFs with Optical Character Recognition (OCR) and convert scans to editable Word or Excel files effortlessly; Designed for home and office document scanning
Need Documented approach
Full-page capture with Playwright page.screenshot({ path, fullPage: true })
Full-page capture with Puppeteer Use fullPage in screenshot options and path to save the image; PNG is the default format.
Capture a selected element instead of the whole page Use an element or target screenshot. Playwright’s documented screenshots tool does not combine target with fullPage.

See Playwright’s screenshots tool documentation for the page-versus-target constraint. Element capture is a different task from capturing the entire scrollable page.

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

Control the batch’s practical risks

Navigation and readiness

Set a timeout appropriate to your sites and log failures with the URL. A timeout prevents one unresponsive navigation from blocking the run indefinitely, but an arbitrary wait after navigation does not prove that all page content is ready. If a specific page needs additional time or a known element to appear, add a site-appropriate readiness condition rather than assuming one wait rule suits every URL.

Lazy content, animation, and authentication

The cited screenshot APIs establish how to request a full-page image; they do not guarantee that lazy-loaded images, delayed content, animations, or authenticated pages will appear correctly. For sites requiring sign-in, configure the browser context with the authentication state your application is authorized to use. Inspect captures from representative pages before relying on a large run.

Rank #4
Canon Canoscan Lide 300 Scanner (PDF, AUTOSCAN, Copy, Send)
  • Scanner type: Document
  • Connectivity technology: USB
  • With Auto Scan Mode, the scanner automatically detects what you're scanning
  • Digitize documents and images

Large pages and resource use

Full-page captures can involve much more content than a viewport screenshot. Start with sequential processing as in the examples, then decide whether bounded concurrency is appropriate for your workload. Opening many pages at once can increase resource use and load on target sites; the cited API documentation does not provide a universal safe concurrency level or speed estimate.

Troubleshooting batch captures

  • The script cannot launch a browser: confirm the library and its browser installation are present in the project, then follow that library’s installation instructions for the version you use.
  • A URL times out: check that it is reachable from the machine running the script, raise the navigation timeout only if justified, and consider whether the page needs a different readiness condition.
  • A capture is missing or fails to save: confirm the output directory is writable and that every URL maps to a distinct output path. Review the per-URL error and manifest rather than assuming the whole batch succeeded.
  • The image omits content near the bottom: verify that fullPage: true is set on the screenshot call. If the option is present, investigate whether content loads only after scrolling or after a page-specific interaction; the option alone does not guarantee that delayed content has loaded.
  • The page is blank or returns an error: inspect the navigation result and HTTP status. Some sites require authentication or may block automated visits; do not treat a saved file as proof that the page rendered correctly.
  • A later run overwrites earlier images: include a run identifier in the output directory or filenames, while retaining the URL-to-file manifest.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Or skip the browser setup

ScreenshotNeo is a screenshot API and MCP server for developers. Send a GET request for a URL to receive an image or PDF; this example saves a WebP response. See the ScreenshotNeo API documentation for request options.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

To batch URLs, put that request in your own loop and choose a distinct output filename for each URL. ScreenshotNeo removes cookie/consent banners, newsletter popups, and chat widgets before capture; each step can be turned off. Bot checks and CAPTCHAs, blank pages, timeouts, failed loads, and cache hits are not billed, and response headers identify the page verdict and billing status. Its MCP server offers take_screenshot, get_page_info, and capture_pdf for AI agents and MCP clients. The Free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 shots.

Sign up for ScreenshotNeo free to get 1,000 screenshots a month with no card.

Best Value
Sale
ScanSnap iX2500 Wireless or USB High-Speed Document Scanner, Black | Cloud Enabled | Photos & Receipts | Large Touchscreen | 100 page Auto Document Feeder | Mac or PC
  • OUR MOST ADVANCED SCANSNAP. Large touchscreen, fast 45ppm double-sided scanning, 100-sheet document feeder, Wi-Fi and USB connectivity, automatic optimizations, and support for cloud services. Upgraded replacement for the discontinued iX1600
  • CUSTOMIZABLE. SHARABLE. Select personalized profiles from the touchscreen. Send to PC, Mac, mobile devices, and clouds. QUICK MENU lets you quickly scan-drag-drop to your favorite computer apps
  • STABLE WIRELESS OR USB CONNECTION. Built-in Wi-Fi 6 for the fastest and most secure scanning. Connect to smart devices or cloud services without a computer. USB-C connection also available
  • PHOTO AND DOCUMENT ORGANIZATION MADE EFFORTLESS. Easily manage, edit, and use scanned data from documents, receipts, photos, and business cards. Automatically optimize, name, and sort files
  • AVOIDS PAPER JAMS AND DAMAGE. Features a brake roller system to feed paper smoothly, a multi-feed sensor that detects pages stuck together, and skew detection to prevent paper damage and data loss

Frequently Asked Questions

Can I save a full-page screenshot as JPEG or WebP with these browser libraries?

The cited Playwright and Puppeteer material here establishes the full-page option and file path, but does not provide enough format detail to specify the relevant format options for both libraries. Check the documentation for your installed version.

Does `fullPage: true` capture a selected element and the whole document at once?

No such combination is established here. Playwright’s documented screenshots tool treats target capture and full-page capture as separate options.

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

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.

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
Crashes, No Sound, or Screen Glitches?Free driver scan
Windows Errors? Fix Them Before They SpreadFree repair scan

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.