Mobile Website Screenshot API: iPhone, iPad and Android Viewports
Last updated:
URLBooth screenshots any public URL at a phone or tablet viewport when you pass a mobile device id, such as iphone-17-pro, ipad-air-11 or android. The page is laid out at that device’s exact CSS width and height, so responsive breakpoints and mobile styles apply.
What does device emulation do?
For each preset the browser is set to:
- the preset’s width and height in CSS pixels, matching the size the hardware reports;
- the preset’s device pixel ratio, 2x for every phone and tablet below, so the image is sharp (a 402 pixel wide viewport produces an 804 pixel wide image);
- mobile and touch mode, which turns on the mobile viewport behavior and touch input support;
- an iPhone, iPad or Android user agent string for the matching presets.
With fullPage the pixel ratio drops to 1x; see full-page screenshots. You can only choose from the presets; custom viewport sizes are not supported.
Which phone and tablet presets are available?
18 presets are touch devices. Pass the id as device. The same data, plus desktop and Mac presets, is in the device reference.
| Id | Device | Viewport | DPR |
|---|---|---|---|
| tablet | Tablet | 768 × 1024 | 2x |
| mobile | Mobile | 390 × 844 | 2x |
| iphone-17-pro-max | iPhone 17 Pro Max / 16 Pro Max | 440 × 956 | 2x |
| iphone-17-pro | iPhone 17 Pro / 17 / 16 Pro | 402 × 874 | 2x |
| iphone-air | iPhone Air | 420 × 912 | 2x |
| iphone-16-plus | iPhone 16 Plus / 15 Plus | 430 × 932 | 2x |
| iphone-16 | iPhone 16 / 15 / 15 Pro | 393 × 852 | 2x |
| iphone-16e | iPhone 16e / 14 / 13 | 390 × 844 | 2x |
| iphone-13-mini | iPhone 13 mini | 375 × 812 | 2x |
| iphone-se | iPhone SE | 375 × 667 | 2x |
| ipad-pro-13 | iPad Pro 13″ | 1032 × 1376 | 2x |
| ipad-pro-11 | iPad Pro 11″ | 834 × 1210 | 2x |
| ipad-air-13 | iPad Air 13″ | 1024 × 1366 | 2x |
| ipad-air-11 | iPad Air 11″ / iPad | 820 × 1180 | 2x |
| ipad-mini | iPad mini | 744 × 1133 | 2x |
| ipad-classic | iPad 9th gen | 810 × 1080 | 2x |
| android | Android phone | 412 × 915 | 2x |
| android-compact | Android compact | 360 × 800 | 2x |
Which preset should I choose?
Pick the viewport you want to test, not the exact model. Several labels cover more than one phone because they share a viewport, for example iphone-17-pro also matches the iPhone 17 and 16 Pro. Use android-compact for a narrow 360 pixel Android layout, iphone-se for the smallest iPhone, andipad-pro-13 for the largest tablet. All presets are portrait; there is no landscape or rotation option. Test the widths your own CSS breakpoints care about, and compare each against a desktop capture of the same URL.
How do I capture the same page on desktop and on a phone?
Send two requests that differ only in device. Both use the default PNG format and have cleanup on.
curl --fail-with-body "https://urlbooth.com/v1/screenshots" \-H "Authorization: Bearer $URLBOOTH_API_KEY" \-H "Content-Type: application/json" \-d '{"url":"https://example.com","device":"desktop"}' \-o desktop.png
curl --fail-with-body "https://urlbooth.com/v1/screenshots" \-H "Authorization: Bearer $URLBOOTH_API_KEY" \-H "Content-Type: application/json" \-d '{"url":"https://example.com","device":"iphone-17-pro"}' \-o iphone.png
The API needs a Pro plan at $20 per month; see pricing and the options reference. A step-by-step intro is in how to take a website screenshot with an API.
Can I put the phone screenshot in a device frame?
Yes. Add "frame": true for a mockup in an iPhone, iPad or Android frame; see device frame screenshots. Cookie banners and ads are removed by default, which matters most on small screens where a banner can cover half the page; see cookie banner removal.
Limits and caveats
- This is viewport emulation in a Chromium-based browser (Cloudflare Browser Run), not a real iPhone or real Safari. iPhone and iPad presets send a Safari user agent, but the rendering engine is Chromium, so engine-specific behavior can differ from a real device.
- Sites that choose layouts by user agent, or that block automated browsers, may show something different from a real phone.
- The output is a still image of the first screen unless you set
fullPage. - Plan limits apply: 10,000 a day, 60 a minute and 10 at once, with images stored for 2 days. See the API reference.