How to take full-page and mobile screenshots of hundreds of URLs at once
Screenshotting one page is a keyboard shortcut. Screenshotting 300 landing pages every morning, on desktop and mobile, full height, without cookie banners covering half of each image, is a small project. Here is what ac
Screenshotting one page is a keyboard shortcut. Screenshotting 300 landing pages every morning, on desktop and mobile, full height, without cookie banners covering half of each image, is a small project.
Here is what actually matters when you do it in bulk.
1. Use a real browser, but don't wait for every last tracker
JavaScript-heavy pages only render properly in headless Chromium. But waiting for networkidle on a page full of ad scripts can hang for a minute. Open the page when the HTML is ready, wait for load with a cap (10 s works), and block analytics / ad / chat scripts: the page looks the same and loads faster.
2. Scroll before a full-page capture
Lazy-loaded images below the fold stay blank unless you scroll to the bottom first. Also cap the height (15,000 px is sane), or a page with infinite scroll gives you a 200 MB PNG.
3. Hide consent banners with CSS, don't click them
Clicking "Accept" on someone's site is a choice you shouldn't make for them, and it is slow. Hiding the common consent tools with CSS gives a clean image without accepting anything.
4. Keep status codes next to the images
A screenshot of a 404 or a "403 Access denied" looks like a success unless you store the HTTP status with it. Keep statusCode, title and finalUrl on the same row as the image link.
Example output
Real rows from a 3-URL run (desktop 1280x800, PNG), 3.7 s of crawling:
| URL | Title | Status | Bytes | Load ms |
|---|---|---|---|---|
| https://www.python.org/ | Welcome to Python.org | 200 | 136,831 | 2,196 |
| https://apify.com/ | Apify: Marketplace of ready-to-run tools for AI | 200 | 162,572 | 3,306 |
| https://en.wikipedia.org/wiki/Web_scraping | Web scraping - Wikipedia | 200 | 226,374 | 1,006 |
Each row also has screenshotUrl (direct image link), device, viewportWidth / viewportHeight, imageWidth, pageHeightCss, heightTruncated and takenAt.
I run these with my Website Screenshot API ($0.40 per 1,000 screenshots plus Apify usage, no start fee; failed URLs and 4xx/5xx pages are never charged). Desktop, laptop, Full HD, tablet and mobile presets, dark mode, PNG or JPEG. Full-page mobile input:
{
"urls": ["https://stripe.com", "https://vercel.com"],
"device": "mobile",
"fullPage": true,
"hideSelectors": [".intercom-launcher"]
}
From Python:
# pip install apify-client
from apify_client import ApifyClient
client = ApifyClient("YOUR_APIFY_TOKEN")
run = client.actor("rel8ble/website-screenshot-api").call(run_input={
"urls": ["https://stripe.com", "https://vercel.com"],
"device": "mobile",
"fullPage": True
})
for row in client.dataset(run["defaultDatasetId"]).iterate_items():
print(row["statusCode"], row["url"], row["screenshotUrl"])
For thumbnails, use "format": "jpeg", "quality": 60: 3-5x smaller than PNG. For daily visual monitoring, save the input as an Apify task with a schedule and compare bytes day to day as a cheap "something changed" signal.
Limits: public pages only (no logins), and a few big shops block data-centre IPs; for those, turn on a residential proxy.
Using Claude, Cursor or another MCP client? Add https://mcp.apify.com?tools=rel8ble/website-screenshot-api as a remote MCP server and ask in plain English.
Disclosure: I built and maintain this actor; it is a paid Apify actor (pay per result, Apify's free plan credit covers small tests). The sample rows above are real output from a test run.
Originally published by Dev.to WebDev. Aggregated on AIWithGhost for educational purposes — full credit and traffic to the original publisher.