Hardware FixRecommendedDevice not working? Your driver may be the problemCheck updates for common hardware issues.Fix DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan Now×
Skip to content
World desk5 min

How to Capture Screenshots with Chrome DevTools MCP

Use Chrome DevTools MCP’s take_screenshot tool to capture a browser viewport, full page, or a selected element, then choose a format and output path.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To capture a screenshot with Chrome DevTools MCP, connect an MCP client to a Chrome browser, select the target page, then call take_screenshot with that page’s pageId. Omit uid for the visible viewport, set fullPage: true for the whole page, or supply a current snapshot’s uid to capture one element. PNG is the default; use filePath to save the image or leave it out to receive the image in the tool response.

What you need before capturing

  • An MCP client: Follow the setup instructions for your specific client. The project documents a general configuration that launches npx -y chrome-devtools-mcp@latest, but client configuration paths and procedures can differ.
  • Node.js LTS and npm: These are listed prerequisites for the server.
  • Google Chrome or Chrome for Testing: These are the officially supported browsers. Other Chromium browsers may work but are not guaranteed.
  • A page open in the connected browser: The screenshot tool operates on a page selected by its current pageId.

Use the official Chrome DevTools for agents getting-started guide for client-specific setup, and the Chrome DevTools MCP project for current requirements and supported-browser details.

Capture a viewport, full page, or element

First connect the MCP server and open or select the page in the browser. Then call take_screenshot with the page’s pageId. Page IDs are session-specific; use the ID supplied by your active browser session rather than copying an example value.

Capture the visible viewport

Pass the current page ID and leave out both uid and fullPage (or set fullPage to false). The result is a screenshot of the visible page area.

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

Capture the whole page

Set fullPage to true. This mode is incompatible with uid, so do not combine a full-page capture with an element UID.

Capture one element

  1. Request a fresh page snapshot through the MCP browser tools.
  2. Find the target element’s uid in that snapshot.
  3. Call take_screenshot for the same page using that UID, and do not set fullPage to true.

UIDs belong to a page snapshot and can become stale as the page changes. Get a new snapshot before choosing an element if the content or page state has changed. See the official Chrome DevTools MCP tool reference for the current tool names and parameters.

Choose a file path and image format

Set filePath to save the screenshot. If you omit it, the image is attached to the tool response instead. A requested path must be permitted by the MCP server’s filesystem configuration.

Setting Behavior Useful when
format: "png" or omit format PNG is the documented default; the tool reference does not specify a quality setting for PNG. You want crisp interface text and avoid lossy compression.
format: "jpeg" JPEG supports the quality setting from 0 to 100. You want a compressed image and can accept lossy compression.
format: "webp" WebP supports the quality setting from 0 to 100. You want a compressed image and your next step supports WebP.
--screenshotMaxWidth and/or --screenshotMaxHeight Large screenshots are downscaled while preserving aspect ratio. You need to limit output dimensions or image context.

The project configuration documentation describes JPEG and WebP files as roughly 3–5 times smaller than PNG; that is an approximate product-documented comparison, not a guaranteed result for every page or image. Lowering quality can further reduce file size, with a corresponding loss of image fidelity. See the configuration reference for sizing options.

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.

Example tool call: full-page WebP saved to disk

This illustrative MCP call uses a session-specific example page ID. Replace it with the active page’s ID and choose a path allowed by your server configuration.

{
  "pageId": 1,
  "filePath": "screenshots/page.webp",
  "format": "webp",
  "quality": 85,
  "fullPage": true
}

Example tool call: element screenshot

Replace the illustrative UID with an element UID from the latest snapshot for that page.

{
  "pageId": 1,
  "uid": "<uid from the latest page snapshot>",
  "format": "png"
}

Optional browser connection settings

You do not need to change browser connection settings for every screenshot. If your setup requires an existing debuggable Chrome instance, the project documents --browser-url for a loopback debugging endpoint (including an example on port 9222) and support for a WebSocket endpoint. It also documents headless operation and isolated temporary browser profiles. Check the current configuration instructions before using these options; they change how the browser is launched or connected, not the screenshot parameters.

Troubleshoot common capture problems

Symptom Likely cause What to check
The tool cannot capture the intended page. The page is not open in the connected Chrome instance, or the supplied pageId points to another page or session. Confirm the target tab is open in the connected browser and use its current page ID.
An element screenshot fails or selects the wrong target. The UID came from a different page snapshot or became stale after the page changed. Take a fresh snapshot of the target page and use the UID shown there.
A request combining an element UID and full-page mode does not work. uid and fullPage: true are incompatible. Choose one mode: remove uid for a full-page capture, or use a fresh UID for an element capture without full-page mode.
The image is attached to the tool response instead of saved. No filePath was supplied. Provide a path if you need a file; otherwise retrieve the image from the response.
Saving to the requested path is blocked or the file is missing. The server may restrict file writing to configured roots. If the client does not negotiate filesystem roots, the documented default restricts file-writing tools to the operating system temporary directory. Use an allowed directory or adjust the configured filesystem roots deliberately. Avoid granting broader access than the workflow requires.
The screenshot is larger than expected. The page’s dimensions exceed the output limits you intended. Configure --screenshotMaxWidth and/or --screenshotMaxHeight; the server downscales large images while preserving aspect ratio.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Privacy and telemetry considerations

The ChromeDevTools project warns that “chrome-devtools-mcp exposes content of the browser instance to the MCP clients allowing them to inspect, debug, and modify any data in the browser or DevTools.” An agent connected to an authenticated browser may therefore be able to access sensitive content or act using that session. Connect only a browser profile appropriate for the work, and avoid exposing personal or confidential pages. The Chrome for Developers agent guide also cautions readers to consider browser access when setting up an agent.

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

Usage-statistics collection is enabled by default according to the project README and can be disabled with --no-usage-statistics. The configuration documentation notes that CI and an environment variable also disable collection. The project distinguishes this tool telemetry from Chrome browser metrics. Check the README and configuration reference for current behavior.

Or skip the browser setup

If you need a screenshot from code rather than an agent-connected Chrome session, ScreenshotNeo provides a website screenshot API and MCP server. A single GET request can return a PNG, JPEG, WebP, or PDF. For example, using cURL:

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 parameters and response details. Cookie and consent banners, newsletter popups, and chat widgets can be removed before capture; bot checks, blank pages, timeouts, failed loads, and cache hits are not billed. Its MCP server gives AI agents tools including take_screenshot, get_page_info, and capture_pdf. The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000 screenshots.

Sign up for ScreenshotNeo’s free plan to get 1,000 screenshots a month with no card.

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

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 *

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
PC Slower Than It Used to Be?Free scan - under a minute
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.