Skip to main content

Screenshots

browser_take_screenshot

Capture the current page, a specific element, or the full scrollable page.

ParameterTypeRequiredDescription
typestringnopng (default) or jpeg
refstringnoElement ref to screenshot a specific element
fullPagebooleannoCapture full scrollable page

Page screenshot

You: Take a screenshot of the current page.
→ browser_take_screenshot
→ Returns: PNG image of the viewport

Element screenshot

You: Take a screenshot of just the login form.
→ browser_take_screenshot { ref: "e12" }
→ Returns: PNG image cropped to the element

Full-page screenshot

You: Take a full-page screenshot including content below the fold.
→ browser_take_screenshot { fullPage: true }
→ Returns: PNG image of entire scrollable page

When to use screenshots

Screenshots complement accessibility snapshots:

Use caseBest tool
Interacting with elementsAccessibility snapshot (refs)
Verifying visual layoutScreenshot
Canvas/chart contentScreenshot
Documenting a bugScreenshot
Understanding page structureAccessibility snapshot
Reading text contentAccessibility snapshot