Driver FixRecommendedSound, Wi-Fi or graphics acting up? Check drivers firstFind missing or outdated drivers fast.Check DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PC×
Skip to content
World desk5 min

How to Capture a Website Screenshot on Mobile with ScreenshotAPI.net

Use ScreenshotAPI.net’s screenshot endpoint with a mobile-sized viewport, bearer authentication, and direct image saving. See runnable examples, settings, and fixes for common errors.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To capture a mobile-sized website screenshot with ScreenshotAPI.net, send a GET request to its current endpoint, https://screenshot-api.net/v1/screenshot, authenticate with a bearer token, and set width and height to the viewport you want. For example, 375×812 produces a mobile-sized viewport rendering; it does not, by itself, establish that the page was rendered as a particular phone model. The API returns image bytes, which you save directly to a file. ScreenshotAPI.net’s documentation describes the request and options.

Capture a mobile-sized screenshot with cURL

Get an API key through the service’s account flow, then store it in an environment variable rather than placing a production key in a URL. The service warns that query-string keys can be exposed through page source or server logs.

As an Amazon Associate I earn from qualifying purchases.

  1. Set the key in your shell: export SCREENSHOT_API_KEY='YOUR_API_KEY'.
  2. Request the page with a mobile-sized viewport and save the response body as an image:
curl -G "https://screenshot-api.net/v1/screenshot" 
  -H "Authorization: Bearer $SCREENSHOT_API_KEY" 
  --data-urlencode "url=https://example.com" 
  --data-urlencode "width=375" 
  --data-urlencode "height=812" 
  -o mobile-shot.png

Replace https://example.com with the page you want to capture. The request’s required parameter is url; the dimensions specify the viewport in CSS pixels. The response body is the image itself, not JSON containing a separate image URL. The requested format determines the response Content-Type.

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

Use the API from Python or Node.js

Python

This example uses the Python requests package. It writes the returned image bytes to disk and checks for an HTTP error before saving.

#1 Best Overall
Samsung Galaxy A17 5G Smart Phone 128GB US 1 Yr Manufacturer Warranty Black | Large AMOLED, High-Res Camera, Durable Design, Super Fast Charging, Expandable Storage, Circle to Search, 2025
  • YOUR CONTENT, SUPER SMOOTH: The ultra-clear 6.7" FHD+ Super AMOLED display of Galaxy A17 5G helps bring your content to life, whether you're scrolling through recipes or video chatting with loved ones.¹
  • LIVE FAST. CHARGE FASTER: Focus more on the moment and less on your battery percentage with Galaxy A17 5G. Super Fast Charging powers up your battery so you can get back to life sooner.²
  • MEMORIES MADE PICTURE PERFECT: Capture every angle in stunning clarity, from wide family photos to close-ups of friends, with the triple-lens camera on Galaxy A17 5G.
  • NEED MORE STORAGE? WE HAVE YOU COVERED: With an improved 2TB of expandable storage, Galaxy A17 5G makes it easy to keep cherished photos, videos and important files readily accessible whenever you need them.³
  • BUILT TO LAST: With an improved IP54 rating, Galaxy A17 5G is even more durable than before.⁴ It’s built to resist splashes and dust and comes with a stronger yet slimmer Gorilla Glass Victus front and Glass Fiber Reinforced Polymer back.
import os
import requests

api_key = os.environ["SCREENSHOT_API_KEY"]
response = requests.get(
    "https://screenshot-api.net/v1/screenshot",
    headers={"Authorization": f"Bearer {api_key}"},
    params={
        "url": "https://example.com",
        "width": 375,
        "height": 812,
    },
    timeout=35,
)
response.raise_for_status()
with open("mobile-shot.png", "wb") as image_file:
    image_file.write(response.content)

print("Final page status:", response.headers.get("X-Page-Status"))

Node.js

Use Node.js with a runtime that provides the global fetch API. The response is binary data, so save its array buffer rather than trying to parse JSON.

import { writeFile } from "node:fs/promises";

const apiKey = process.env.SCREENSHOT_API_KEY;
if (!apiKey) throw new Error("Set SCREENSHOT_API_KEY first");

const url = new URL("https://screenshot-api.net/v1/screenshot");
url.searchParams.set("url", "https://example.com");
url.searchParams.set("width", "375");
url.searchParams.set("height", "812");

const response = await fetch(url, {
  headers: { Authorization: `Bearer ${apiKey}` },
  signal: AbortSignal.timeout(35000),
});
if (!response.ok) throw new Error(`Screenshot request failed: HTTP ${response.status}`);

await writeFile("mobile-shot.png", Buffer.from(await response.arrayBuffer()));
console.log("Final page status:", response.headers.get("x-page-status"));

Choose the viewport and image settings

The product page illustrates 375×812 as a mobile viewport, not as a universal phone specification. Choose dimensions that match the layout constraint you need to inspect. For meaningful side-by-side comparisons, keep width and height the same across captures before comparing formats or scale.

Rank #2
Tracfone Motorola Moto G 2025, 64GB, Saphire Blue (Locked to
  • Carrier: This phone is locked to Tracfone, which means this device can only be used on the Tracfone wireless network. Tracfone plan required, activating is easy, just 3 steps.
  • DISPLAY: Immersive viewing on a 6.7-inch super-bright 120Hz display with powerful stereo speakers and Bass Boost for cinematic entertainment.
  • CAMERA SYSTEM: Advanced 50MP Quad Pixel camera captures sharp, detailed photos and videos in any lighting condition
  • PERFORMANCE: Lightning-fast 5G connectivity paired with a powerful processor and RAM Boost for smooth multitasking.
  • BATTERY LIFE: Long-lasting 5000mAh battery with TurboPower charging technology delivers hours of power in minutes.
Setting Documented behavior When to adjust it
url Required; HTTP or HTTPS URL, up to 2048 characters. Use the exact page address. Pages that require a session may need cookies, headers, or basic authentication.
width CSS pixels; default 1280, maximum 3840. Set a mobile-sized width, such as 375, to inspect a narrow layout.
height CSS pixels; default 800, maximum 4320. Set the viewport height needed for the part of the page you want to inspect.
scale Device pixel ratio; default 1, range 0.1–3. Adjust when you need a different output pixel density. This setting does not prove real-device equivalence.
Format PNG, JPEG, and WebP are among the supported formats. PNG is lossless and ignores the quality parameter. Choose another documented format when its compression trade-off suits your use.
delay Optional; maximum 10,000 milliseconds. Allow extra time for content that appears after the initial page load.
timeout Default 25 seconds; documented range 1–30 seconds. Set it within the documented range if you need a different request limit. It is a limit, not a promise that a page will finish loading in that time.
Cookies and headers Listed as available request options. Supply session or request information when the target page requires it.

Viewport sizing controls the rendered page area. The available documentation supports describing this as a mobile-sized viewport capture, not a claim that the API reproduces a named phone’s hardware, browser interface, or all of its behavior.

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

Check the result and diagnose common failures

If the file looks like a login screen, access-denied page, or error page rather than the intended content, inspect X-Page-Status. ScreenshotAPI.net documents it as the final document’s status after redirects; a 401 or 403 can indicate that the capture reached an authentication or error page.

Rank #3
Sale
Samsung Galaxy A17 5G Smart Phone 128GB, US 1 Yr Manufacturer Warranty Blue | Large AMOLED, High-Res Camera, Durable Design, Super Fast Charging, Expandable Storage, Circle to Search, 2025
  • YOUR CONTENT, SUPER SMOOTH: The ultra-clear 6.7" FHD+ Super AMOLED display of Galaxy A17 5G helps bring your content to life, whether you're scrolling through recipes or video chatting with loved ones.¹
  • LIVE FAST. CHARGE FASTER: Focus more on the moment and less on your battery percentage with Galaxy A17 5G. Super Fast Charging powers up your battery so you can get back to life sooner.²
  • MEMORIES MADE PICTURE PERFECT: Capture every angle in stunning clarity, from wide family photos to close-ups of friends, with the triple-lens camera on Galaxy A17 5G.
  • NEED MORE STORAGE? WE HAVE YOU COVERED: With an improved 2TB of expandable storage, Galaxy A17 5G makes it easy to keep cherished photos, videos and important files readily accessible whenever you need them.³
  • BUILT TO LAST: With an improved IP54 rating, Galaxy A17 5G is even more durable than before.⁴ It’s built to resist splashes and dust and comes with a stronger yet slimmer Gorilla Glass Victus front and Glass Fiber Reinforced Polymer back.
Symptom Likely cause What to try
The request is rejected for authentication. The bearer token is missing, invalid, or not being sent in the Authorization header. Check that the environment variable is set and that the header uses Authorization: Bearer .... Do not move a production key into a URL query string.
The image shows a login or access-denied page. The target requires a session, credentials, or other access information; the final document may have returned 401 or 403. Check X-Page-Status. Use the documented cookies, headers, or basic-auth options if appropriate and authorized.
The capture is blank or misses content loaded later. The page may render content asynchronously or require more time. Try the optional delay setting, up to its documented maximum of 10,000 milliseconds. Confirm that the target URL itself loads as expected.
The request fails or exceeds its time limit. The target did not complete within the request timeout, or the timeout value is outside the documented range. Use a timeout within 1–30 seconds (25 seconds is the documented default), and retry only after checking the URL and page availability.
The saved file is not a valid image. The response may be an HTTP error or an error page rather than image bytes, or the code may be parsing the body as JSON. Check the HTTP status and response headers before writing; save the response body as binary data.
The capture does not match a particular phone. Width, height, and scale specify viewport and pixel density, not proof of a particular model’s browser or hardware behavior. Match the viewport dimensions and scale you need to compare, and treat the result as a viewport rendering rather than a device certification.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Or skip the browser setup

ScreenshotNeo is a screenshot API with a one-request workflow and an MCP server for AI agents. It accepts cookie banners like a visitor and removes 60+ known consent platforms, newsletter popups, and chat widgets before capture; each cleanup step can be turned off. Bot checks or CAPTCHAs, blank pages, timeouts, failed loads, and cache hits are not billed, with the response indicating the page verdict and billing status.

Use the API key from ScreenshotNeo with this cURL example (see the ScreenshotNeo API documentation):

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://example.com -o shot.webp

The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000. Sign up for ScreenshotNeo’s free plan.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
Sale
Samsung Galaxy S26 Ultra, Unlocked Android Smartphone, 512GB, Black
  • PRIVACY DISPLAY: Automatically hide your screen from those beside you. The built-in privacy display can be preset¹ to turn on when receiving notifications, typing passwords, or using specific apps
  • TYPE IT IN. TRANSFORM IT FAST: Enhance any shot in seconds on your smartphone by using Photo Assist² with Galaxy AI.³ Add objects, restore details, or apply new styles by simply typing or tapping
  • NIGHTS, CAPTURED CLEARLY: From gigs to city lights, record and capture moments after dark with clarity using Nightography so your photos and videos stay crisp and clear on your Samsung Galaxy
  • MAKE IT. EDIT IT. SHARE IT: Turn everyday moments into something personal with creative tools built right into your mobile phone, whether it’s a special contact photo, custom wallpaper, an invitation or more⁴
  • HELP THAT KEEPS UP: Stay in the moment while Now Nudge with Galaxy AI helps you respond faster and stay organized with smart suggestions⁵ that appear exactly when you need them on your phone

Frequently Asked Questions

Does a 375×812 screenshot represent a specific phone?

No. It is a mobile-sized viewport example, not evidence of exact emulation of a named phone.

Does ScreenshotAPI.net return JSON with an image link?

No. Its documented response is image bytes, which you save directly.

Best Value
Tracfone Moto g Play 2024 Prepaid Phone with a 1-Yr Plan Included
  • Carrier: This phone is locked to Tracfone, which means this device can only be used on the Tracfone wireless network. Activating is easy, just 3 steps.
  • ACTIVATION Promotion: Includes 1500 min, 1500 texts & 1500 MB Data + add more as you need it
  • CAMERA SYSTEM: 50MP Quad Pixel camera. Capture sharper, more vibrant photos day or night with 4x the light sensitivity.
  • PERFORMANCE: Blazing-fast Qualcomm performance. Get the speed you need for great entertainment with a Snapdragon 680 processor and 4GB of RAM.
  • 64GB built-in storage. Get plenty of room for photos, movies, songs, and apps. Made for US

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.

Leave a Reply

Your email address will not be published. Required fields are marked *

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

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

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Outdated Drivers Are Slowing You DownFree scan - exact matches

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.