# Website Screenshot & PDF API: Full-Page PNG, JPEG, PDF (`magenta_waterwheel/website-screenshot-pdf`) Actor

Website screenshot API: capture full-page or viewport screenshots (PNG, JPEG) or convert web pages to PDF in bulk with a real Chrome browser. Mobile and retina viewports, dark mode, element capture, lazy-load scrolling, ad blocking and cookie banner hiding. Failed pages are free.

- **URL**: https://apify.com/magenta_waterwheel/website-screenshot-pdf.md
- **Developed by:** [Huss](https://apify.com/magenta_waterwheel) (community)
- **Categories:** Developer tools, Automation, SEO tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.50 / 1,000 screenshots

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Website Screenshot & PDF API: Full-Page PNG, JPEG, PDF

**Website Screenshot & PDF API** is a bulk **website screenshot API** and **URL to PDF converter**. It captures **full-page or viewport screenshots** (PNG or JPEG) and **prints web pages to PDF** in bulk, using a real Chrome browser. Paste a list of URLs, pick a format, and get a download link for every file, plus page title, final URL and HTTP status.

It works for single pages or thousands of URLs. Common uses include visual archiving, website thumbnails, compliance records, QA and design reviews, link previews, and saving articles or invoices as PDFs. It's easy to call from AI agents, Zapier, Make, n8n or your own code through the Apify API.

### Why use this website screenshot API?

|                                                | Website Screenshot & PDF API                                           | Desktop extensions and manual capture | Self-hosted Puppeteer or Playwright |
| ---------------------------------------------- | ---------------------------------------------------------------------- | ------------------------------------- | ----------------------------------- |
| Bulk URLs                                      | Thousands per run                                                      | One at a time                         | Yes, after you build it             |
| Full-page, viewport and single-element capture | Yes                                                                    | Partly                                | You write the code                  |
| PNG, JPEG **and** PDF in one tool              | Yes                                                                    | Rarely                                | You write the code                  |
| Retina, mobile viewport, dark mode             | Yes                                                                    | Limited                               | You write the code                  |
| Cookie banners, ads and trackers               | Ads and trackers blocked by default, banners hidden with CSS selectors | Visible                               | You write the code                  |
| Servers, browsers and scaling                  | Handled by Apify                                                       | n/a                                   | Your job                            |
| Failed or 404 pages                            | **Not charged**                                                        | n/a                                   | Still cost compute                  |

### Who uses website screenshots?

- **SEO and marketing teams** capturing competitor landing pages, SERPs and ad pages over time.
- **Compliance and legal teams** archiving web pages as dated PDFs or images for evidence.
- **QA, design and dev teams** checking how pages render at different viewports and in dark mode.
- **Product and growth teams** generating website thumbnails and link previews.
- **AI agents** that need to "see" a page or save it as a PDF for later reading.

### What can this screenshot tool do?

- 📸 **Full-page screenshots** of the whole scrollable page, or just the visible viewport.
- 📄 **Web page to PDF** with paper size (A4, Letter, Legal, A3, Tabloid), landscape mode and background printing.
- 🖼️ **PNG or JPEG**, with adjustable JPEG quality for smaller files.
- 📱 **Any viewport**, from a phone view (390 px wide) to 4K, with **retina (2x/3x)** pixel density.
- 🌙 **Dark mode** rendering for sites that support it.
- 🧹 **Hide cookie banners, chat widgets and popups** with CSS selectors.
- 🎯 **Capture a single element**, such as a pricing table, chart or tweet embed.
- ⏳ **Lazy-loaded content**: scroll to the bottom first and wait for network idle or an extra delay.
- 🚦 **No charge for broken pages.** Pages returning 404 or other HTTP errors are skipped and reported, not billed.

### How to take website screenshots in bulk

1. Click **Try for free**.
2. Add your **URLs**, typing them in, pasting a list or uploading a text file.
3. Choose **Output format**: PNG, JPEG or PDF.
4. Optionally set the viewport size, dark mode, elements to hide, or PDF options.
5. Click **Start**. Each result has a `fileUrl` you can open or download.

### Input example

```json
{
    "startUrls": [{ "url": "https://apify.com" }, { "url": "https://en.wikipedia.org/wiki/Web_scraping" }],
    "format": "png",
    "fullPage": true,
    "viewportWidth": 1280,
    "viewportHeight": 800,
    "deviceScaleFactor": 1,
    "hideSelectors": ["#onetrust-banner-sdk"],
    "scrollToBottom": false
}
```

For a PDF, set `"format": "pdf"` and optionally `"pdfPaperFormat": "Letter"` and `"pdfLandscape": true`.

### Output example

Every captured page is one dataset item, and the file itself is stored in the run's key-value store:

```json
{
    "url": "https://en.wikipedia.org/wiki/Web_scraping",
    "finalUrl": "https://en.wikipedia.org/wiki/Web_scraping",
    "statusCode": 200,
    "title": "Web scraping - Wikipedia",
    "format": "png",
    "fileUrl": "https://api.apify.com/v2/key-value-stores/<storeId>/records/screenshot-en.wikipedia.org-0dbff88b785a",
    "key": "screenshot-en.wikipedia.org-0dbff88b785a",
    "contentType": "image/png",
    "bytes": 2439275,
    "viewportWidth": 1280,
    "viewportHeight": 800,
    "fullPage": true,
    "selector": null,
    "takenAt": "2026-10-07T20:16:58.699Z"
}
```

Pages that couldn't be captured are listed with the reason (for example `Page returned HTTP 404`) in the `RUN_SUMMARY` record of the key-value store.

### How much does it cost to screenshot a website?

This Actor uses **pay-per-event** pricing. You only pay for files that were successfully saved:

| Event                                               | Price                                          |
| --------------------------------------------------- | ---------------------------------------------- |
| Screenshot saved (PNG or JPEG)                      | **$2.50 per 1,000 screenshots** ($0.0025 each) |
| PDF saved                                           | **$3.00 per 1,000 PDFs** ($0.003 each)         |
| High-resolution add-on (device scale factor 2 or 3) | $3.00 per 1,000 screenshots ($0.003 each)      |
| Actor start                                         | $0.00005 per run                               |

For example, 1,000 full-page screenshots at standard resolution cost about **$2.50**, and the same 1,000 at retina (2x) resolution cost about **$5.50**. 1,000 PDFs cost **$3**. Failed pages and HTTP error pages are free when **Skip pages with HTTP errors** is on (the default). Set **Maximum cost per run** in the run options to cap spending; the Actor stops cleanly when the limit is reached.

You don't pay separately for compute or the browser: the price per file already includes them.

### Tips

- **Cookie banners**: add selectors like `#onetrust-banner-sdk`, `.cookie-banner` or `[id*="cookie"]` to **Hide elements**.
- **Blank areas in full-page screenshots** usually mean lazy loading. Turn on **Scroll to bottom first** or add a short **Extra delay**.
- **Heavy single-page apps**: use **Wait until: Network idle**.
- **Ads and trackers** are blocked by default for faster, cleaner captures. Turn off **Block ads and trackers** to capture a page exactly as visitors see it.
- **Smaller files**: use JPEG at quality 60–80, and keep the device scale factor at 1.
- Some websites block automated browsers. Those pages are reported as failed, and you aren't charged for them.

### Use it with AI agents (MCP) and the API

Add this Actor as a tool in Claude, ChatGPT, Cursor, VS Code or any other MCP client through the [Apify MCP server](https://docs.apify.com/mcp):

```text
https://mcp.apify.com?tools=magenta_waterwheel/website-screenshot-pdf
```

Then just ask, for example: *"Take full-page screenshots of these 20 competitor homepages on a mobile viewport and give me the links."* The agent fills in the input, runs the Actor and reads the results. The Actor runs with **limited permissions**, so it can only access its own run storage.

To get results in a single HTTP request, call the synchronous endpoint with your [Apify API token](https://console.apify.com/settings/integrations):

```bash
curl -X POST "https://api.apify.com/v2/acts/magenta_waterwheel~website-screenshot-pdf/run-sync-get-dataset-items" \
  -H "Authorization: Bearer $APIFY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"startUrls":[{"url":"https://apify.com"}],"format":"png","fullPage":true}'
```

You can also use the official [Python](https://docs.apify.com/api/client/python) and [JavaScript](https://docs.apify.com/api/client/js) clients, or the ready-made code on the **API** tab.

### Integrations and scheduling

- ⏰ **Schedule runs** hourly, daily or weekly in Apify Console, with no server to maintain.
- 🔗 **Send results anywhere**: Google Sheets, Slack, Google Drive, Airbyte, webhooks, or no-code tools such as **Make, Zapier and n8n**.
- 📤 **Export** the dataset as JSON, CSV, Excel, XML, RSS or HTML.
- 📈 **Monitoring**: get notified if a run fails, and see every run's log and cost in Console.

### FAQ

#### Is there a free trial?

Yes. Apify's Free plan includes **$5 of usage credit every month**, enough for about **2,000 screenshots** with this Actor. No credit card is needed to start.

#### How do I convert a web page to PDF?

Set **Output format** to **PDF**. Choose the paper size (A4, Letter, Legal, A3 or Tabloid), portrait or landscape, and whether to print backgrounds. Each URL becomes one PDF file with a download link.

#### How do I take screenshots on a schedule?

Save your input as a task and add a schedule in Apify Console, for example daily at 9:00. Every run stores new dated files, which is handy for visual change tracking and archiving.

#### Where do I download the files?

Each dataset item has a `fileUrl` that points to the file in the run's key-value store. You can also open the **Storage → Key-value store** tab of the run and download all files, or fetch them via the [Apify API](https://docs.apify.com/api/v2).

#### How long are files kept?

Files stay in the run's default key-value store according to your Apify plan's data retention. Download them or copy them to your own storage, for example through an integration, if you need to keep them longer.

#### Can it capture pages behind a login?

No. The Actor captures publicly accessible pages only.

#### Why did a page fail with HTTP 403?

The website blocked the automated browser. You can try the **Proxy configuration** option, but some sites will still block screenshots. You are not charged for failed pages.

#### Is there a maximum page height?

Very long pages, tens of thousands of pixels, take longer and produce large files. Use JPEG, viewport-only mode, or an element selector for extremely long pages.

#### Can I use it from AI agents or my own app?

Yes. Call it via the Apify API, the Apify MCP server, or the JavaScript and Python clients. Pass `startUrls` and read `fileUrl` from the dataset.

#### I found a bug or need a feature

Open an issue in the **Issues** tab with a link to your run. We aim to reply within one business day.

### More tools from the same developer

| Actor                                                                                       | What it does                                                                       | Price                 |
| ------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | --------------------- |
| [Career Site Jobs API](https://apify.com/magenta_waterwheel/career-site-jobs-api)           | Jobs from Greenhouse, Lever, Ashby and SmartRecruiters career sites, with salaries | $2 / 1,000 jobs       |
| [App Store Reviews Scraper](https://apify.com/magenta_waterwheel/app-store-reviews-details) | Apple App Store reviews and app details in any country                             | $0.25 / 1,000 reviews |
| [Document & PDF to Markdown](https://apify.com/magenta_waterwheel/document-to-markdown)     | PDF, Word, PowerPoint, Excel and HTML to LLM-ready Markdown, with OCR              | $3 / 1,000 pages      |

# Actor input Schema

## `startUrls` (type: `array`):

Web pages to capture. You can add URLs one by one, paste many at once, or upload a text file.

## `format` (type: `string`):

PNG for lossless screenshots, JPEG for smaller files, or PDF to print the page as a document.

## `fullPage` (type: `boolean`):

Capture the whole scrollable page instead of only the visible viewport. Ignored for PDF (PDFs always contain the whole page).

## `viewportWidth` (type: `integer`):

Browser window width. Use 390 for a phone-like view, 1280 or 1920 for desktop.

## `viewportHeight` (type: `integer`):

Browser window height. With full-page off, this is the screenshot height.

## `deviceScaleFactor` (type: `integer`):

Pixel density. Use 2 for sharp retina-quality screenshots. Files are about 4x larger, and screenshots above 1x have an extra high-resolution charge (see Pricing).

## `colorScheme` (type: `string`):

Ask the page to render in light or dark mode (works on sites that support prefers-color-scheme).

## `jpegQuality` (type: `integer`):

JPEG quality from 1 to 100. Only used for JPEG.

## `waitUntil` (type: `string`):

When to consider the page loaded. "Network idle" waits for most background requests to finish, which is best for heavy single-page apps.

## `delaySecs` (type: `integer`):

Wait this many seconds after the page loads before capturing, for animations or late content. Maximum 10 seconds.

## `scrollToBottom` (type: `boolean`):

Scroll through the page before capturing so lazy-loaded images and sections appear in full-page screenshots and PDFs.

## `blockTrackers` (type: `boolean`):

Block common ad, analytics, and tracking scripts (Google Analytics, Tag Manager, DoubleClick, Facebook Pixel, Hotjar, and similar) and streaming video files. Pages load faster and captures come out cleaner. Turn off to capture pages exactly as visitors see them, ads included.

## `hideSelectors` (type: `array`):

CSS selectors of elements to hide before capturing, such as cookie banners, chat widgets or popups. Example: #onetrust-banner-sdk, .cookie-banner.

## `selector` (type: `string`):

Screenshot only the first element matching this CSS selector, for example #main or .pricing-table. Leave empty to capture the page. Ignored for PDF.

## `pdfPaperFormat` (type: `string`):

Paper size for PDF output.

## `pdfLandscape` (type: `boolean`):

Use landscape orientation for PDF output.

## `pdfPrintBackground` (type: `boolean`):

Include background colors and images in PDF output.

## `failOnHttpError` (type: `boolean`):

Don't capture (or charge for) pages that return HTTP 4xx or 5xx, such as 404 Not Found. Turn off to capture error pages too.

## `navigationTimeoutSecs` (type: `integer`):

Maximum time to wait for a page to load.

## `maxConcurrency` (type: `integer`):

Maximum pages captured in parallel. The Actor also scales automatically based on available memory.

## `maxRequestRetries` (type: `integer`):

How many times to retry a page after a timeout, network error or HTTP 5xx error.

## `proxyConfiguration` (type: `object`):

Optional proxy, for example to capture a site as seen from another country. Not needed for most sites.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://apify.com"
    },
    {
      "url": "https://en.wikipedia.org/wiki/Web_scraping"
    }
  ],
  "format": "png",
  "fullPage": true,
  "viewportWidth": 1280,
  "viewportHeight": 800,
  "deviceScaleFactor": 1,
  "colorScheme": "light",
  "jpegQuality": 80,
  "waitUntil": "load",
  "delaySecs": 0,
  "scrollToBottom": false,
  "blockTrackers": true,
  "hideSelectors": [],
  "pdfPaperFormat": "A4",
  "pdfLandscape": false,
  "pdfPrintBackground": true,
  "failOnHttpError": true,
  "navigationTimeoutSecs": 60,
  "maxConcurrency": 5,
  "maxRequestRetries": 2,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `captures` (type: `string`):

No description

## `files` (type: `string`):

No description

## `runSummary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "startUrls": [
        {
            "url": "https://apify.com"
        },
        {
            "url": "https://en.wikipedia.org/wiki/Web_scraping"
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("magenta_waterwheel/website-screenshot-pdf").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "startUrls": [
        { "url": "https://apify.com" },
        { "url": "https://en.wikipedia.org/wiki/Web_scraping" },
    ] }

# Run the Actor and wait for it to finish
run = client.actor("magenta_waterwheel/website-screenshot-pdf").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "startUrls": [
    {
      "url": "https://apify.com"
    },
    {
      "url": "https://en.wikipedia.org/wiki/Web_scraping"
    }
  ]
}' |
apify call magenta_waterwheel/website-screenshot-pdf --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,magenta_waterwheel/website-screenshot-pdf"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/sMfEZAQG4vvaY9Apk/builds/vtbTNuUYSNZLliffk/openapi.json
