# Website Screenshot & PDF — No Cookie Banners, Full Page, Mobile (`robinsiacreation/website-screenshot-pdf`) Actor

Capture full-page or viewport screenshots (PNG/JPG) or PDFs of any list of URLs. Auto-closes cookie consent banners, scrolls to load lazy images, emulates desktop, laptop, tablet and mobile, dark mode, element capture. Pay per screenshot.

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

## Pricing

Pay per event

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 — no cookie banners, full page, mobile

Take clean screenshots or PDFs of any list of websites. Paste URLs, get PNG, JPG or PDF links back — in bulk, through the API, or from your AI agent.

- **No cookie banners:** automatically clicks "Accept" on consent pop-ups (OneTrust, Cookiebot, Didomi, Quantcast, Usercentrics, Sourcepoint and generic ones in 15+ languages) and hides whatever remains.
- **Real full-page captures:** scrolls the page first so lazy-loaded images actually appear.
- **Any device:** desktop, laptop, tablet (iPad) and mobile (iPhone, retina @3x).
- **PNG, JPG or PDF** (A4 with backgrounds).
- **Element capture:** screenshot only `#pricing`, `.hero` or any CSS selector.
- **Hide anything:** chat widgets, ads, pop-ups via CSS selectors.
- **Dark mode** emulation.
- **Ad & tracker blocking** for faster, cleaner captures (optional).
- **Bulk & parallel:** hundreds of URLs per run, several pages at once. One broken URL doesn't stop the batch and is not charged.

### What is it good for?

| Use case | Example |
|---|---|
| Monitoring | Daily screenshots of competitors' pricing or landing pages (use Apify Schedules) |
| SEO & agencies | Before/after captures, client reports, mobile vs desktop checks |
| Archiving & compliance | Evidence of what a page showed on a given date (PDF) |
| QA | Visual checks across devices after every deploy |
| AI agents & LLMs | Give a vision model a clean picture of a page |
| Link previews | Thumbnails for directories, bookmarks and newsletters |

### How to use it

1. Paste one or more **URLs**.
2. Pick the **device**, **full page** or not, and **format**.
3. Click **Start**. Each result row has the page title, HTTP status and a direct link to the file.

#### Input example

```json
{
  "urls": ["https://www.bbc.com", "apify.com"],
  "device": "mobile",
  "fullPage": true,
  "format": "jpeg",
  "removeCookieBanners": true,
  "hideSelectors": ["#intercom-container"]
}
```

#### Output example

```json
{
  "url": "https://www.bbc.com",
  "status": "ok",
  "error": null,
  "finalUrl": "https://www.bbc.com/",
  "title": "BBC Home - Breaking News, World News, US News, Sports, Business",
  "httpStatus": 200,
  "screenshotUrl": "https://api.apify.com/v2/key-value-stores/…/records/00001-bbc-com.jpg",
  "key": "00001-bbc-com.jpg",
  "bytes": 412331
}
```

### Pricing

Pay per event: one charge per page captured successfully. Failed pages (timeouts, DNS errors) are free. Set "Maximum cost per run" to cap spending — the Actor stops cleanly when it is reached.

### Notes

- Full-page captures are capped at 20,000 px tall to keep files usable.
- Sites with strong bot protection (some big news sites, marketplaces) may return a block page. Those rows get status `http-error` and are **not charged**; enable Apify residential proxy in the input to get through most of them.
- Only capture pages you are allowed to access. The Actor does not bypass logins or paywalls.

# Actor input Schema

## `urls` (type: `array`):

Pages to capture. One URL per line; https:// is added if missing.

## `device` (type: `string`):

Screen size and user agent to emulate. Tablet and mobile use touch, mobile user agents and retina resolution.

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

Capture the whole scrollable page instead of only the visible screen (capped at 20,000 px tall).

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

PNG is lossless, JPG is much smaller, PDF gives a printable A4 document of the page.

## `quality` (type: `integer`):

Only for JPG.

## `removeCookieBanners` (type: `boolean`):

Clicks 'Accept' on consent pop-ups (OneTrust, Cookiebot, Didomi, Quantcast, Usercentrics, Sourcepoint and generic ones, many languages) and hides any that remain.

## `scrollToLoad` (type: `boolean`):

Scrolls through the page before a full-page capture so lazy-loaded images appear.

## `blockAds` (type: `boolean`):

Blocks common ad, analytics and video requests. Pages load much faster and captures are cleaner; ad slots may appear empty.

## `darkMode` (type: `boolean`):

Emulates prefers-color-scheme: dark.

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

Optional, e.g. #pricing or .hero. Leave empty to capture the page.

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

Optional list of selectors to hide before capturing (chat widgets, ads, pop-ups).

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

When the page counts as loaded. "Page load" works for almost all sites; "Network idle" waits for all requests to finish.

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

Wait this long after loading, e.g. for animations.

## `timeoutSecs` (type: `integer`):

Give up on a page after this many seconds (not charged).

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

How many pages to capture at the same time. Automatically limited by the run memory (about 1 page per 1.5 GB).

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

Optional. Sites with bot protection (big news sites, marketplaces) may show a block page; Apify residential proxies usually get through. Block pages (HTTP 4xx/5xx) are not charged.

## Actor input object example

```json
{
  "urls": [
    "https://www.bbc.com",
    "https://apify.com"
  ],
  "device": "desktop",
  "fullPage": true,
  "format": "png",
  "quality": 80,
  "removeCookieBanners": true,
  "scrollToLoad": true,
  "blockAds": true,
  "darkMode": false,
  "waitUntil": "load",
  "delaySecs": 0,
  "timeoutSecs": 45,
  "maxConcurrency": 4,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `results` (type: `string`):

One row per URL with status, page title and download link.

## `files` (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 = {
    "urls": [
        "https://www.bbc.com",
        "https://apify.com"
    ],
    "proxyConfiguration": {
        "useApifyProxy": false
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("robinsiacreation/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 = {
    "urls": [
        "https://www.bbc.com",
        "https://apify.com",
    ],
    "proxyConfiguration": { "useApifyProxy": False },
}

# Run the Actor and wait for it to finish
run = client.actor("robinsiacreation/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 '{
  "urls": [
    "https://www.bbc.com",
    "https://apify.com"
  ],
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}' |
apify call robinsiacreation/website-screenshot-pdf --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,robinsiacreation/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/vQVWhp61vTgbKy7Nz/builds/HFJAD2JAqGz0FqJnn/openapi.json
