# Website Screenshot: full page, mobile, PNG/JPEG/PDF (`kvnloo/website-screenshot`) Actor

Screenshot any public URL as PNG, JPEG or PDF: full page or viewport, desktop, tablet or mobile, dark mode, cookie banners hidden. Per-URL timeouts, failed pages free. $0.80 per 1,000 screenshots, platform usage included.

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

## Pricing

from $0.60 / 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.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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: full page, mobile, PNG, JPEG and PDF

Screenshot any public web page by URL. Choose PNG, JPEG or PDF, the visible viewport or the full scrollable page, and a desktop, laptop, Full HD, tablet, iPhone or Android viewport. Cookie consent banners are hidden automatically. Each screenshot is saved to the run's key-value store, and its download link goes to the dataset, together with the HTTP status, page title, real image size and file size.

### Why use this Actor

- **Platform usage included.** $0.80 per 1,000 screenshots on the Free plan, $0.60 on Gold and higher Apify plans. You are not billed separately for memory or compute.
- **Failed pages are free.** A page that never answers, a DNS error, or an HTTP 4xx/5xx page costs nothing; you get a row explaining why.
- **No run-wide time-outs from one slow site.** Every URL has its own time limit. A page whose ads or trackers never finish loading is still captured as rendered and flagged `loadTimedOut`, instead of stalling the run.
- **Clean shots.** Common consent banners (OneTrust, Cookiebot, Usercentrics, Didomi, Quantcast and others) are hidden with CSS. Nothing is clicked or accepted for you. You can also hide your own selectors, such as chat widgets.
- **Real devices.** The tablet, iPhone 15 and Pixel 7 presets use the device's pixel ratio, touch support and mobile user agent, so you get the mobile layout at retina resolution.
- **Verified output.** `width` and `height` are read from the stored image itself, not from the request.

### Input example

```json
{
  "urls": ["https://example.com/", "https://www.python.org/"],
  "format": "png",
  "fullPage": false,
  "device": "desktop"
}
```

Other options: `viewportWidth`, `viewportHeight`, `quality` (JPEG), `waitUntil` (`load`, `domcontentloaded`, `networkidle`), `delayMs` (default 500 ms, so sliders and fade-ins paint), `waitForSelector`, `scrollToBottom` (loads lazy images), `hideCookieBanners`, `hideSelectors`, `darkMode`, `timeoutSecs` (default 20 s per step) and `concurrency` (default 2). If you leave `urls` empty, the Actor screenshots the built-in example.

### Output example

```json
{
  "url": "https://www.python.org/",
  "finalUrl": "https://www.python.org/",
  "statusCode": 200,
  "title": "Welcome to Python.org",
  "format": "png",
  "width": 1280,
  "height": 800,
  "bytes": 110114,
  "screenshotKey": "screenshot-0001-www.python.org-1ab11d99",
  "screenshotUrl": "https://api.apify.com/v2/key-value-stores/<storeId>/records/screenshot-0001-www.python.org-1ab11d99",
  "charged": true,
  "loadTimedOut": false,
  "durationMs": 518,
  "takenAt": "2026-11-15T17:15:00+00:00",
  "error": null
}
```

The Dataset tab shows the screenshots as image previews. Download the files from `screenshotUrl`, or from the run's key-value store.

### Pricing

Pay per event:

| Event | Free / Bronze | Silver | Gold | Platinum | Diamond |
|---|---|---|---|---|---|
| Screenshot (page loaded with HTTP status below 400) | $0.0008 | $0.0007 | $0.0006 | $0.0006 | $0.0006 |
| Actor start, per GB of memory | $0.00005 | | | | |

Error rows and 4xx/5xx pages are free. The default 1 GB with 2 parallel pages handles typical batches well (20 sites in about 28 s). More parallel pages share the same CPU, and each batch waits for its slowest page. Memory does not change the screenshot price; only the start event counts per GB. To cap the cost of a run, set **Maximum cost per run**; the Actor stops cleanly at the cap.

### How it compares

| | This Actor | Free open-source screenshot Actor | Typical paid screenshot Actors |
|---|---|---|---|
| Price per 1,000, Free plan | $0.80, platform usage included | Free Actor; you pay platform usage at a 2 GB default | $0.89 to $10, some plus usage |
| Price per 1,000, Gold plan | $0.60 | same | from $0.61 |
| Formats | PNG, JPEG, PDF | PNG, PDF | Varies |
| Full page, viewport height, device presets | Yes | Width only, scroll option | Varies |
| Slow page | Per-URL limit; captured as rendered | Can time out the run | Varies |
| Cookie banners hidden | Yes, CSS only | Manual selectors | Some |
| Failed pages | Free, with the reason | n/a | Often charged |

### FAQ

**Can it screenshot pages behind a login?**
No. It only opens public URLs, and it does not use cookies, proxies or anti-bot workarounds. Respect each website's terms of use.

**Why is a page cut at 16,384 pixels?**
That is Chromium's limit for a single image. Taller pages are captured from the top down to that height.

**Why does a mobile screenshot look wide?**
A page without a mobile viewport tag renders at 980 px on phones, as in a real phone browser.

**Can I run it on a schedule?**
Yes. Create a task with your URLs and add a schedule to track visual changes over time. Each run's screenshots stay in its key-value store.

**What does `charged: false` with a screenshot mean?**
The page answered with an HTTP 4xx or 5xx status. You still get the screenshot, for free.

# Actor input Schema

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

Public http(s) pages to screenshot (up to 1,000). A bare domain such as example.com gets https://. localhost and private IP addresses are rejected. Leave empty to screenshot the built-in example (example.com and python.org).

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

PNG (lossless), JPEG (smaller files; see Quality) or PDF (the page rendered at the viewport width with backgrounds).

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

Capture the whole scrollable page instead of the visible viewport. Pages taller than 16,384 px are cut at that height.

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

Viewport preset. Tablet and mobile presets use the device's size, pixel ratio, touch and mobile user agent.

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

Overrides the device width (240-3840).

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

Overrides the device height (240-4320).

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

1-100, used only for JPEG.

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

Page event to wait for before capturing. networkidle waits until no requests for 500 ms (slower, best for JavaScript-heavy pages).

## `delayMs` (type: `integer`):

Wait this long after the page is ready, for animations, sliders and late content (0-10000). The default 500 ms lets JavaScript carousels and fade-ins paint.

## `waitForSelector` (type: `string`):

Optional CSS selector that must be visible before the screenshot.

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

Scroll through the page first so lazy-loaded images appear (useful with Full page).

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

Time limit for each page step (5-120). A page that never answers becomes an error row (not charged); a page whose late resources never finish loading is captured as rendered and flagged loadTimedOut. The run always continues.

## `hideCookieBanners` (type: `boolean`):

Hide common consent banners (OneTrust, Cookiebot, Usercentrics, Didomi, Quantcast and others) with CSS. Nothing is clicked or accepted.

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

CSS selectors of elements to hide, such as chat widgets or ads.

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

Emulate prefers-color-scheme: dark.

## `concurrency` (type: `integer`):

Pages captured at the same time (1-5). 2 is fastest at the default 1 GB; more pages share the same CPU and each batch waits for its slowest page.

## Actor input object example

```json
{
  "urls": [
    "https://example.com/",
    "https://www.python.org/"
  ],
  "format": "png",
  "fullPage": false,
  "device": "desktop",
  "quality": 80,
  "waitUntil": "load",
  "delayMs": 500,
  "scrollToBottom": false,
  "timeoutSecs": 20,
  "hideCookieBanners": true,
  "hideSelectors": [],
  "darkMode": false,
  "concurrency": 2
}
```

# Actor output Schema

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

No description

## `summary` (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://example.com/",
        "https://www.python.org/"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("kvnloo/website-screenshot").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://example.com/",
        "https://www.python.org/",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("kvnloo/website-screenshot").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://example.com/",
    "https://www.python.org/"
  ]
}' |
apify call kvnloo/website-screenshot --silent --output-dataset

```

## MCP server setup

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

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/3iMlu1pVHclJ2O56z/builds/AZfcOR5BOJ6tPKi3Q/openapi.json
