M
MesmerTools
Back to tools

Website Screenshot

Capture a screenshot of any website via API. Powered by Cloudflare Browser Rendering at the edge. Screenshots are cached for 1 hour. Rate limited to 10/hour.

REST API

GET/api/v1/screenshot
Pass ?url= with a full website URL. Optionally set ?width= and ?height= for custom viewport dimensions.

Parameters

urlrequiredFull website URL (e.g. https://github.com). Must include protocol.
widthViewport width in pixels. Default 1280. Range: 320-1920.
heightViewport height in pixels. Default 720. Range: 240-1080.

Example

curl "https://mesmer.tools/api/v1/screenshot?url=https://github.com"

Response

{
"url": "https://cdn.mesmer.tools/screenshots/api/abc123.jpg",
"width": 1280,
"height": 720,
"cached": false
}

How it works

Three steps to capture any website as an image.

Step 1
terminal
$ curl "/api/v1/screenshot
?url=https://github.com"

Send a URL

Make a GET request with the target URL. Optionally specify viewport dimensions for custom screenshot sizes.

Step 2
edge-us-east12ms
rendering...active
edge-eu-west8ms
edge-ap-south15ms
edge-sa-east22ms

We render at the edge

Cloudflare Browser Rendering spins up a headless browser at the nearest edge location and captures the page as a JPEG.

Step 3
{
"url": "/screenshots/...jpg",
"width": 1280,
"cached": false
}

Get your screenshot

Receive a JSON response with the CDN URL for your screenshot. Download it directly or embed the URL in your app.

Why use this API

A screenshot API built for developers who need reliable, fast captures without managing headless browser infrastructure.

330+ edge locations worldwide

Edge rendering

Runs on Cloudflare's global network with 330+ edge locations. Screenshots are captured close to the target server for minimal latency.

Cache hit: <5ms
1-hour TTL, R2-backed

Smart caching

Same URL and viewport returns a cached result instantly for 1 hour. Screenshots are stored on Cloudflare R2 and served from a CDN edge near you.

POST /browser-rendering
Mode: REST API
Billing: per-request

Cost optimized

Uses the Cloudflare Browser Rendering REST API instead of persistent Workers bindings. You only pay for browser hours actually used, not concurrent browser slots.

GET /api/v1/screenshot
?url=https://example.com
200 OK — JSON response

Simple integration

One GET request with a URL parameter. Returns a JSON object with the screenshot CDN URL. No API keys, no authentication, no SDKs required.

Common use cases

Whether you need thumbnails, visual checks, or archival snapshots, a screenshot API is the building block.

Link previews

Generate OG-style preview images for shared links. Show users a visual thumbnail of any URL before they click through, just like social media platforms do.

Used by link aggregators, social platforms, bookmarking tools, and any app that displays external URLs.

Monitoring

Run periodic visual regression checks for web apps. Compare screenshots over time to detect unexpected layout changes, broken pages, or deployment issues.

Used by QA teams, DevOps engineers, and site reliability teams tracking visual stability of production sites.

Content archival

Capture and store visual snapshots of web pages for records, compliance, or historical reference. Preserve the exact appearance of a page at a point in time.

Used by legal teams, compliance departments, researchers, and journalists preserving web content.