zendriver-rs
Async-first, undetectable browser automation via the Chrome DevTools Protocol.
A Rust port of zendriver. Drives Chrome via raw CDP โ no WebDriver, no JS shim โ with anti-detection patches baked in by default.
๐ User guide & full documentation โ ยท ๐ฆ API reference (docs.rs) โ
Quick example
use Browser;
async
More working examples in crates/zendriver/examples/.
Feature matrix
| Feature | Default? | Use case | Extra deps |
|---|---|---|---|
stealth |
yes | Anti-detection: spoofed UA/platform, isolated worlds, JS shim | (built-in to zendriver) |
interception |
no | Block/modify requests via CDP Fetch.*; rule-based + streams |
zendriver-interception |
expect |
no | Playwright-style expect_response() / expect_request() |
(in-tree, no extra crate) |
cloudflare |
no | Solve Cloudflare Turnstile challenges | zendriver-cloudflare |
fetcher |
no | Auto-download a pinned Chrome for Testing build | zendriver-fetcher + reqwest/zip |
Install
Pick the use case that matches what you're building.
Just browse:
Default stealth is on.
Stealth scraping (explicit):
Same as above โ only spell out the feature if you want it visible in Cargo.toml.
Everything:
Adds request interception, expect() matchers, Cloudflare Turnstile bypass, and the Chrome for Testing fetcher.
Phases
Six development phases shipped into the v0.1.0 release. The mdBook covers each surface in depth.
- Foundation โ CDP transport + minimal
Browser/Tab/Element. See introduction. - Stealth โ fingerprint patches + isolated worlds + stealth JS bundle. See stealth.
- Element API completeness โ CSS/XPath/text/role selectors, actionability, input controller, screenshots. See quickstart.
Tab/Browsercompleteness โ multi-tab, cookies, storage, frames, nav history,wait_for_idle. See multi-tab + frames.- Optional gated features โ request interception,
expect()matchers, Cloudflare bypass, Chrome-for-Testing fetcher. See interception, expect, cloudflare, fetcher. - Polish + release โ trait extraction, rustdoc + mdBook, publish to crates.io.
Comparison
| Feature | zendriver-rs | chromiumoxide | fantoccini | headless_chrome | thirtyfour |
|---|---|---|---|---|---|
| API ergonomics opinion | builder + auto-wait | raw CDP types | WebDriver verbs | sync wrappers | WebDriver verbs |
| Stealth out-of-box | yes (default) | no | no | no | no |
| Multi-tab | yes (first-class) | yes | yes | yes | yes |
| Interception | yes (Fetch.* wrapper) |
yes (raw) | no (proxy-only) | partial | no (proxy-only) |
| License | MIT OR Apache-2.0 | MIT OR Apache-2.0 | Apache-2.0 | MIT | MIT |
| Async runtime | tokio | tokio / async-std | tokio | sync | tokio |
Subjective rows marked *opinion. All claims accurate as of the 0.1.0 release; check upstream changelogs before relying on them.
Contributing
See CONTRIBUTING.md. Issues and PRs welcome.
License
Dual-licensed under MIT (LICENSE-MIT) and Apache-2.0 (LICENSE-APACHE) at your option.