Capture high-quality screenshots of any website with our powerful API. Configure viewports, wait conditions, blocking rules, and over 100+ advanced options for pixel-perfect results.
/v1/screenshotsCreate a new screenshot job. Screenshots are processed asynchronously in our queue system and typically complete in 10-60 seconds depending on the page complexity and configuration.
Base URL: https://www.snapshotai.dev
Asynchronous Processing
This endpoint creates a screenshot job and returns immediately. Use the returned id to check the status with GET /v1/screenshots/:id
Include your API key in the Authorization header:
Authorization: Bearer YOUR_API_KEYGet your API key from the Dashboard → API Keys
urlstringOptionalThe URL to capture. Can be provided at top level or within options object.
Example: https://example.com
optionsobjectOptionalComprehensive options object containing all capture parameters. See categories below.
Control the browser viewport size and device emulation
viewport_widthnumberOptionalBrowser viewport width in pixels
Default: 1920
Example: 1280
viewport_heightnumberOptionalBrowser viewport height in pixels
Default: 1080
Example: 720
device_scale_factornumberOptionalDevice pixel ratio for high-DPI displays
Default: 1
Example: 2
devicestringOptionalPreset device emulation (e.g., 'iphone_x', 'ipad_pro')
Example: iphone_14_pro
Configure output image format and quality
formatenumOptionalOutput image format: jpeg, png, or webp
Default: png
Example: jpeg
image_qualitynumberOptionalImage quality (0-100). Higher is better quality but larger file size
Default: 90
Example: 85
omit_backgroundbooleanOptionalMake the background transparent (PNG only)
Default: false
Example: true
Options for capturing entire scrollable pages
full_pagebooleanOptionalCapture the entire scrollable page
Default: false
Example: true
full_page_scrollbooleanOptionalScroll smoothly when capturing full page
Default: false
Example: true
full_page_scroll_delaynumberOptionalDelay between scrolls in milliseconds (0-10000)
Default: 0
Example: 100
full_page_max_heightnumberOptionalMaximum height for full page capture in pixels (1000-50000)
Default: 25000
Example: 30000
Control timing and page load waiting behavior
delaynumberOptionalWait time in milliseconds before capturing (0-60000)
Default: 0
Example: 2000
timeoutnumberOptionalMaximum time to wait for page load in milliseconds (1000-180000)
Default: 30000
Example: 45000
wait_for_selectorstringOptionalCSS selector to wait for before capturing
Example: .content-loaded
wait_untilarrayOptionalEvents to wait for: load, domcontentloaded, networkidle, commit
Example: ["load", "networkidle"]
Block ads, trackers, and unwanted content
block_adsbooleanOptionalBlock advertisements
Default: false
Example: true
block_cookie_bannersbooleanOptionalAutomatically dismiss cookie consent banners
Default: false
Example: true
block_trackersbooleanOptionalBlock tracking scripts
Default: false
Example: true
Inject custom CSS/JS and interact with the page
dark_modebooleanOptionalEnable dark mode if the website supports it
Default: false
Example: true
stylesstringOptionalCustom CSS to inject into the page
Example: body { font-size: 16px; }
scriptsstringOptionalCustom JavaScript to execute on the page
Example: document.querySelector('.popup').remove();
clickstringOptionalCSS selector to click before capturing
Example: #accept-cookies
Advanced Parameters
This API supports 100+ advanced parameters including geolocation, custom headers, cookies, proxy settings, and more. See our Advanced Options Guide for the complete list.
curl -X POST https://www.snapshotai.dev/api/v1/screenshots \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com"
}'curl -X POST https://www.snapshotai.dev/api/v1/screenshots \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"url": "https://example.com",
"options": {
"viewport_width": 1920,
"viewport_height": 1080,
"format": "jpeg",
"image_quality": 90,
"full_page": true,
"delay": 2000,
"wait_until": ["load", "networkidle"],
"block_ads": true,
"block_cookie_banners": true,
"dark_mode": false
}
}'const response = await fetch('https://www.snapshotai.dev/api/v1/screenshots', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
url: 'https://example.com',
options: {
viewport_width: 1920,
viewport_height: 1080,
full_page: true,
format: 'png',
block_ads: true
}
})
});
const data = await response.json();
console.log('Screenshot ID:', data.id);
console.log('Status:', data.status);import requests
url = "https://www.snapshotai.dev/api/v1/screenshots"
headers = {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json"
}
payload = {
"url": "https://example.com",
"options": {
"viewport_width": 1920,
"viewport_height": 1080,
"full_page": True,
"format": "png",
"block_ads": True
}
}
response = requests.post(url, json=payload, headers=headers)
data = response.json()
print(f"Screenshot ID: {data['id']}")
print(f"Status: {data['status']}"){
"id": "scr_2nX8Kp9mJ4dL7qR",
"url": "https://example.com",
"status": "pending",
"options": {
"viewport_width": 1920,
"viewport_height": 1080,
"format": "png",
"full_page": true
},
"created_at": "2025-11-04T23:30:15.123Z",
"estimated_time": "30-60s"
}Next Steps
id to check job statusGET /v1/screenshots/:id until status is "completed"download_url from the response