Skip to main content

CAPTCHA guide

Cap

Open-source proof-of-work widget that sites host themselves as a lighter Turnstile.

Difficulty: Low
Open source
Exploded concept drawing of how the Cap challenge is built

Cap is an open-source proof-of-work CAPTCHA that sites host themselves, built as a lighter take on Cloudflare Turnstile. The visitor sees a small "Verify" widget while a Web Worker grinds through a SHA-256 puzzle, and the server then checks a one-time token. Since there is no image task, the simplest route is to let the widget finish and keep the token it produces.

How to identifyLink to How to identify

  • A <cap-widget> custom element, often with data-cap-api-endpoint="..."
  • Attributes like data-cap-api-endpoint, data-cap-worker-count and data-cap-hidden-field-name
  • A hidden cap-token input (sites can rename it)
  • A "Verify" button that briefly shows progress
  • The script from https://cdn.jsdelivr.net/npm/@cap.js/widget, or a self-hosted copy
  • Requests to the site's /challenge and /redeem endpoints

How it worksLink to How it works

  1. The widget asks the site's Cap endpoint for a challenge.
  2. One or more Web Workers solve the SHA-256 proof-of-work.
  3. The solution is exchanged for a token, written into the hidden cap-token field.
  4. A solve event fires with the token in event.detail.token.
  5. The backend checks it with @cap.js/server or the standalone Docker service.
  6. Every token is tied to its challenge, short-lived and usable once.

Free & open-source bypass methodsLink to Free & open-source bypass methods

Tool What it does Success Rate Link
Official widget Loads the widget and waits for solve or cap-token ~100% tiagorangel1/cap
@cap.js/solver Solves the proof-of-work server-side in Node.js ~100% Cap solver docs
Playwright / DrissionPage Runs the widget in a real browser and reads the hidden field ~100% microsoft/playwright-python · g1879/DrissionPage
Node worker script Re-creates the SHA-256 loop for headless pipelines ~100% tiagorangel1/cap

Practical approachLink to Practical approach

  1. Load the page with JavaScript and Web Workers turned on.
  2. Wait for <cap-widget> to appear, and click "Verify" if the site expects it.
  3. Catch the solve event, or poll the hidden cap-token input.
  4. Submit at once, since the token can be used only one time.
  5. If the field has been renamed, the widget's attributes tell you its name.

Practical tipsLink to Practical tips

  • Solving is pure CPU work. Allow enough time and don't let the browser throttle background tabs.
  • The widget needs Web Workers and crypto.subtle, which some locked-down headless profiles switch off.
  • Tokens are verified on the server and can't be faked, but generating a real one locally costs very little.
  • Self-hosted setups may point to their own endpoint: check data-cap-api-endpoint.
  • Cap proves that work was done, not that a human is present. It is not bot management, which is why sites usually pair it with rate limiting.

Skip the solver: let BrowserSolver handle Cap

Website AntiBot runs a real browser session with matching TLS, headers, cookies and IP, clears the challenge, and returns the page. You send a URL, you get HTML back.

For education and authorized testing only. Respect the law, privacy, and the terms of the sites you work with. Difficulty labels are editorial estimates. Adapted from the CC0 community field guide on GitHub.