Do these 3 things before closing this tab:
1Clear out junk files and repair common Windows errors2Fix the driver behind crashes, sound loss and screen glitches3Repair Windows errors before they cause bigger problemsUse Chrome’s mobile-emulation capability before creating the Selenium WebDriver session. Choose a named device profile when you want a familiar preset, or provide custom viewport dimensions and pixel ratio when your test must state its assumptions explicitly. Then navigate, wait for the page to become stable, and call your language binding’s screenshot method.
This produces a mobile-emulated Chrome screenshot for responsive-layout checks. It does not demonstrate identical behavior on a physical iPhone or Android browser; use a real device or platform simulator when operating-system, hardware, native browser, or device-specific behavior is the subject of the test.
What Selenium mobile emulation changes
Chrome mobile emulation changes the browser context used by the page. Depending on the options exposed by your Selenium binding, you can control viewport width, viewport height, device pixel ratio, user agent, and touch behavior. Responsive CSS media queries and JavaScript viewport checks then receive mobile-oriented values.
Emulation is therefore well suited to repeatable screenshot checks such as verifying a navigation collapse, card stacking, breakpoint transition, or image sizing. It is not a hardware simulation. It cannot establish how Safari on iOS, Android system rendering, a particular GPU, or an on-device browser handles a feature.
#1 Best Overall
- 【Strong Adsorption】The inspiration of the silicone phone suction case comes from the adhesive force of the octopus. Each suction cup phone mount is 3.15 inches long and 2.17 inches wide, with 24 independent suction cups providing a stronger and more stable suction force, so you don't have to worry about your phone falling during use.
- 【Back of Phone Suction Grip】Remove the adhesive film on the phone suction cup and stick it on the phone case. You can then fix the phone on any smooth surface, which is very convenient. (The phone suction cup cannot be removed and reused after being attached to the phone case. It is recommended to attach it to a regular phone case, not a valuable one.)
- 【Widely Used】Our non-slip silicone phone sticky grip mount attaches to almost any flat phone case and make it compatible with common mobile phones such as iPhone and Android.You can shoot, watch videos or video calls in the kitchen, gym, dance studio, bathroom and other places.
- 【Capture the Wonderful Picture】Whether you are a TikTok creator or just like to share videos and photos, this phone suction cup can help you hands-free capture wonderful videos and photos for sharing with friends.
- 【Note】You can fix the phone suction cup on a smooth surface such as a mirror or glass. If necessary, wipe the suction cup with a damp cloth to obtain stronger suction. Before releasing your hand, make sure the phone is firmly fixed. (Not applicable to rough walls, wooden surfaces, and other uneven surfaces)
Prerequisites and version checks
- Install Selenium for the language you will use and a Chrome or Chromium installation.
- Use a ChromeDriver major version that matches the Chrome major version. Selenium’s Chrome documentation states that Selenium 4 is compatible with Chrome 75 and later by default, while advising that Chrome and ChromeDriver major versions match; verify the versions in your own environment rather than treating that baseline as a guarantee.
- Use a current Selenium binding. Option names and screenshot behavior are binding-specific and can change with browser releases.
Python: complete mobile-emulated screenshot
The following script uses a custom profile so the viewport assumptions are visible in the test. The values are an example, not a claim about a particular handset.
from pathlib import Path
from selenium import webdriver
from selenium.webdriver.chrome.options import Options
from selenium.webdriver.support.ui import WebDriverWait
TARGET = "https://example.com"
options = Options()
options.add_experimental_option("mobileEmulation", {
"deviceMetrics": {
"width": 360,
"height": 640,
"pixelRatio": 3.0
},
# Add a userAgent here only when your test requires one.
# "userAgent": "..."
})
# Create the session only after mobileEmulation has been configured.
driver = webdriver.Chrome(options=options)
try:
driver.get(TARGET)
WebDriverWait(driver, 30).until(
lambda d: d.execute_script("return document.readyState") == "complete"
)
# Replace this with an application-specific readiness condition when needed.
driver.save_screenshot("mobile-emulated.png")
finally:
driver.quit()
save_screenshot writes the image using the Python binding’s documented screenshot behavior. Do not assume that every binding produces the same format or that a viewport screenshot is automatically a full-page capture.
Use a named device profile
Chrome also accepts a device-name profile supported by the browser’s DevTools device list:
options = Options()
options.add_experimental_option("mobileEmulation", {
"deviceName": "Nexus 5"
})
driver = webdriver.Chrome(options=options)
The profile name must be valid for the Chrome/driver combination running your test. Device lists and accepted names are version-sensitive, so check the current browser documentation before pinning one in CI.
JavaScript: configure emulation with Chromium options
In Selenium’s JavaScript API, the documented method is setMobileEmulation. Set it before constructing the driver:
Rank #2
- SUPERIOR COMFORT — Unlike traditional circular ear buds, the design of EarPods is defined by the geometry of the ear. Which makes them more comfortable for more people than any other ear bud–style headphones.
- HIGH-QUALITY AUDIO — The speakers inside EarPods have been engineered to maximize sound output and minimize sound loss, which means you get high-quality audio.
- BUILT-IN REMOTE — EarPods with USB-C plug also include a built-in remote that lets you adjust the volume, control the playback of music and video, and answer or end calls with a pinch of the cord.
- COMPATIBILITY — Works with all devices that have a USB-C port.
- INTEGRATED MICROPHONE — A built-in microphone precisely captures your voice while you’re on the phone, taking a FaceTime call, or summoning Siri — so you’re always heard loud and clear.
const {Builder} = require('selenium-webdriver');
const chrome = require('selenium-webdriver/chrome');
(async function () {
const options = new chrome.Options();
options.setMobileEmulation({
deviceMetrics: {width: 360, height: 640, pixelRatio: 3.0}
});
const driver = await new Builder()
.forBrowser('chrome')
.setChromeOptions(options)
.build();
try {
await driver.get('https://example.com');
await driver.executeAsyncScript((done) => {
if (document.readyState === 'complete') return done();
window.addEventListener('load', () => done(), {once: true});
});
await driver.takeScreenshot().then(data =>
require('fs').writeFileSync('mobile-emulated.png', data, 'base64'));
} finally {
await driver.quit();
}
})();
Bindings differ: consult the API reference for the exact screenshot method, profile syntax, and support for user-agent or touch settings.
Named profile or custom metrics?
| Approach | Strength | Trade-off | Best use |
|---|---|---|---|
| Named device profile | Quick setup with a recognizable preset | Depends on profile availability and browser-version naming | Smoke checks aimed at a known DevTools preset |
| Custom device metrics | Explicit width, height, and pixel ratio recorded in the test | You must choose and maintain the assumptions yourself | Reproducible visual regression and breakpoint tests |
Neither approach supplies full physical-device fidelity. A pixel ratio of 3.0, for example, sets an emulated metric; it does not reproduce every characteristic of a real high-density display.
Wait for the state you actually want to capture
A completed navigation is not necessarily a visually ready page. Add a condition that matches the application:
- Wait for
document.readyStateto becomecompletefor basic documents. - Wait for a key element (such as the rendered dashboard) to be visible or populated.
- Wait for a known loading indicator to disappear.
- Wait for fonts, images, or client-side data when those assets affect the pixels.
Use an explicit timeout and fail the test when readiness is not reached. Avoid arbitrary sleeps unless a third-party animation or delayed transition genuinely requires one; if you use a delay, document why.
Touch, user-agent, and other controls
The available controls depend on the binding. Selenium’s .NET Chromium API documents dimensions, pixel ratio, UserAgent, and EnableTouchEvents; that API’s touch setting defaults to true. Do not generalize that default to Python, Java, or JavaScript without checking the corresponding reference. Configure a user agent only when the behavior under test depends on it, because changing it can select different server-side content and make results harder to compare.
Rank #3
- Secure Hold: Our PopSockets adhesive phone grip gives your cell phone a secure, comfortable hold in hand to help prevent drops while texting, taking photos, or scrolling on the go. Designed to stick firmly to most phone cases and devices.
- Hands-Free Made Easy: Easily turn your PopSocket into a phone stand to prop up your phone anywhere — perfect for watching videos, video calls, or following recipes. A must-have phone holder that keeps your device secure and ready for anything.
- Compatibility: Works with all phones, tablets, and Kindles. Sticks best to smooth, hard plastic cases and may not adhere to silicone or textured cases. Easily swap your PopTop to change up your style — just close the grip, press down, twist 90°, and snap on a new top.
- Black PopSockets: Simple, refined, and endlessly versatile — a timeless essential for any phone.
- PopSockets Ecosystem: Mix and match your favorite PopSockets products — from grips and wallets to cases and mounts — all designed to work together seamlessly.
Full-page and element screenshots
Screenshot APIs are not uniform across Selenium bindings and Chrome versions. A standard screenshot commonly represents the current viewport. If you need the entire document, verify that your chosen binding and browser support full-page capture; otherwise, capture a specific element or stitch scroll segments deliberately. For a component regression, locating the component and taking its element screenshot can reduce unrelated page noise.
Why Chrome Options is the normal path
Selenium recommends Chrome Options for ordinary Chrome mobile emulation and generally prefers it over setting metrics through the Chrome DevTools Protocol (CDP). Selenium describes CDP support as temporary and version-dependent while WebDriver BiDi is implemented across browsers. Its CDP documentation cautions: “This is not designed for testing, nor to have a stable API, so functionality is highly dependent on the version of the browser.”
Free tools Windows power users keep installed
One-click scans. No signup required.
Use CDP only as a specialized fallback when the required capability is not exposed by your binding’s options API, and isolate that code so a browser upgrade does not silently change the test.
Emulation versus a real device or simulator
| Question | Desktop Chrome emulation | Physical device or platform simulator |
|---|---|---|
| Responsive viewport and breakpoint layout? | Well suited | Also suitable, with more setup |
| Actual mobile OS/browser behavior? | Not established | Direct evidence |
| Hardware, native input, GPU, or vendor quirks? | Not reproduced reliably | Can be tested |
| Repeatable local screenshot check? | Convenient and scriptable | Requires device or simulator management |
Use emulation for fast responsive checks, then add real-device or simulator coverage where platform fidelity is a release requirement. Selenium’s legacy mobile documentation distinguishes mobile devices and their emulators or simulators from ordinary desktop browser automation; it should not be used as current setup instructions.
Troubleshooting
Session will not start
Check Chrome and ChromeDriver major versions first, then confirm Selenium is using the intended binary. A mismatch commonly prevents session creation. Update the binding and driver through your environment’s supported method rather than copying an old executable into CI.
Rank #4
- [360 ° Flexible Rotation Design] Comes with a rotatable lanyard ring that supports 360 ° free rotation, effectively solving the problem of twisted and tangled lanyards
- [Wide compatibility] The ultra-thin 0.02-inch design does not block the charging port at all, and both wired and wireless charging can be used directly without removing the pad. Compatible with most smartphones such as iPhone, compatible with various wristbands, lanyards, crossbody straps, and keychains
- [Durable and Portable Material] Premium rust-resistant stainless steel material with good flexibility, which not only avoids scratching the phone case, but also has excellent anti rust and anti fading performance
- [Multi scenario Practical] Paired with a lanyard or wristband, hands-free use can be achieved. The phone is within reach and not easily dropped, ideal for daily commuting and outdoor activities. Suitable for full coverage phone cases, does not support half coverage phone cases
- [Quality Service] If you find any damage or other issues with the product upon receipt, please contact us immediately. We will handle it quickly
“Unknown device” or invalid profile
The named profile is unavailable in that browser version or is misspelled. Switch to custom deviceMetrics, or select a name from the current DevTools device list.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
The layout is still desktop-sized
Ensure mobileEmulation was added to the options object before webdriver.Chrome (or the equivalent builder) created the session. Inspect window.innerWidth, window.innerHeight, and window.devicePixelRatio in the page to confirm the active values.
The screenshot captures a loading or blank state
Navigation completion may have preceded client rendering. Wait for the application’s key selector, data marker, or loading-mask removal. For blank pages, also check console/network failures and whether the target requires authentication.
Mobile content differs unexpectedly
A user agent, touch capability, cookies, geolocation, or server-side device detection may be changing the response. Record these settings in the test and vary one at a time. Remember that emulation does not validate a physical browser’s behavior.
CDP code broke after a browser update
That is an expected risk of a version-coupled protocol. Replace it with Chrome Options when the option exists, or pin and upgrade Chrome, driver, and Selenium together while reviewing the current CDP documentation.
Best Value
- 【PKYAA Double Sided Silicone Suction Phone Case Mount】PKYAA With Double Sided 40 Strong and Reliable individual suction cups, PKYAA provides a thicken and upgraded universal silicon suction mount for your phone.
- 【Friendly to Content Creators】If you are a content creator or an online influencer, you can create videos anywhere with this suction mount completely hands free with this silicone cell phone mount for cases.
- 【HANDS-FREE & Adhere to Mirrors】This Double Sided silicone suction phone case mount allows you to stick your phone to the mirror easily. No longer holding your phone in one hand to watch video tutorials while making up.
- 【Strong Grip on the Smooth Surface】You can easily hang your phone anywhere with a smooth surface. All you do is you clean off your phone and smooth surface. It is STURDY and it not only sticks to mirrors, it also sticks to windows, it sticks to refrigerators, tiles and other clean, flat surfaces.
- 【Press Down Firmly Every 30 Minutes】Use your palm or fingers to press the phone down firmly and check it's secure before letting go. Apply even pressure for a few seconds to allow the suction cup to adhere properly. To maintain the grip and prevent accidental falls, it's a good practice to periodically reapply pressure to the suction cup.
Or skip the browser setup
ScreenshotNeo provides a website screenshot API and MCP server when you need a rendered image without maintaining a Selenium browser session. One GET request returns PNG, JPEG, WebP, or PDF. Its cleanup steps can accept cookie/consent banners and remove more than 60 known consent platforms, newsletter popups, and chat widgets before capture; each step can be disabled.
Only clean shots are billed. Bot checks or CAPTCHAs, blank pages, timeouts, failed loads, and cache hits cost nothing, and the response identifies the result with X-Page-Verdict and X-Billed headers. An MCP server supplies take_screenshot, get_page_info, and capture_pdf tools to Claude, Cursor, and other MCP clients.
For Selenium-like viewport control, ScreenshotNeo supports full-page capture with lazy images loaded, CSS-selector element capture, dark mode, 12 device presets or any viewport, retina scale, custom CSS and JavaScript, clicks, selector/delay/network-idle waits, request and resource blocking, headers, cookies, user agent, timezone, geolocation, transparent backgrounds, resizing, chosen-TTL caching, signed image links, asynchronous webhooks, bulk capture of up to 100 URLs per call, a usage API, and an OpenAPI specification. Its parameter names also accept the names used by other screenshot APIs.
See the ScreenshotNeo documentation for request options. A minimal cURL call is:
Recommended Free Tools
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
Python:
import requests
r = requests.get("https://api.screenshotneo.com/v1/shot", params={"access_key": "YOUR_API_KEY", "url": "https://stripe.com"}, timeout=90)
open("shot.webp", "wb").write(r.content)
Node.js:
const q = new URLSearchParams({ access_key: 'YOUR_API_KEY', url: 'https://stripe.com' });
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);
The Free plan includes 1,000 shots per month with no card. Paid plans start at $5 for 3,000 shots; yearly billing gives two months free, and every feature is available on every plan. Sign up for the free plan to try it.
Cost and reliability considerations
Local Selenium costs are primarily your browser, driver, machine, CI time, and the maintenance burden of keeping versions compatible. Emulated screenshots are repeatable only when you control viewport metrics, browser version, fonts, page data, and readiness conditions. For visual regression, record those inputs alongside the artifact and avoid comparing screenshots made with silently different browser builds.
Frequently Asked Questions
Can Selenium mobile emulation prove an iPhone layout works in Safari?
No. It checks a mobile-emulated Chrome context. Test real iOS Safari or an appropriate simulator when browser- or operating-system-specific behavior matters.
Should I use a device name or custom metrics in CI?
Custom metrics are usually easier to audit because width, height, and pixel ratio are written directly in the test. A named profile is convenient when its availability is stable in your browser image.
Is CDP required for mobile screenshots?
No. Selenium’s Chrome Options mobile-emulation configuration is the normal approach. CDP is a version-dependent fallback for capabilities your binding does not expose.
Quick Recap
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.

