# Website Screenshot API: Full Page, Mobile & URL to PDF (`gmyri/website-screenshot`) Actor

Take full-page website screenshots in bulk: desktop or mobile, element capture, PNG, JPEG, WebP and URL to PDF, with cookie banners hidden. $1.50 per 1,000 screenshots.

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

## Pricing

from $1.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 API: Full Page, Mobile & URL to PDF

A **website screenshot API** for bulk captures: **full-page screenshots**, mobile and desktop presets, element screenshots, **URL to PDF**, PNG, JPEG or WebP, and cookie banners hidden automatically.

💲 **$1.50 per 1,000 screenshots** ($1 per 1,000 for the optional PDF). Failed pages are free. Pay only for results. No subscription, and the Apify free plan's monthly credit covers small jobs.

**Also known as:** website screenshot, full page screenshot, URL to image, URL to PDF, webpage to PDF, screenshot API, mobile screenshot, bulk screenshots.

### Quick start

1. Click **Start**. The prefilled input works as is.
2. Or paste this input (JSON tab):

```json
{
  "urls": [
    {
      "url": "https://apify.com"
    },
    {
      "url": "https://example.com"
    }
  ],
  "format": "webp",
  "fullPage": true,
  "device": "desktop"
}
```

**Output** (one dataset item):

```json
{
  "url": "https://example.com",
  "status": 200,
  "title": "Example Domain",
  "screenshotUrl": "https://api.apify.com/v2/key-value-stores/…/records/example.com-327c3fda87.webp",
  "widthPx": 1920,
  "heightPx": 1080,
  "format": "webp",
  "error": null
}
```

### Use it from the API, AI agents (MCP), n8n, Make or Zapier

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

- **AI agents / MCP:** connect `https://mcp.apify.com/?actors=gmyri/website-screenshot` to Claude, Cursor, ChatGPT or any MCP client. The input schema is fully described for tool calling.
- **Python:** `ApifyClient(token).actor("gmyri/website-screenshot").call(run_input={...})`
- **n8n / Make / Zapier:** use the Apify "Run Actor" action with `gmyri/website-screenshot`, then read the dataset items.

### Quick FAQ

- **Can it log in or bypass CAPTCHAs?** No. It captures public pages only and doesn't bypass logins, paywalls or bot protection. Pages that block it return an error and are not charged.
- **What if I set a spending limit?** The Actor stops cleanly at your *Max cost per run* and you're never charged above it.

### Details

Take **screenshots of any public web page** in bulk: full-page or viewport, desktop, laptop, tablet or mobile, a single element, PNG, JPEG or **WebP**, and optionally a **PDF** of the page. Each result has a public image link you can drop straight into a spreadsheet, a Slack message, an AI agent's context or a report.

**$1.50 per 1,000 screenshots.** Failed pages are free. No subscription, no API key to manage.

### Why use this screenshot API

- **Full-page that actually works.** It scrolls the page first so lazy-loaded images appear, then captures the whole page (very long pages are capped at a height you choose).
- **Clean shots.** Hides cookie and consent banners from OneTrust, Cookiebot, Didomi, Usercentrics, Quantcast and 20+ others with CSS. Nothing is clicked or accepted. You can also hide your own selectors, such as chat widgets.
- **Devices.** Desktop 1920×1080, laptop 1366×768, tablet (2×) and mobile (3×, iPhone user agent), or any custom viewport size.
- **Element screenshots.** Capture just `#pricing`, `main` or a chart.
- **Small files.** WebP is usually 3–5× smaller than PNG.
- **PDF export.** Print any page to an A4, Letter, Legal, A3 or Tabloid PDF.
- **Dark mode** (`prefers-color-scheme: dark`).
- **Built for automation and AI agents.** Predictable per-screenshot pricing, a flat JSON output and public file URLs.

### Typical uses

- Visual monitoring of your own sites and landing pages, scheduled daily, with screenshots kept in a dataset
- Competitor and ad landing page archives, SEO reports, client reports
- Thumbnails for directories, link previews and bookmarks
- Evidence and compliance snapshots (with timestamp and final URL)
- Giving AI agents "eyes": an agent calls the Actor and gets back an image URL it can pass to a vision model

### Input example

```json
{
  "urls": [{ "url": "https://apify.com" }, { "url": "https://example.com" }],
  "format": "webp",
  "fullPage": true,
  "device": "desktop",
  "hideCookieBanners": true,
  "delayMs": 1000,
  "savePdf": false
}
```

| Field | Default | What it does |
|---|---|---|
| `urls` | – | Pages to capture (full `https://` URLs) |
| `format` | `png` | `png`, `jpeg` or `webp` |
| `fullPage` | `true` | Whole page instead of the viewport |
| `device` | `desktop` | `desktop`, `laptop`, `tablet`, `mobile` |
| `viewportWidth` / `viewportHeight` | – | Custom size (overrides the device) |
| `selector` | – | CSS selector of one element to capture |
| `hideCookieBanners` | `true` | Hide common consent banners |
| `hideSelectors` | – | Extra CSS selectors to hide |
| `waitUntil` | `load` | `load`, `domcontentloaded` or `networkidle` |
| `delayMs` | 1000 | Extra wait before capturing |
| `scrollToBottom` | `true` | Trigger lazy-loaded images |
| `darkMode` | `false` | Emulate dark mode |
| `quality` | 80 | JPEG/WebP quality |
| `maxHeightPx` | 15000 | Cap for very long pages |
| `savePdf` / `pdfFormat` | `false` / `A4` | Also export a PDF |
| `timeoutSecs` | 45 | Per-page timeout |
| `maxConcurrency` | 3 | Pages in parallel |

### Output

One dataset item per URL:

```json
{
  "url": "https://example.com",
  "finalUrl": "https://example.com/",
  "status": 200,
  "title": "Example Domain",
  "screenshotUrl": "https://api.apify.com/v2/key-value-stores/…/records/example.com-327c3fda87.webp",
  "format": "webp", "widthPx": 1920, "heightPx": 1080, "bytes": 36548,
  "pdfUrl": null, "loadTimeMs": 1715, "device": "desktop", "error": null
}
```

The images (and PDFs) are stored in the run's key-value store. Failed pages get an `error` message and are **not charged**.

### Pricing (pay per event)

| Event | Price |
|---|---|
| Screenshot (primary) | **$0.0015** ($1.50 / 1,000) |
| PDF generated (only with `savePdf`) | $0.001 |
| Actor start | $0.00005 per run (Apify default) |

Platform usage is included. Set **Max cost per run** in the run options and the Actor stops cleanly at your limit.

### Use from AI agents (MCP), n8n, Make, Zapier and the API

- **MCP / AI agents:** add the Actor to the [Apify MCP server](https://mcp.apify.com) (`gmyri/website-screenshot`). Agents get a typed input schema and receive `screenshotUrl` links.
- **n8n / Make / Zapier:** use the Apify app's "Run Actor" action and map `screenshotUrl` from the dataset items.
- **API (sync):**
  ```bash
  curl -X POST "https://api.apify.com/v2/acts/gmyri~website-screenshot/run-sync-get-dataset-items?token=$APIFY_TOKEN" \
    -H 'Content-Type: application/json' -d '{"urls":[{"url":"https://example.com"}],"format":"webp"}'
  ```

### FAQ

**Can it log in or get past CAPTCHAs?** No. It captures publicly accessible pages only and does not bypass logins, paywalls or bot protection. Pages that block automated browsers return an error and are not charged.

**Why do some pages look different from my browser?** Geo-location, A/B tests and consent walls vary. Try `waitUntil: networkidle`, a longer `delayMs`, or hide the offending element with `hideSelectors`.

**How long are files kept?** As long as the run's storage is retained under your Apify plan. Download them or copy them to your own storage if you need them long-term.

**Is it legal?** Screenshots of public pages are generally fine for monitoring, archiving and reporting, but you are responsible for respecting each site's terms and copyright when you reuse the images.

### Related tools

- [Broken Link Checker & SEO Audit: 404s, Redirects, Sitemap](https://apify.com/gmyri/site-health-audit)
- [PDF to Markdown & Text Converter: Word, Excel, PPT, HTML, RAG](https://apify.com/gmyri/doc-to-markdown)
- [DNS Lookup & SSL Checker: SPF, DMARC, DKIM, Domain Expiry](https://apify.com/gmyri/domain-health-check)

# Actor input Schema

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

Public web pages to capture. One screenshot per URL. Use full URLs (https://...).

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

Output image format. JPEG and WebP use the quality setting.

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

Capture the whole scrollable page instead of just the visible viewport.

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

Viewport size, pixel density and user agent. Override the size with the viewport fields below.

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

Optional. Overrides the device preset width.

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

Optional. Overrides the device preset height.

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

CSS selector of a single element to capture (e.g. '#pricing' or 'main'). Leave empty for the page.

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

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

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

CSS selectors to hide before capturing, e.g. chat widgets or sticky headers.

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

Page-load event to wait for before capturing. 'networkidle' is best for heavy single-page apps but slower.

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

Extra wait after loading, for animations and late content.

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

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

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

Emulate prefers-color-scheme: dark.

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

1-100. Ignored for PNG.

## `maxHeightPx` (type: `integer`):

Very long pages are cut at this height (CSS pixels) to keep files usable.

## `savePdf` (type: `boolean`):

Also print each page to PDF (charged as a separate 'PDF generated' event).

## `pdfFormat` (type: `string`):

Paper size when 'Also save as PDF' is on.

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

Maximum time to load and capture one page.

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

Pages captured in parallel. Keep low (1-3) with 1-2 GB of memory.

## Actor input object example

```json
{
  "urls": [
    {
      "url": "https://apify.com"
    },
    {
      "url": "https://example.com"
    }
  ],
  "format": "png",
  "fullPage": true,
  "device": "desktop",
  "hideCookieBanners": true,
  "waitUntil": "load",
  "delayMs": 1000,
  "scrollToBottom": true,
  "darkMode": false,
  "quality": 80,
  "maxHeightPx": 15000,
  "savePdf": false,
  "pdfFormat": "A4",
  "timeoutSecs": 45,
  "maxConcurrency": 3
}
```

# Actor output Schema

## `screenshots` (type: `string`):

One item per URL with a public link to the image (and PDF), size and status.

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

All image and PDF files in the run's key-value store.

## `summary` (type: `string`):

OUTPUT record: ok/failed/pdf counts.

# 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": [
        {
            "url": "https://apify.com"
        },
        {
            "url": "https://example.com"
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("gmyri/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": [
        { "url": "https://apify.com" },
        { "url": "https://example.com" },
    ] }

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

```

## MCP server setup

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