Get Screenshot
Capture full-page or viewport screenshots of dynamic, JavaScript-rendered pages with the Get Screenshot endpoint, with real browser rendering enabled by default.
Render a page in a real browser and return a base64-encoded screenshot. Real browser rendering is enabled by default so client-side scripts and layout elements render before the capture.
Note
- Use the Scraper API Server (
https://api.mrscraper.com) host when calling this endpoint. - Set
screenshottofullfor the entire scroll height, totopfor the first viewport, or to<width>x<height>(optionally-<zoom>) for a custom viewport, such as1280x800or1920x1080-75. The image is always a PNG. - The response is a JSON object with the base64-encoded
screenshotand the pagehtml. The tokens used are in thetoken_usageresponse header. - See Get Screenshot in the Scraper API guide for the full list of settings.
Query Parameters
API token.
URL-encoded URL of the page you want to capture, such as https%3A%2F%2Fwww.walmart.com%2Fsearch%3Fq%3Dtable%2520lamps. Must include the protocol (https://).
uriScreenshot area. full captures the entire scroll height (default), top captures the first viewport, and <width>x<height> sets the viewport size in pixels with an optional -<zoom> percent, such as 1280x800 or 1920x1080-75. Width and height range from 100 to 3840, zoom from 25 to 300. The image is a base64-encoded PNG.
"full"^(full|top|[0-9]{3,4}x[0-9]{3,4}(-[0-9]{2,3})?)$Screenshots always load the page in a real browser, so rendering stays on for this endpoint.
trueMaximum seconds to wait for the scrape before the request times out. Up to 330, after which the API stops waiting. Increase for slow or complex pages.
3001 <= value <= 330Opens the site's home page first to warm the session before loading the target URL. Useful for sites that expect a normal browsing session before deeper pages.
falseReturns the raw HTML of the scraped page in the response.
trueAlso returns the page content as clean Markdown in markdown. Send it with html=true and browserRendering=true.
falseRoutes the request through a real device to improve results on complex websites. On by default; set to false to use standard routing.
trueTwo-letter country code to load the page from, such as us or gb. Defaults to the United States. Send geoCode or proxyCountry; if you send both, they must match.
"us"2 <= length <= 2Two-letter country code of the proxy server, such as us or gb. Same as geoCode; if you send both, they must match. Defaults to the United States.
"us"2 <= length <= 2Saves the result to the Result tab.
trueServes a cached result of the same request when it is newer than this age, in milliseconds, such as 86400000 for 1 day. Up to 604800000 (7 days). Omit or send 0 to always scrape fresh. A cached result costs the same tokens as the original scrape.
0 <= value <= 604800000Waits until a specific CSS selector appears in the DOM before returning the page, such as #results. Up to 500 characters. Useful for content that loads asynchronously after the initial page load. Turns on browser rendering.
length <= 500Extra seconds to wait after the page loads, from 0 to 30. Decimals are allowed, such as 1.5. Turns on browser rendering.
0 <= value <= 30Routes the request to a specific scraper action, or simply flags it. Useful for separating analytics per domain.
Maximum total tokens the scrape and its retries can use. Automatic retries are bounded by this cap, so the total tokens for a single run stay at or below the value you set. Omit for no limit.
1 <= valueMaximum number of retries for the request. Omit for no limit.
0 <= valueHeader Parameters
API token.
Response Body
application/json
application/json
application/json
curl -X GET "https://api.mrscraper.com/?token=string&url=https%3A%2F%2Fwww.walmart.com%2Fsearch%3Fq%3Dtable%2520lamps&screenshot=1280x800" \ -H "x-api-token: string"{
"html": "<!DOCTYPE html>...</html>",
"screenshot": "iVBORw0KGgoAAAANSUhEUgAA..."
}{
"message": "Unauthorized access",
"data": null
}{
"success": false,
"message": "Something failed on our side. Please retry. If it keeps failing, contact support@mrscraper.com with request id <trace_id>.",
"data": null,
"error": "internal",
"traceId": "<trace_id>"
}Scrape Markdown GET
Convert any web page into clean, LLM-friendly Markdown with the Scrape Markdown endpoint, stripping navigation, scripts, and ads for token-efficient AI input.
Scrape Brand GET
Extract a website's colors, typography, logos, icons, social links, and metadata with the Scrape Brand endpoint, with an optional HTML, screenshot, and ZIP page bundle.