Hardware FixRecommendedDevice not working? Your driver may be the problemCheck updates for common hardware issues.Fix DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsWindows FixRecommendedWindows errors stealing your time? Find the fix fastScan stability, cleanup and performance issues.Fix Now×
Skip to content
World desk7 min

Website Screenshot API: Capture Pages as Images or PDFs

A practical guide to capturing rendered web pages as screenshots or PDFs with Playwright or a hosted API, including capture modes, code, trade-offs and troubleshooting.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

A website screenshot API renders a URL in a browser and returns an image or PDF; it captures what a browser displays, not merely the page’s raw HTML. Use a hosted API when you want someone else to run the browser, or Playwright when you need browser-level control in your own environment. For a managed option, ScreenshotNeo returns screenshots or PDFs from a single GET request and also provides an MCP server for AI agents.

Choose a capture method

Method What it does Best fit
ScreenshotNeo Managed screenshot and PDF capture through an HTTP API, with an MCP server for AI agents. Teams that prefer a hosted browser and want clean captures with clear billing verdicts.
Playwright in your environment Launches a browser, navigates to a page, and saves a screenshot or PDF through browser APIs. Teams that can operate browser infrastructure and need direct control over the capture flow.
Other managed APIs Microlink documents URL-based screenshots and PDFs; ScreenshotCenter documents PDF capture with scripted actions. Workflows that depend on a provider’s specific parameters, integrations, or interaction support.

There is no independent, comparable benchmark here that establishes one provider as universally fastest or most reliable. Compare the exact capture controls, operational requirements, data handling, quotas and cost you need, then test your own representative pages if latency or fidelity is important.

As an Amazon Associate I earn from qualifying purchases.

Decide what the output must contain

Viewport screenshot

A viewport capture records the visible browser area. It is suitable for a card, preview, or visual check of the top of a page, but it will not include content farther down the page unless you scroll or request a full-page capture.

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

Full-page screenshot

A full-page image captures the scrollable page as if it were displayed on a very tall screen. Use it for long articles, reports, or page archives. Lazy-loaded images and other content may not appear until they have been scrolled into view; wait for or trigger loading before capturing when completeness matters.

Element screenshot

Capturing one element, such as a chart or product panel, avoids saving unrelated page content. The element must exist and be visible when the capture runs; dynamic pages may need a selector wait or interaction first.

PDF

A PDF is useful for document-style output, but it follows print-rendering behavior. Playwright’s page.pdf() uses print CSS media by default, so styles can differ from the screen. If you need screen styling, emulate screen media before generating the PDF. Page size, margins, orientation, and page ranges also affect the result.

Capture with Playwright

This Node.js example follows Playwright’s documented flow: launch a browser, navigate, save a screenshot, and close the browser. It uses Chromium; Playwright’s example also uses WebKit and notes Chromium or Firefox as alternatives.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  1. Install Playwright: npm install playwright, then install the browser you intend to use with npx playwright install chromium.
  2. Save this as capture.mjs:
    import { chromium } from 'playwright';
    
    const url = process.argv[2] ?? 'https://example.com';
    const browser = await chromium.launch();
    try {
      const page = await browser.newPage({ viewport: { width: 1440, height: 900 } });
      await page.goto(url, { waitUntil: 'load', timeout: 60_000 });
      await page.screenshot({ path: 'page.png', fullPage: true });
    } finally {
      await browser.close();
    }
  3. Run it: node capture.mjs https://example.com. The output is page.png in the current directory.

For a viewport image, omit fullPage: true. To capture a specific element, locate it and call its screenshot method, for example await page.locator('.report').screenshot({ path: 'report.png' }). Use a selector that identifies the intended element on the target site.

Adjust image format and scale

Playwright supports PNG, JPEG, and WebP screenshot output, plus scale controls for CSS-pixel or device-pixel sizing. For example, choose a path ending in .jpg and pass type: 'jpeg' with a quality value for a lossy JPEG. Device-pixel scale can increase image dimensions and file size; choose it based on the output’s display or storage needs.

Generate a PDF

Use the same page after navigation, then call page.pdf(). For example:

await page.pdf({ path: 'page.pdf', format: 'A4', printBackground: true });

To use screen styles instead of the default print media styling, call await page.emulateMedia({ media: 'screen' }) before page.pdf(). Set an explicit paper size or format and margins when consistent pagination matters.

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

Or skip the browser setup

ScreenshotNeo’s GET endpoint takes a URL and returns an image or PDF. This cURL example saves a WebP screenshot of Stripe; replace the target URL and supply your API key. See the ScreenshotNeo API documentation for parameters and response details.

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

Cookie banners and consent overlays are accepted or removed before capture, along with known newsletter popups and chat widgets; each cleanup step can be turned off. Bot checks, blank pages, timeouts, failed loads, and cache hits are not billed, and response headers report the page verdict and billing status. An MCP server exposes take_screenshot, get_page_info, and capture_pdf for Claude, Cursor, and other MCP clients. The Free plan includes 1,000 shots per month without a card; paid plans start at $5 for 3,000 shots.

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

Compare providers by the work your capture flow needs

ScreenshotNeo

ScreenshotNeo is the first managed option to consider here: clean shots, billing only for clean shots, and a paid plan starting at $5 for 3,000 shots. Its 63 options include full-page, selector-based, and PDF capture; device presets and custom viewport; custom CSS and JavaScript; click, selector, delay, and network-idle waits; request and resource blocking; headers, cookies, user agent, and authorization; timezone and geolocation; caching; signed image links; async jobs with signed webhooks; bulk capture up to 100 URLs per call; a usage API; and an OpenAPI spec. Parameter names used by other screenshot APIs also work, which can ease migration. All features are available on every plan.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Plan Monthly price Shots included
Free $0 1,000 per month
Starter $5 3,000
Growth $15 15,000
Pro $39 60,000
Scale $99 250,000
Business $249 1,000,000

Yearly billing gives two months free. Check the current plan page before purchase because prices and quotas can change.

Microlink

Microlink documents a managed REST API for screenshots, PDFs, and other URL-derived data. Its screenshot response can include an image URL, dimensions, type, and size, and its documentation describes target-element and output parameters. Microlink’s API page displayed 25 requests per day on Free, and a Pro plan at $49 per month with about 46,000 requests per month and a 99.9% uptime SLA on paid plans when accessed October 3, 2026. These are Microlink’s displayed plan and SLA claims, not independent performance findings; verify current terms before relying on them.

ScreenshotCenter

ScreenshotCenter’s PDF page shows a POST request with a URL, scripted actions, and a screenshot target. It lists integrations including Google Drive, SharePoint, S3, Zapier, and n8n. Those are vendor-described capabilities; confirm that the exact actions and integrations you need are supported under the current plan.

Reliability, performance, and cost considerations

  • Browser ownership: With Playwright, your team runs and maintains the browser, capture code, storage, and failure handling. A hosted API takes on browser execution, but its quotas, caching, authentication, proxy handling, support, and service guarantees vary by provider.
  • Rendering time: Pages can wait on scripts, fonts, images, network calls, or interaction. A fixed delay can help with known timing needs but may waste time; waiting for a meaningful selector or network condition is often more targeted. Test dynamic pages instead of assuming a single wait strategy works everywhere.
  • Caching: A cached result can reduce repeated work, but it may not reflect recent page changes. Check whether the provider offers cache controls and decide how fresh the capture must be.
  • Output size: Full-page images and high device-pixel scale can produce larger files. Choose the format and dimensions required downstream, and account for storage and transfer costs in addition to API or browser costs.
  • Authentication and sensitive pages: A capture service may need cookies, headers, or authorization to access a page. Review the service’s data controls and avoid sending credentials or sensitive URLs unless its handling meets your requirements.
  • Blocked requests: Bot checks and CAPTCHAs can prevent a browser from reaching the intended content. A screenshot API cannot guarantee that a protected page will render as a normal visitor sees it; distinguish a valid page capture from a block or challenge response.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Troubleshoot common capture failures

The image is blank or incomplete

Confirm the URL is reachable from the capture environment and that navigation completed. Wait for a page-specific selector or content to appear; if images are lazy-loaded, scroll or use full-page capture behavior that loads them before saving. Check whether the page returned a bot challenge instead of its normal content.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

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

The screenshot cuts off the page

Use full-page capture rather than a viewport screenshot. If you need a single region, capture its element explicitly and confirm the selector resolves to the intended element.

The PDF looks different from the browser

Print CSS is the default for Playwright PDF generation. Emulate screen media before calling page.pdf() if screen styling is required, and set paper size, margins, and background printing intentionally.

Navigation times out

Slow or continuously active pages may not reach the chosen readiness condition within the timeout. Check whether the target URL is available, use an appropriate wait condition or a page-specific selector, and set a timeout that matches the workflow. Treat a timeout as a failed capture rather than assuming the saved file is complete.

Images are too large or soft

Check the viewport and screenshot scale. Device-pixel output increases pixel dimensions; use CSS-pixel sizing where smaller files are preferable, or select an appropriate compression format and quality when a lossy image is acceptable.

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

Hosted API output is stale

Check whether caching is enabled and whether the cache lifetime suits the update frequency of the page. If current content is essential, configure cache behavior accordingly or use a fresh capture path.

Further documentation

Frequently Asked Questions

Does a screenshot API capture HTML source?

No. It renders the page in a browser and captures the rendered result.

Can I use an API to capture just one page element?

Yes. Playwright supports element screenshots, and managed providers may offer a target selector or element capture parameter; check the relevant API’s documentation.

Why can a PDF differ from a screenshot?

PDF generation may use print CSS rather than screen CSS. In Playwright, print media is the default for page.pdf().

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
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

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.