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

iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more

Give your AI agent a clear instruction to open the website, wait for it to render, save a full-page screenshot as an image, and export a separate PDF. With Playwright CLI, those are two commands: playwright-cli screenshot --full-page --filename=website.png and playwright-cli pdf --filename=website.pdf. A screenshot is an image; the PDF is a separate browser-rendered document.

What to ask the AI agent to do

Use this Hindi prompt, replacing the example with the page you want:

इस URL को खोलें: https://example.com। पेज पूरी तरह render होने दें। पूरे scrollable पेज का PNG screenshot website.png नाम से सहेजें। फिर उसी पेज को website.pdf नाम से PDF के रूप में export करें। दोनों फ़ाइलें बनने की पुष्टि करें।

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

The prompt names the URL, asks for the entire scrollable page, specifies both output formats and filenames, and asks the agent to confirm that both files exist. If you only want the visible portion, replace “पूरे scrollable पेज” with “वर्तमान viewport.” Waiting for rendering matters on long or dynamic pages; there is no single wait duration established for every site.

#1 Best Overall
Sale
Epson Workforce ES-50 Compact & Lightweight Mobile Document Scanner
  • 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

Use Playwright CLI

When the agent can run Playwright CLI commands in its working environment, ask it to execute these two commands for the page it has opened:

playwright-cli screenshot --full-page --filename=website.png
playwright-cli pdf --filename=website.pdf

The first command saves a full-page image; the second exports a PDF. The screenshot command can also capture the current viewport or a target element. Its documented image formats are PNG, JPEG and WebP; the filename extension helps select the format. To capture only the current viewport, omit --full-page:

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)
playwright-cli screenshot --filename=website.png

For the corresponding CLI options and PDF command, see the Playwright CLI screenshots and PDF documentation.

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

Use the Playwright Page API in code

If the agent is writing browser automation rather than issuing CLI commands, use the Playwright Page API. This runnable JavaScript example assumes the Playwright package is installed and a browser page has been opened and navigated to the target URL:

Rank #3
Sale
Canon imageFORMULA R10 - Portable Document Scanner, USB Powered, Duplex Scanning, Document Feeder, Easy Setup, Convenient, Perfect for Mobile Users, White
  • STAY ORGANIZED – Easily convert your paper documents into digital formats like searchable PDF files, JPEGs, and more.Power Consumption : 2.5W or less (Energy Saving Mode: 0.7W). Suggested Daily Volume : 500 scans..Does it contain liquid: no
  • CONVENIENT AND PORTABLE –lightweight and small in size, you can take the scanner anywhere from home offices, classrooms, remote offices, and anywhere in between
  • HANDLES VARIOUS MEDIA TYPES – Digitize receipts, business cards, plastic or embossed cards, reports, legal documents, and more
  • FAST AND EFFICIENT – No technical hurdles or complicated setups here; easily scan both sides of a document at the same time, in color or black-and-white, at up to 12 pages-per-minute, and with a 20 sheet automatic feeder
  • BROAD COMPATIBILITY – Works with both Windows and Mac devices, be it laptop or computer
await page.goto('https://example.com');
await page.screenshot({ path: 'website.png', fullPage: true });
await page.pdf({ path: 'website.pdf' });

For a viewport-only image, leave out fullPage: true. The image screenshot and PDF export are separate calls, so request both if you need both files.

Choose how the PDF should look

page.pdf() renders with print CSS media by default. If the site has print-specific styles but you want its screen styling instead, set the media mode before exporting:

Rank #4
IRIScan Express 4 Black Compact Portable USB Simplex Document Scanner, 8 PPM for Contracts, Invoices and Business Cards, Compatible with Windows, Readiris PDF Included
  • IRIScan Express, portable scanner : scans color and black and white documents a blazing speed up to 8ppm simplex. Color scanning won’t slow you down as the color scan speed is the same as the black and white scan speed.
  • IRIScan Express mobile scanner is powered via an included micro USB 2. 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. USB cable provided. AC Adapter not provided and not needed.
  • IRIScan flatbed scanner uses a simplex scanning mode allows for quick and straightforward scanning of single-sided documents. IRIScan with its full portable features is the ideal document scanners for computers.
  • IRIScan document scanner : Versatile scanning capabilities, including scanning to Word, PDF, and Excel formats with companion software provided Readiris OCR
  • Receipt scanner and card scanner with Additional features include scanning business cards directly to Outlook, photo scanning, and receipt scanning for efficient document management
await page.emulateMedia({ media: 'screen' });
await page.pdf({ path: 'website.pdf' });

PDF colors may be adjusted for printing. Playwright’s documentation notes -webkit-print-color-adjust for controlling print color adjustment. Check the resulting PDF when exact colors or layout matter. See the Playwright Page API documentation for screenshot and PDF options.

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.

Other ways an AI agent can capture the page

Playwright MCP

If your agent uses Playwright MCP, its screenshot tool can capture the viewport, an element or the full scrollable page. A screenshot helps inspect visual layout; an accessibility snapshot is a separate way to understand page structure and interactions. Use the screenshot tool for the image, and ask the agent to use a PDF-capable browser workflow if you also need a PDF. See Playwright MCP screenshot documentation.

Best Value
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

Chrome Headless CLI

Where Chrome is available in headless mode, its command-line reference documents --screenshot for an image and --print-to-pdf for PDF output. The --timeout option adds render time before capture. For example, an agent can adapt this pattern to the installed Chrome command and target URL:

chrome --headless --timeout=5000 --screenshot=website.png https://example.com
chrome --headless --timeout=5000 --print-to-pdf=website.pdf https://example.com

The timeout value here is only an example, not a universal recommendation; pages differ in load and rendering behavior. Check the command name and supported options for the Chrome installation in use. See the Chrome Headless command-line reference.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Choose the right capture for the job

Method Best suited to Key choice
Playwright CLI Agent or command-line capture Viewport or --full-page; PNG, JPEG or WebP; choose a filename.
Playwright Page API Code-based browser automation Image via page.screenshot() or PDF via page.pdf(); print or screen media.
Playwright MCP Agents using MCP browser tools Capture viewport, element or full page; use an accessibility snapshot for structure and interactions.
Chrome Headless CLI Command-line capture without the browser UI Choose --screenshot or --print-to-pdf; allow render time with --timeout.

Check the files and diagnose common problems

  • The image shows only part of the page: A viewport capture includes only what is visible. Use --full-page in the CLI or fullPage: true in the Page API for the full scrollable page.
  • You got an image but no PDF, or the reverse: Screenshot and PDF are separate outputs. Run or request both capture operations and confirm that both named files were created.
  • The PDF looks different from the browser: Playwright PDF output uses print CSS media by default. If screen styling is needed, call page.emulateMedia({ media: 'screen' }) before page.pdf(). Print color adjustment can also affect appearance.
  • The capture is incomplete on a dynamic page: Ask the agent to wait for the page to render before capturing. In Chrome Headless, --timeout can add render time; no fixed duration suits every page.
  • The agent cannot find a command or tool: It may not have Playwright CLI, Playwright MCP, or Chrome configured in its environment. Ask it which browser workflow is available, then use the matching CLI, API or MCP instructions above.

Or skip the browser setup

ScreenshotNeo provides a website screenshot API and MCP server. Its API can return an image or PDF from one GET request; the request below saves a PDF:

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://example.com -o website.pdf

See the ScreenshotNeo API documentation for setup and options. ScreenshotNeo can accept cookie or consent banners and remove more than 60 known consent platforms, 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 report the page verdict and billing status. Its MCP server includes tools for screenshots, page information and PDF capture. The free plan includes 1,000 screenshots a month with no card; paid plans start at $5 for 3,000 shots. Visit ScreenshotNeo for details, or sign up free for 1,000 screenshots a month with no card.

Frequently Asked Questions

Can an AI agent save both a screenshot and a PDF?

Yes. Ask it for both outputs explicitly: the screenshot is an image file, while the PDF is a separate export.

Does a full-page screenshot include the whole website?

It captures the page’s scrollable content, not every page on the website. To capture multiple URLs, request a capture for each one.

Quick Recap

SaleBestseller No. 3
Canon imageFORMULA R10 - Portable Document Scanner, USB Powered, Duplex Scanning, Document Feeder, Easy Setup, Convenient, Perfect for Mobile Users, White
Canon imageFORMULA R10 - Portable Document Scanner, USB Powered, Duplex Scanning, Document Feeder, Easy Setup, Convenient, Perfect for Mobile Users, White
BROAD COMPATIBILITY – Works with both Windows and Mac devices, be it laptop or computer; This product is not intended for scanning photographs on photo paper / photographic media
$153.00
Bestseller No. 4
IRIScan Express 4 Black Compact Portable USB Simplex Document Scanner, 8 PPM for Contracts, Invoices and Business Cards, Compatible with Windows, Readiris PDF Included
IRIScan Express 4 Black Compact Portable USB Simplex Document Scanner, 8 PPM for Contracts, Invoices and Business Cards, Compatible with Windows, Readiris PDF Included
Find our Software here : irislink.com/start; IRIScan Express is only compatible Windows platform and not macintosh
$129.00
Bestseller No. 5
Canon Canoscan Lide 300 Scanner (PDF, AUTOSCAN, Copy, Send)
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
$75.00

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.