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

In Selenium Python, save the CAPTCHA page currently shown in the browser with driver.save_screenshot("captcha.png"). Wait until the UI you want to document has rendered, check that the method returned True, and remember that it captures the current browser window—not the entire scrollable document.

Save the current CAPTCHA page as a PNG

Selenium’s Python WebDriver API documents save_screenshot(path) and get_screenshot_as_file(path) for saving an image of the current window. Both use a PNG screenshot. The methods return a Boolean; a failed file write returns False. The example below creates the output directory, checks the result, and closes the browser even if capture fails. The page address is an example placeholder, so replace it with a test page you own or are authorized to test.

from pathlib import Path
from selenium import webdriver

output = Path("screenshots")
output.mkdir(parents=True, exist_ok=True)

driver = webdriver.Chrome()
try:
    driver.get("https://your-test-site.example/captcha")
    # Wait for the page and the CAPTCHA UI or test state you need.
    saved = driver.save_screenshot(str(output / "captcha.png"))
    if not saved:
        raise OSError("Selenium could not write the screenshot")
finally:
    driver.quit()

This uses the Selenium Python WebDriver API documented for Selenium 4.50.0. See the Selenium WebDriver API documentation for the current API details.

Alternative save method

You can replace the save line with driver.get_screenshot_as_file(str(output / "captcha.png")). It also saves the current window as a PNG and returns a Boolean that you should check.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Sale
Logitech Brio 101 Full HD 1080p Webcam for Streaming and Meetings - Black
  • Compatible with Nintendo Switch 2’s new GameChat mode
  • Auto-Light Balance: RightLight boosts brightness by up to 50%, reducing shadows so you look your best—compared to previous-generation Logitech webcams (1)
  • Privacy with a Slide: The integrated webcam cover makes it easy to get total, reliable privacy when you're not on a video call
  • Built-In Mic: The built-in microphone lets others hear you clearly during video calls
  • Easy Plug-And-Play: The Brio 101 works with most video calling platforms, including Microsoft Teams, Zoom and Google Meet—no hassle; it just works

Make the CAPTCHA state repeatable for authorized tests

CAPTCHA UI can vary between runs. For a site you own or are authorized to test, configure the provider’s documented test mode instead of relying on a live challenge appearing on demand.

reCAPTCHA v2

Google supplies reCAPTCHA v2 test keys that always show “No CAPTCHA” and pass verification requests. Google says the widget displays a warning so these keys are not used for production traffic. This gives a repeatable test state, but it is not a way to test a real user challenge. Follow Google’s reCAPTCHA FAQ and testing guidance for the provider’s instructions.

Rank #2
Sale
NexiGo N60 1080P Webcam with Microphone, Software Control & Privacy Cover, USB HD Computer Web Camera, Plug and Play, for Zoom/Skype/Teams, Conferencing and Video Calling
  • 【Full HD 1080P Webcam】Powered by a 1080p FHD two-MP CMOS, the NexiGo N60 Webcam produces exceptionally sharp and clear videos at resolutions up to 1920 x 1080 with 30fps. The 3.6mm glass lens provides a crisp image at fixed distances and is optimized between 19.6 inches to 13 feet, making it ideal for almost any indoor use.
  • 【Wide Compatibility】Works with USB 2.0/3.0, no additional drivers required. Ready to use in approximately one minute or less on any compatible device. Compatible with Mac OS X 10.7 and higher / Windows 7, 8, 10 & 11 / Android 4.0 or higher / Linux 2.6.24 / Chrome OS 29.0.1547 / Ubuntu Version 10.04 or above. Not compatible with XBOX/PS4/PS5.
  • 【Built-in Noise-Cancelling Microphone】The built-in noise-canceling microphone reduces ambient noise to enhance the sound quality of your video. Great for Zoom / Facetime / Video Calling / OBS / Twitch / Facebook / YouTube / Conferencing / Gaming / Streaming / Recording / Online School.
  • 【USB Webcam with Privacy Protection Cover】The privacy cover blocks the lens when the webcam is not in use. It's perfect to help provide security and peace of mind to anyone, from individuals to large companies. 【Note:】Please contact our support for firmware update if you have noticed any audio delays.
  • 【Wide Compatibility】Works with USB 2.0/3.0, no additional drivers required. Ready to use in approximately one minute or less on any compatible device. Compatible with Mac OS X 10.7 and higher / Windows 7, 10 & 11, Pro / Android 4.0 or higher / Linux 2.6.24 / Chrome OS 29.0.1547 / Ubuntu Version 10.04 or above. Not compatible with XBOX/PS4/PS5.

reCAPTCHA v3

Google recommends creating a separate key for testing environments. Unlike a visible checkbox flow, v3 is score based, so there may be no interactive challenge to capture. The response includes a score and action; your backend must assess those in the application’s context. A screenshot can show the page UI, but it cannot establish what score the backend received or whether your integration handled it correctly.

Google also cautions that test-key scores may not represent real traffic. For the testing-key guidance, see Google’s reCAPTCHA FAQ.

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.
Rank #3
Sale
Logitech C920S HD Pro Webcam Full 1080p/30fps Video Calling Clear Stereo
  • Webcam comes with privacy shutter – puts you in control of what you show and protects the lens with a snugly fitting cover. Does not include the 3-month XSplit VCam license.
  • Full HD 1080P video calls – premium video quality that makes you look like a Pro
  • Full HD 1080P video Recording – a glass lens and full HD mean your recorded videos are crisp and vibrantly colored
  • HD autofocus and light Correction – enjoy razor-sharp high Def in every environment
  • Stereo audio with dual mics – capture natural sound on calls and recorded videos

Configure domains and verify the application separately

Make sure the test key is configured for the hostname you are using. Google says keys are normally restricted to registered domains and first-level subdomains, and localhost must be added for local development. Disabling domain or package validation introduces a security risk; Google says server-side hostname or package checking is required if validation is disabled. See Google’s domain validation guidance, updated July 10, 2024.

A screenshot records browser output; it does not prove that the application accepted the CAPTCHA. Test that outcome separately in the application or backend. Google documents that a reCAPTCHA response token is valid for two minutes and can be verified only once. See Google’s server-side verification documentation.

Rank #4
NIVEOLI Webcam 1080P with Microphone & Privacy Cover for PC/Laptop, USB Computer Camera Plug & Play with Auto Light Correction for Video Calls, Live Streaming Gaming & Online Meetings
  • 【Crystal-Clear 1080P HD Video】This 1080p webcam for PC delivers sharp, true Full HD video at 30 frames per second, bringing your digital world to life with vibrant clarity. Enjoy smooth, real-time streaming with enhanced high dynamic range (HDR) that keeps your face clearly visible even in low light or backlit conditions.
  • 【Built-In Noise-Canceling Microphone】This computer camera with microphone features dual noise-reducing digital mics and an advanced audio processor, capturing rich stereo sound while filtering background noise. It ensures clear conversations during video calls, even in busy environments.
  • 【Privacy Shutter for Added Security】This secure USB webcam includes a built-in privacy cover, letting you physically block the lens with a simple slide. Protect your visibility and keep the lens dust-free—no drivers needed, just plug into USB 2.0 and start using it immediately.
  • 【Flexible Mount & Auto Light Correction】Designed for your computer or laptop, this webcam comes with an adjustable clip for monitors or standalone use. It offers automatic light correction and fixed focus for sharp, well-balanced images in any lighting.
  • 【Wide Device & Platform Compatibility】This versatile webcam for laptop and desktop use is compatible with Windows, Mac, Linux, and Android systems. Supports Skype, Zoom, Twitch, YouTube, and more—featuring a 360° rotating head for easy adjustment. Simply plug and play.

Use a reliable capture sequence

  1. Open an authorized local or staging page using the intended test-key configuration.
  2. Wait for the relevant page content and widget or test state to render. Navigation finishing does not necessarily mean an asynchronously rendered widget is ready.
  3. Call save_screenshot or get_screenshot_as_file and check its Boolean result.
  4. Assert CAPTCHA acceptance or rejection separately; do not treat an image of the page as proof of server-side verification.
  5. Keep screenshots and test logs clear of production tokens, session credentials, and personal information. Do not publish images containing them.

Troubleshoot common capture problems

  • The PNG is missing or the method returns False: confirm the parent directory exists, the path is correct, and the process can write to that location. The example creates its directory before capture.
  • The screenshot does not show the widget: wait for the specific UI or test state, rather than assuming page navigation alone means asynchronous rendering has finished. For a repeatable reCAPTCHA state, use the provider’s test configuration.
  • No visible challenge appears: this can be expected with reCAPTCHA v3, which is score based. Test the score-handling integration separately from screenshot capture.
  • The screenshot looks right but the test fails: image capture does not verify backend acceptance. Check the application’s test result and server-side verification flow; a token is single-use and expires after two minutes.
  • A local test key is rejected: check that the key configuration includes the hostname in use. Google specifically says to add localhost for local development.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Or skip the browser setup

If you need a screenshot endpoint rather than a Selenium browser workflow, ScreenshotNeo accepts a URL in one GET request and returns an image or PDF. It removes cookie and consent banners, newsletter popups, and chat widgets before capture; each step can be turned off. Bot checks, blank pages, failed loads, timeouts, and cache hits are not billed, and the response identifies the page verdict and billing status. ScreenshotNeo also has an MCP server with screenshot tools for AI agents.

Here is the one-call cURL example, adapted to your authorized test URL. See the ScreenshotNeo API documentation for request options and response details.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://your-test-site.example/captcha -o captcha.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.

Best Value
Anker PowerConf C200 2K Webcam for PC/Laptop/Mac, Low-Light Correction
  • 2K Ultra-Clear Resolution: Enjoy sharp, detailed video with this 2K resolution webcam for professional-grade conferences, enhancing your PC setup.
  • Advanced Audio Clarity with AI Noise Cancellation: This webcam features dual mics to ensure voices are crystal clear, even in noisy environments, making it ideal for virtual meetings.
  • Superior Low-Light Performance: This webcam captures crisp images in dim settings without extra lighting, perfect for any home office or late-night streaming.
  • Customizable Viewing Angles: Choose from 65°, 78°, or 95° via software to frame your perfect shot during video calls with this versatile webcam for PC.
  • Privacy When You Need It: An integrated cover slides easily over the lens of this webcam for security and peace of mind between calls.

Frequently Asked Questions

Does Selenium’s screenshot call capture the full page?

No. The documented save methods capture the current browser window, not the entire scrollable document.

Can a screenshot prove that reCAPTCHA passed?

No. It records browser output only; verify the application’s server-side result separately.

Does reCAPTCHA v3 always show a challenge to photograph?

No. It is score based and may have no interactive challenge UI.

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

Quick Recap

SaleBestseller No. 1
Logitech Brio 101 Full HD 1080p Webcam for Streaming and Meetings - Black
Logitech Brio 101 Full HD 1080p Webcam for Streaming and Meetings - Black
Compatible with Nintendo Switch 2’s new GameChat mode; Built-In Mic: The built-in microphone lets others hear you clearly during video calls
$35.82
SaleBestseller No. 3
Logitech C920S HD Pro Webcam Full 1080p/30fps Video Calling Clear Stereo
Logitech C920S HD Pro Webcam Full 1080p/30fps Video Calling Clear Stereo
Full HD 1080P video calls – premium video quality that makes you look like a Pro; HD autofocus and light Correction – enjoy razor-sharp high Def in every environment
$54.99

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.