skillfed

2captcha-python

Python module for easy integration with 2Captcha API

2captcha-python v2.1.0 624.0K downloads/30d#5,703 on PyPI790
Permissive license Active released

What it is and what it does

This package wraps the 2Captcha captcha-solving service into a Python client, letting you programmatically submit captchas and receive solutions. It supports a wide range of captcha types—from simple image text recognition to modern challenges like reCAPTCHA, Cloudflare Turnstile, GeeTest, and FunCaptcha—making it useful for automation, testing, and integration workflows that encounter captcha barriers.

The library provides both synchronous and asynchronous interfaces, configurable polling behavior, and support for proxy routing. You instantiate a solver with your API key, call a method matching the captcha type, and receive the solved answer. It depends on requests, httpx, and aiofiles for HTTP communication and async file handling.

Use it for:

  • Automate web scraping workflows that encounter image or reCAPTCHA barriers during data collection.
  • Test web applications and login flows that require captcha solving without manual intervention.
  • Integrate captcha solving into bot automation for account creation or form submission tasks.
  • Build security testing tools that need to bypass captcha protections to assess application robustness.
  • Automate API interactions with services protected by Cloudflare Turnstile or similar modern captcha systems.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

A Python client for the 2Captcha API that automates captcha solving across multiple captcha types including reCAPTCHA, FunCaptcha, GeeTest, Cloudflare Turnstile, and many others.

Yes, if you need to programmatically solve captchas and have a 2Captcha account. The package is actively maintained, has low install friction, carries no known vulnerabilities, and supports a comprehensive set of captcha types. The main constraint is the service cost and the requirement for an external API key; it is not suitable for free or offline captcha solving.

Install

2captcha-python on PyPI

pip

pip install 2captcha-python

uv

uv add 2captcha-python

poetry

poetry add 2captcha-python

Installing 2captcha-python

Before you install

Low friction: pure Python wheel with three common runtime dependencies (requests, httpx, aiofiles). Active maintenance with a recent release 25 days ago and 790 repository stars.

License in practice

MIT license (permissive): you can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions.

Quickstart

pip install 2captcha-python

from 2captcha_python import TwoCaptcha

solver = TwoCaptcha('YOUR_API_KEY')
result = solver.normal('path/to/captcha.jpg')

Requires a 2Captcha API key and account; solving captchas incurs service charges based on 2Captcha's pricing.

Verify before relying

  • Whether async support is production-ready and what performance characteristics it offers.
  • Specific rate limits or request throttling imposed by the 2Captcha service itself.
  • Whether callback-based result delivery is reliable in production environments.
  • Full list of supported captcha types beyond those mentioned in the description excerpt.

Package facts

License not declared (permissive)
Python support supports the current Python release (>=3.8)
Install friction low — pure-Python wheel
Runtime dependencies 3 — requests, httpx, aiofiles
Maintenance actively maintained — 25 days since the last release
Last repo commit
First released
Downloads 624,012/month — #5,703 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: 2captcha_python-2.1.0-py3-none-any.whl

Keywords: 2captcha, captcha, api, captcha solver, reCAPTCHA, FunCaptcha, Geetest, image captcha, Coordinates, Click Captcha, Geetest V4, Lemin captcha, Amazon WAF, Cloudflare Turnstile, Capy Puzzle, MTCaptcha, Friendly Captcha, Tencent, Cutcaptcha, DataDome, VK Captcha, CaptchaFox, Prosopo, cybersiara, Hunt, Alibaba, TSPD, Basilisk

Intended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3Topic :: Scientific/Engineering :: Image RecognitionTopic :: Software Development :: Libraries :: Python ModulesTopic :: Utilities

Tags

captcha solver api client2captcha python integrationrecaptcha automationbypass captcha programmaticallycaptcha solving servicecloudflare turnstile solverautomated captcha recognition
captcha-solvingweb-automationapi-client

More Python Modules packages