Web access for LLM agents. One static binary. No Chrome.
Project description
unbrowser
Web access for LLM agents. One static binary. No Chrome.
Single-file native headless browser optimized for LLM agents. Runs JavaScript via QuickJS, returns a low-token page summary on every navigate, and gives you stable element refs for click/type/submit. Tens of MB RAM per session, no Chrome dependency.
pip install pyunbrowser # PyPI name; the import is `from unbrowser import ...`
The wheel ships the native binary for your platform — there's nothing else to install.
Quick start
from unbrowser import Client
with Client() as ub:
r = ub.navigate("https://news.ycombinator.com")
for s in ub.query(".titleline > a")[:3]:
print(s["text"], s["attrs"]["href"])
Why
| curl | This | Playwright / headless Chrome | |
|---|---|---|---|
| Static / SSR pages | ✅ but token-heavy | ✅ low-token BlockMap | overkill |
SPA-shell sites (with exec_scripts) |
❌ | ⚠️ partial | ✅ |
| Bot-walled (cookie handoff) | ❌ | ✅ | ✅ |
| Run in Lambda / Workers / edge | ✅ | ✅ | ❌ Chrome too big |
| Per-page cost at 100K/day | ~free | ~free | $$$ |
| LLM-shaped output | DIY parse | ✅ inline BlockMap | DIY parse |
What it does
navigate(url)— fetch, parse, return{status, url, bytes, headers, blockmap, challenge}. Withexec_scripts=True, runs page JS in QuickJS (bounded by a 30s watchdog so it can't wedge).query(selector)— CSS query →[{ref, tag, attrs, text}]. Refs are stable handles for click/type/submit.extract()— auto-strategy structured data: tries JSON-LD →__NEXT_DATA__→ Nuxt → OpenGraph → microdata → text fallback, returns highest-confidence hit.click(ref)/type(ref, text)/submit(ref)— interaction. POST and GET forms supported. Checkboxes/radios tracked.cookies_set(...)— paste cookies from a real Chrome session to bypass bot detection (Cloudflare, PerimeterX, Datadome). Solve once, replay forever.
Full RPC reference, BlockMap shape, challenge detection, profile system, and architecture: github.com/protostatis/unbrowser.
Honest limits
- Heavy framework SPAs (Ember/React) often don't auto-mount inside QuickJS even with
exec_scripts=True— the watchdog ensures it returns, checkdensity.likely_js_filledto decide whether to escalate. - No screenshots (out of scope by design).
- Hardest-tier anti-bot (FingerprintJS Pro, Kasada, advanced Akamai BMP) needs the cookie handoff path. The binary detects and labels the challenge for you.
License
Apache-2.0.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pyunbrowser-0.0.5.tar.gz.
File metadata
- Download URL: pyunbrowser-0.0.5.tar.gz
- Upload date:
- Size: 12.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
26c6b3032b8679262e9b607b988f0034e79e23cc1452c0180adfcbd251103761
|
|
| MD5 |
c45f7f7d3fd41a3f70c5f1a695bcafba
|
|
| BLAKE2b-256 |
74fccc779f6b2fb4a42b256ae9db49063fd15cd8fb2ee62f3d099938d25618f1
|
Provenance
The following attestation bundles were made for pyunbrowser-0.0.5.tar.gz:
Publisher:
release.yml on protostatis/unbrowser
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pyunbrowser-0.0.5.tar.gz -
Subject digest:
26c6b3032b8679262e9b607b988f0034e79e23cc1452c0180adfcbd251103761 - Sigstore transparency entry: 1425257706
- Sigstore integration time:
-
Permalink:
protostatis/unbrowser@dacbdf2587f1b92731d07538b2d7d33fb1046072 -
Branch / Tag:
refs/tags/v0.0.5 - Owner: https://github.com/protostatis
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@dacbdf2587f1b92731d07538b2d7d33fb1046072 -
Trigger Event:
push
-
Statement type:
File details
Details for the file pyunbrowser-0.0.5-py3-none-manylinux_2_35_x86_64.whl.
File metadata
- Download URL: pyunbrowser-0.0.5-py3-none-manylinux_2_35_x86_64.whl
- Upload date:
- Size: 4.1 MB
- Tags: Python 3, manylinux: glibc 2.35+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
802de3707822724831b842085111cbd89bbae3c9041b2031ef85fa85f38221c3
|
|
| MD5 |
85680786cdaeaadaeaa54be691586b20
|
|
| BLAKE2b-256 |
79d8b55086e7d6e75138f770b5412254b2b4779e3b05c9838e2921b9bb12529b
|
Provenance
The following attestation bundles were made for pyunbrowser-0.0.5-py3-none-manylinux_2_35_x86_64.whl:
Publisher:
release.yml on protostatis/unbrowser
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pyunbrowser-0.0.5-py3-none-manylinux_2_35_x86_64.whl -
Subject digest:
802de3707822724831b842085111cbd89bbae3c9041b2031ef85fa85f38221c3 - Sigstore transparency entry: 1425257920
- Sigstore integration time:
-
Permalink:
protostatis/unbrowser@dacbdf2587f1b92731d07538b2d7d33fb1046072 -
Branch / Tag:
refs/tags/v0.0.5 - Owner: https://github.com/protostatis
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@dacbdf2587f1b92731d07538b2d7d33fb1046072 -
Trigger Event:
push
-
Statement type:
File details
Details for the file pyunbrowser-0.0.5-py3-none-macosx_11_0_arm64.whl.
File metadata
- Download URL: pyunbrowser-0.0.5-py3-none-macosx_11_0_arm64.whl
- Upload date:
- Size: 3.6 MB
- Tags: Python 3, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0f8d7ac41c9f3529a88dcbac49d523e168a7cebed4c177751df75f807ab89e55
|
|
| MD5 |
2235e213bd7ecf1ff660e9c3e61b4127
|
|
| BLAKE2b-256 |
7d222b6d0e2a915786f31e71e6503f985c15061e3f3a35087ba328d51e971536
|
Provenance
The following attestation bundles were made for pyunbrowser-0.0.5-py3-none-macosx_11_0_arm64.whl:
Publisher:
release.yml on protostatis/unbrowser
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pyunbrowser-0.0.5-py3-none-macosx_11_0_arm64.whl -
Subject digest:
0f8d7ac41c9f3529a88dcbac49d523e168a7cebed4c177751df75f807ab89e55 - Sigstore transparency entry: 1425257769
- Sigstore integration time:
-
Permalink:
protostatis/unbrowser@dacbdf2587f1b92731d07538b2d7d33fb1046072 -
Branch / Tag:
refs/tags/v0.0.5 - Owner: https://github.com/protostatis
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@dacbdf2587f1b92731d07538b2d7d33fb1046072 -
Trigger Event:
push
-
Statement type:
File details
Details for the file pyunbrowser-0.0.5-py3-none-macosx_10_12_x86_64.whl.
File metadata
- Download URL: pyunbrowser-0.0.5-py3-none-macosx_10_12_x86_64.whl
- Upload date:
- Size: 3.9 MB
- Tags: Python 3, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0ec8365f75442ea2954b43c21d1d382ed8e463d186b5cc94884382c5f67d9351
|
|
| MD5 |
943b269b601a5984cf318cd1220bbc65
|
|
| BLAKE2b-256 |
2382be10489005950de9a7070430510e6158be721e8803a45a0e9b69aa9fd696
|
Provenance
The following attestation bundles were made for pyunbrowser-0.0.5-py3-none-macosx_10_12_x86_64.whl:
Publisher:
release.yml on protostatis/unbrowser
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pyunbrowser-0.0.5-py3-none-macosx_10_12_x86_64.whl -
Subject digest:
0ec8365f75442ea2954b43c21d1d382ed8e463d186b5cc94884382c5f67d9351 - Sigstore transparency entry: 1425257836
- Sigstore integration time:
-
Permalink:
protostatis/unbrowser@dacbdf2587f1b92731d07538b2d7d33fb1046072 -
Branch / Tag:
refs/tags/v0.0.5 - Owner: https://github.com/protostatis
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@dacbdf2587f1b92731d07538b2d7d33fb1046072 -
Trigger Event:
push
-
Statement type: