Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Set the page’s mobile-sized viewport before navigating, then capture it with Puppeteer’s Page.screenshot(). Use Page.setViewport() when you need particular CSS-pixel dimensions; use device emulation when you also need a named device’s user agent and metrics.

Capture a page at a chosen mobile viewport size

This example uses 390 × 844 CSS pixels as illustrative inputs, not as a specification for any particular phone. Replace them with the dimensions your test or design requires.

import puppeteer from 'puppeteer';

const browser = await puppeteer.launch();
try {
  const page = await browser.newPage();

  await page.setViewport({
    width: 390,
    height: 844,
    deviceScaleFactor: 1,
  });

  await page.goto('https://example.com');
  await page.screenshot({path: 'mobile.png'});
} finally {
  await browser.close();
}

The sequence matters: create a page, set its viewport, navigate, capture, and close the browser. Puppeteer’s viewport documentation advises setting the viewport before navigation because some websites do not expect phones to change size. See Page.setViewport() and the Puppeteer screenshot guide.

Choose dimensions or emulate a device

Approach Use it when What it configures Consideration
Page.setViewport() You need a specific viewport width and height. Viewport dimensions and, optionally, device scale factor. It does not by itself provide a device-specific user agent.
Page.emulate(device) You need to target a named device preset. Device metrics and user agent; Puppeteer documents it as a shortcut for setting the user agent and viewport. Mobile or touch-related viewport changes can reload a page in some cases.

The topic does not specify a phone model, device pixel ratio, user-agent requirement, or browser version. Choose those to match your test target rather than treating one dimension pair as universal. Puppeteer documents device emulation in Page.emulate().

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Smartphone Holder/Vertical and Horizontal Tripod Mount Adapter
  • FEATURE: the tripod phone mount is adjustable by screw mechanism, 360 degree rotating, vertical(portrait mode) and horizontal(landscape mode) or any angle as you need, not necessary to take your cell phone out of a standard tripod or small tripod.
  • EASY TO USE: two options for using tripod phone holder: 1. screw it directly to the tripod or selfie stick with pivoting arm, being able to 360 degrees rotating, 2. remove the phone clamp from pivoting arm and then mount on a tripod or monopod.
  • ADJUSTABLE WIDTH: 2.2inch-4.1inch(55mm-105mm), attachable to any regular-size smartphone, tripod, selfie stick, monopod or camera; two standard 1/4 x 20mm female thread interfaces meeting your various needs. Very functional and compact.
  • MATERIAL: the black part made of sturdy plastic, the female threads inserted are brass, the male screw is steel and soft non-slipping silica gel pads, which protect your cellphone from scratch and hold the phone securely.
  • ATTACHABLE TO: most mobile phones, tripods, unipods, selfie sticks, cameras, camcorders, pico projectors, including iPhone 11/11 Pro/11 Pro Max/X/XS/XR/XS Max/8/7/6/6s Plus/SE/5s/5/5c, Samsung Galaxy S10/10+/S9/S9+/S8/S8+/S7/S6/S6 edge, Note10/10+/9/8 and Android phones.

Emulate a named device

When the target is a specific preset, import KnownDevices and emulate it before navigating:

import puppeteer, {KnownDevices} from 'puppeteer';

const browser = await puppeteer.launch();
try {
  const page = await browser.newPage();
  await page.emulate(KnownDevices['iPhone 17 Pro']);
  await page.goto('https://example.com');
  await page.screenshot({path: 'device.png'});
} finally {
  await browser.close();
}

Decide whether you need a viewport screenshot or a full-page capture

A mobile viewport screenshot represents the visible page area at the configured dimensions. If you need the entire document rather than the visible viewport, consult the current Page.screenshot() options and select the capture extent deliberately. The dimensions alone do not determine whether the output should include the full page.

Rank #2
SYNCWIRE Tripod Phone Mount, Universal Smartphone Mount Adapter with 2 Cold Shoe and 1/4" Screw, 360° Rotates and 180° Tilts Adjustable Cell Phone Clamp Holder for Enhancing Mobile Photography Setup
  • Dual Cold Shoe Mounts: Attach microphones, lights, and accessories for enhanced photography or vlogging.
  • Versatile Screw Design: 1/4" screw hole compatible with tripods, selfie sticks, cameras, and various accessories.
  • 360° Rotation, 180° Tilt: Effortlessly switch between landscape and portrait mode with adjustable angle design for precise control.
  • Universal Phone Compatibility: Fits smartphones from iPhone 14 to Galaxy S23 Ultra, accommodating devices within 2.16" to 3.7" width. For best results, avoid clamping directly on the side buttons. Adjust the position slightly higher or lower if your phone has thick cases or protruding buttons.
  • Secure Grip: Thick non-slip silicone pad ensures stability even with a thick phone case.

Check the viewport configuration

Page.viewport() reports Puppeteer’s configured viewport; it is not an independent measurement of the browser’s actual rendered viewport. Use it to inspect the configuration you set, not as proof that a page rendered exactly as intended. See the Page class documentation.

Common problems and fixes

  • The screenshot has desktop layout. Confirm setViewport() runs before page.goto(). If mobile-specific user-agent or device metrics matter, use a named device preset with page.emulate() before navigation.
  • The page reloads after changing mobile or touch settings. Puppeteer notes that changing mobile or touch properties can trigger a reload in some cases. Configure the target before navigation to avoid changing those settings mid-page.
  • The image is cropped to the visible area. The requested output may be a viewport capture. Check the current Page.screenshot() documentation and configure full-page capture if you need the whole document.
  • The result does not match a particular phone. Width and height alone do not define a device. Confirm whether your target requires a specific preset, user agent, or device scale factor, then configure those before loading the site.

Or skip the browser setup

ScreenshotNeo can return a screenshot or PDF from one GET request. For example, save a WebP screenshot of a page with this cURL call (replace the URL as needed):

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Sale
Metal Phone Tripod Mount 3 Cold Shoes & Arca Port, 360° Smartphone Tripod
  • 🏆【Latest Metal Phone Tripod Mount】: 360° rotation smartphone holder with 2 side cold shoe and 1 back cold shoe & 1/4" Expand Hole Design, you can attach additional LED light, microphone or other film device. It helps you film steady vlogging video for Facebook, Youtube, and platforms as well as live streaming channels.
  • 🏆【Back Cold Shoe & Two 1/4" Expand Hole Design】: There is a cold shoe on the back, which solves the problem that the wireless microphone cannot be fixed during mobile phone recording. Two 1/4" screw hole help you expand the devices you want.
  • 🏆【Standard Arca Mount on Bottom】- ULANZI Iron Man IV with a standard Aka quick release plate port, quick installation. A 1/4 screw port is added at the bottom to connect tripods. It is all aluminum metal made. Solid, Durable and Safer.
  • 🏆【Side Double Cold Shoe Design】: ULANZI ST-27 with 2 cold shoes on the side, you can mount your fill light & microphone at same time. It is be the best choice for your vlog.
  • 🏆【Extra Wide Compatibility】: Ulanzi phone tripod mount compatible with iPhone17 16 15 14 13 12/12Pro/12Pro Max/11/11Pro/11Pro Max/X/Xs/XR/Xs Max,8/7/6/6s, iPhone 6/6s plus, iphone SE,Samsung Galaxy s10s10 plus S9/S9+,S8/S8+/S7/S6/S6 edge, Note 10 9 8 5 4 3 and many other brands and models
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

See the ScreenshotNeo API documentation for request options. It removes cookie banners, newsletter popups, and chat widgets before capture; bot checks, blank pages, failed loads, timeouts, and cache hits are not billed. An MCP server lets AI agents take screenshots, and the Free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000. Sign up for ScreenshotNeo free.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Frequently Asked Questions

Does setting the viewport guarantee the page will behave exactly like a phone?

No. A viewport sets dimensions, while device emulation also applies a preset’s device metrics and user agent. Neither should be treated as a guarantee that every aspect of a physical phone is reproduced.

What does Puppeteer’s `Page.viewport()` tell me?

It reports the page’s configured viewport; it does not independently verify the actual rendered viewport.

Quick Recap

Bestseller No. 2
SYNCWIRE Tripod Phone Mount, Universal Smartphone Mount Adapter with 2 Cold Shoe and 1/4' Screw, 360° Rotates and 180° Tilts Adjustable Cell Phone Clamp Holder for Enhancing Mobile Photography Setup
SYNCWIRE Tripod Phone Mount, Universal Smartphone Mount Adapter with 2 Cold Shoe and 1/4" Screw, 360° Rotates and 180° Tilts Adjustable Cell Phone Clamp Holder for Enhancing Mobile Photography Setup
Secure Grip: Thick non-slip silicone pad ensures stability even with a thick phone case.; Compact and Lightweight: Weighing only 54g, perfect for on-the-go photography and storage.
$9.99
Bestseller No. 5
SMALLRIG Universal Phone Holder Mount with Cold Shoe - 4382
SMALLRIG Universal Phone Holder Mount with Cold Shoe - 4382
Package Included: phone holder x 1. Please note that the load capacity is 500g
Best Value
SMALLRIG Universal Phone Holder Mount with Cold Shoe - 4382
  • Universal Phone Holder: This multifunctional phone clamp can be mounted on the top of a camera or tripod through 1/4"-20 threaded hole or cold shoe at the bottom for photography, live-streaming, vlogging, interviews, etc
  • Support Landscape and Portrait Modes: The phone holder can be quick switching between landscape and portrait modes, and securely lock when rotated to 90° degrees. Two rotary joints supports 180 degrees adjustment
  • Universal Compatibility: It supports smartphones with a width of 57-88mm / 2.5-3.5in (for Samsung, for iPhone 18 / 18 Pro / 18 Pro Max / 17 /17 Pro/17 Pro Max/16/16 Pro/16 Pro Max/15/15 Pro /15 Pro Max / for iPhone 14/14 Pro /14 Pro Max / for iPhone 13 /13 Pro /13 Pro Max / for iPhone 12 Pro Max and so on)
  • Threaded Holes & Cold Shoe: Designed with well-spaced threaded holes to facilitate the installation of power bank holders (ID: 2336 / 2790). There is a cold shoe mount on top for microphone or light
  • Package Included: phone holder x 1. Please note that the load capacity is 500g
Rank #4
Sale
Liphisy 64” Tripod for Cell Phone & Camera with Remote and Phone Holder
  • 【Sturdy and Stable】: Made of premium aluminum alloy and stainless steel, Liphisy phone tripod with remote keeps your device stay securely in place for still shots and video recording.
  • 【Multi-angle Shot】: With a max height of 64”, this tripod stand with a 210-degree rotation head and 360-degree rotation holder allows you to capture shots from any angle, catering to different photography needs.
  • 【Wireless Remote Included】: Package includes a wireless remote that connects to your cell phone easily, making it a breeze to snap photos or video recordings.
  • 【Height Adjustable】: The height of this cell phone tripod with remote can be adjusted from 17” to 64” and the easy lock mechanism makes it really easy to set up. It gives you an excellent vantage point for capturing photos and videos.
  • 【Wide Application】: Compatable with different phone and camera, this tripod is great for photography and video recording, perfect for travel and home use.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.