High-Level Stealthy Architecture Overview
This chart outlines the various paths one can take regarding SeleniumBase stealth options:
- Regular Mode (100% Selenium) -->
chromdriver --> (no stealth at all)
- UC Mode -->
uc_driver --> (basic stealth)
- UC Mode --> UC + CDP Mode -->
uc_driver --> (basic stealth)
- UC Mode --> UC + CDP Mode -->
CDP --> (maximum stealth)
- UC Mode --> UC + CDP Mode --> Stealthy Playwright Mode -->
CDP --> (maximum stealth)
- Pure CDP Mode (sync format) -->
CDP --> (maximum stealth)
- Pure CDP Mode (async format) -->
CDP --> (maximum stealth)
- Pure CDP Mode (sync format) --> Stealthy Playwright Mode -->
CDP --> (maximum stealth)
- Pure CDP Mode (async format) --> Stealthy Playwright Mode -->
CDP --> (maximum stealth)
UC Mode is activated by setting uc=True, or by setting --uc as a command-line option.
UC + CDP Mode is activated via sb.activate_cdp_mode(url), or sb.open(url) from UC Mode.
You can call sb.driver.get(url) to open a URL in UC Mode without activating CDP Mode, but that's less stealthy.
UC + CDP Mode may start like this: (may include additional args)
from seleniumbase import SB
with SB(uc=True, test=True) as sb:
sb.activate_cdp_mode(url)
Pure CDP Mode (sync format) starts like this: (may include additional args)
from seleniumbase import sb_cdp
sb = sb_cdp.Chrome(url)
Pure CDP Mode (async format) starts like this: (may include additional args)
from seleniumbase import cdp_driver
driver = await cdp_driver.start_async()
tab = await driver.get(url)
CDP Mode details and examples are covered in the CDP Mode docs.
From CDP Mode, you can also use Stealthy Playwright Mode, which makes Playwright stealthy.
Stealthy Playwright Mode details and examples are covered in the Stealthy Playwright Mode docs.
High-Level Stealthy Architecture Overview
This chart outlines the various paths one can take regarding SeleniumBase stealth options:
chromdriver--> (no stealth at all)uc_driver--> (basic stealth)uc_driver--> (basic stealth)CDP--> (maximum stealth)CDP--> (maximum stealth)CDP--> (maximum stealth)CDP--> (maximum stealth)CDP--> (maximum stealth)CDP--> (maximum stealth)UC Mode is activated by setting
uc=True, or by setting--ucas a command-line option.UC + CDP Mode is activated via
sb.activate_cdp_mode(url), orsb.open(url)from UC Mode.You can call
sb.driver.get(url)to open a URL in UC Mode without activating CDP Mode, but that's less stealthy.UC + CDP Mode may start like this: (may include additional args)
Pure CDP Mode (sync format) starts like this: (may include additional args)
Pure CDP Mode (async format) starts like this: (may include additional args)
CDP Mode details and examples are covered in the CDP Mode docs.
From CDP Mode, you can also use Stealthy Playwright Mode, which makes Playwright stealthy.
Stealthy Playwright Mode details and examples are covered in the Stealthy Playwright Mode docs.