October 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 PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk4 min

How to Capture All Requests with Selenium Wire in Headless Chrome

Enable headless Chrome, set Selenium Wire’s ignored methods to an empty list, and check filters, storage, and asynchronous page behavior when requests are missing.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To capture all HTTP methods—including CORS preflight OPTIONS requests—with Selenium Wire in headless Chrome, enable Chrome’s headless mode and set Selenium Wire’s ignore_http_methods option to an empty list. Selenium Wire ignores OPTIONS by default, so headless mode alone does not capture every method.

Set up headless Chrome and capture requests

Pass Chrome’s options and Selenium Wire’s configuration to the Chrome driver together. This example enables the newer headless mode and captures OPTIONS as well as other HTTP methods:

As an Amazon Associate I earn from qualifying purchases.

from selenium import webdriver
from selenium.webdriver.chrome.options import Options

chrome_options = Options()
chrome_options.add_argument("--headless=new")

seleniumwire_options = {
    "ignore_http_methods": [],
    "enable_har": True,
}

driver = webdriver.Chrome(
    options=chrome_options,
    seleniumwire_options=seleniumwire_options,
)

try:
    driver.get("https://example.com")
    for request in driver.requests:
        print(request.method, request.url)
finally:
    driver.quit()

The headless argument is a Chrome option; Selenium Wire’s Chrome integration accepts browser options and its own seleniumwire_options. The Selenium Wire documentation describes its capture mechanism as redirecting browser traffic through an internal proxy. That means “all requests” means requests routed through that proxy and retained under your capture settings—not every conceivable Chrome network event. See the Selenium Wire documentation and Selenium Chrome documentation.

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

Make sure “all” really includes the traffic you need

Include preflight OPTIONS requests

Selenium Wire’s default ignore_http_methods value is ['OPTIONS']. Set it to [] to stop ignoring methods and capture preflight requests too. A preflight only appears if the page actually triggers one; it is not generated for every navigation or fetch.

#1 Best Overall
Samsung 14" Galaxy Chromebook Go Laptop PC Computer, Intel Celeron N4500 Processor, 4GB RAM, 64GB Storage, ChromeOS, XE340XDA-KA2US, Student Laptop, Silver
  • SLIM. LIGHTWEIGHT. READY TO GO: The all-new slim design is perfect for busy lives on the go.
  • SKILLFULLY DESIGNED. MILITARY TOUGH: Built with premium craftsmanship to withstand the occasional drop or ding.
  • ALL-DAY, ALL-IN-ONE CHARGING: Power through your school day – and beyond – with a long-lasting 12-hour battery.¹
  • 3X FASTER THAN THE PREVIOUS GENERATION OF WIFI: Crush your schoolwork in record time with Wi-Fi that’s three times faster than the previous generation of Wi-Fi.
  • YOUR PHONE AND CHROMEBOOK WORK BETTER TOGETHER: Easily transfer files between devices, and control your phone right from your Chromebook.

Review capture filters and bypasses

  • driver.scopes filters which matching URLs are stored. An empty list is the default and leaves all URLs in scope.
  • disable_capture=True disables interception and storage.
  • exclude_hosts bypasses Selenium Wire for matching hosts, so their traffic will not appear in the capture.

Review these settings if requests are missing. URL scopes filter storage; they do not mean out-of-scope requests are necessarily blocked from continuing through the proxy.

Read, wait for, or retain captured requests

Choose an inspection interface

  • driver.requests provides captured requests in chronological order.
  • driver.last_request is useful when only the most recent request matters.
  • driver.iter_requests() lets you iterate through a large capture.
  • With enable_har=True, the HAR archive is available through driver.har.

Delete driver.requests to clear previously captured requests and HAR entries. Selenium Wire’s default storage is disk-based in a .seleniumwire folder under the system temporary directory. For in-memory storage, use request_storage='memory'; if you also set request_storage_max_size, older records are discarded when that limit is reached.

Rank #2
HP Chromebook 14 Laptop, Intel Celeron N4120, 4 GB RAM, 64 GB eMMC, 14" HD Display, Chrome OS, Thin Design, 4K Graphics, Long Battery Life, Ash Gray Keyboard (14a-na0226nr, 2022, Mineral Silver)
  • FOR HOME, WORK, & SCHOOL – With an Intel processor, 14-inch display, custom-tuned stereo speakers, and long battery life, this Chromebook laptop lets you knock out any assignment or binge-watch your favorite shows..Voltage:5.0 volts
  • HD DISPLAY, PORTABLE DESIGN – See every bit of detail on this micro-edge, anti-glare, 14-inch HD (1366 x 768) display (1); easily take this thin and lightweight laptop PC from room to room, on trips, or in a backpack.
  • ALL-DAY PERFORMANCE – Reliably tackle all your assignments at once with the quad-core, Intel Celeron N4120—the perfect processor for performance, power consumption, and value (2).
  • 4K READY – Smoothly stream 4K content and play your favorite next-gen games with Intel UHD Graphics 600 (3) (4).
  • MEMORY AND STORAGE – Enjoy a boost to your system’s performance with 4 GB of RAM while saving more of your favorite memories with 64 GB of reliable flash-based eMMC storage (5).

Wait when the application makes requests later

A navigation can finish before a single-page application, user interaction, or delayed script makes the request you want. Trigger the relevant action or wait for the application state before inspecting the collection. wait_for_request(pattern, timeout=10) waits for a matching request that another action has already triggered; it does not create the request itself.

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

Troubleshoot missing requests and startup problems

  • No requests appear: confirm the Chrome driver was created with Selenium Wire’s integration and that you passed both options and seleniumwire_options to it.
  • OPTIONS is absent: set "ignore_http_methods": []; the default ignores that method.
  • Only some URLs appear: inspect driver.scopes for filters, and check for exclude_hosts entries that bypass the proxy.
  • Capture is empty or disabled: check that disable_capture is not set to True.
  • Earlier requests disappeared: check whether in-memory storage reached request_storage_max_size; older records are discarded as new ones arrive.
  • HTTPS shows an unexpected trust warning: Selenium Wire uses its own root certificate to decrypt HTTPS traffic and documents custom certificate/key configuration. Its README warns that Chrome may show “Not Secure” when the certificate has not been installed as trusted. Treat captured sensitive data and certificate trust carefully, especially in real environments.
  • Chrome fails to start: check Chrome and ChromeDriver major versions. Selenium’s general guidance says their major versions should match and that Selenium 4 is compatible with Chrome 75 and greater; this is not a Selenium Wire compatibility guarantee. Verify the complete Selenium Wire, Selenium, Python, Chrome, and ChromeDriver combination used in your runtime.

Or skip the browser setup

If your goal is a screenshot rather than inspecting network traffic, ScreenshotNeo can return a page capture through one GET request. It does not expose Selenium Wire’s request log or replace network inspection. Its screenshot API can remove cookie banners, newsletter popups, and chat widgets before capture; bot checks, blank pages, and failed loads are not billed. It also provides an MCP server for AI agents to take screenshots.

Example using cURL (replace the target URL as needed):

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 setup. The free plan includes 1,000 screenshots per month with no card; paid plans start at $5 for 3,000. Sign up for free ScreenshotNeo access.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Frequently Asked Questions

Does Selenium Wire capture OPTIONS requests by default?

No. Its default ignored-method list includes OPTIONS; set ignore_http_methods to an empty list to include them.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
HP 14" HD Chromebook Laptop for Students, Intel Quad-Core N4120(> N4020), 4GB RAM, 64GB eMMC, WiFi, Webcam, HDMI, USB-A&C, 14 Hours Battery Life, Zoom, Chrome OS, CUE Accessories
  • Intel Celeron N4120: 4 Cores & Threads, 1.1GHz Base Clock, Up to 2.6GHz Boost Clock, 4MB Cache, Intel UHD Graphics 600. The perfect combination of performance, power consumption, and value helps your device handle multitasking smoothly and reliably with four processing cores to divide up the work.

Does wait_for_request trigger the request?

No. It waits for a matching request after your code or page has already triggered it.

Does ScreenshotNeo show captured network requests?

No. ScreenshotNeo returns screenshots or PDFs; use Selenium Wire when you need to inspect browser traffic.

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
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

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.