TA-Lib
Python wrapper for TA-Lib
What it is and what it does
TA-Lib is a Python binding to a widely-used C library for technical analysis of financial market data. It exposes a large collection of indicators (ADX, MACD, RSI, Stochastic, Bollinger Bands, and others) plus candlestick pattern recognition, designed for traders and financial software developers. The wrapper uses Cython and numpy instead of SWIG, aiming for better performance and cleaner integration.
Installation requires the underlying TA-Lib C library to be present on your system first—this is the main friction point. Once installed, you import the module and call indicator functions with price arrays (typically numpy arrays). The package supports Python 3.9 through 3.14 and offers binary wheels for common platforms, though some configurations may require building from source.
Use it for:
- Calculate technical indicators on historical price data for backtesting trading strategies.
- Detect candlestick patterns in OHLC data to identify potential trade signals.
- Build real-time trading systems that compute indicators on incoming market data streams.
- Analyze financial time series with numpy arrays for research or portfolio analysis.
- Integrate technical analysis into a larger trading platform or quantitative finance application.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Python wrapper for the TA-Lib C library providing technical analysis indicators and candlestick pattern recognition for financial market data.
Yes, with conditions. TA-Lib is actively maintained, widely used in trading and finance, has no known vulnerabilities, and offers good performance via Cython. However, you must pre-install the underlying C library on your system—this is non-trivial on some platforms. The unclear license status also warrants verification before use in proprietary work. If you can handle the C library dependency and need a mature indicator library, it is worth installing.
Install
ta-lib on PyPI
pip
pip install ta-libuv
uv add ta-libpoetry
poetry add ta-libInstalling TA-Lib
Before you install
Medium install friction: requires the underlying TA-Lib C library to be pre-installed on your system before installing the Python wrapper. Binary wheels are available for Python 3.9, 3.10, 3.11, 3.12, 3.13, 3.14 on Linux, macOS, and Windows, but compilation from source may be needed on unsupported platforms. Active maintenance with recent release.
License in practice
License status is unclear—no SPDX identifier or raw license text is recorded in the package metadata. Verify the actual license terms before use in proprietary or copyleft-sensitive projects.
Quickstart
pip install TA-Lib
import numpy
close_prices = numpy.array([1.0, 2.0, 3.0])
# Call indicator functions from the installed TA-Lib wrapper
The underlying TA-Lib C library must be installed separately on your system before installing the Python wrapper (e.g., via Homebrew on macOS, MSI on Windows, or from source on Linux).
Verify before relying
- Full list of all 150+ indicators and their exact names.
- Performance improvement claim of 2-4 times faster than SWIG interface—no benchmark data in fact sheet.
- Whether Polars and Pandas integration is built-in or requires separate setup.
- Compatibility of underlying TA-Lib C library version 0.7.1 with all supported Python versions.
Package facts
| License | not declared (unclear) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | medium — platform-specific wheel |
| Runtime dependencies | 2 — build, numpy |
| Maintenance | actively maintained — 29 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 945,941/month — #4,667 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: ta_lib-0.7.1-cp310-cp310-macosx_13_0_x86_64.whl; ta_lib-0.7.1-cp310-cp310-macosx_14_0_arm64.whl; ta_lib-0.7.1-cp310-cp310-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; ta_lib-0.7.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl; ta_lib-0.7.1-cp310-cp310-musllinux_1_2_aarch64.whl; ta_lib-0.7.1-cp310-cp310-musllinux_1_2_x86_64.whl; ta_lib-0.7.1-cp310-cp310-win32.whl; ta_lib-0.7.1-cp310-cp310-win_amd64.whl; ta_lib-0.7.1-cp310-cp310-win_arm64.whl; ta_lib-0.7.1-cp311-cp311-macosx_13_0_x86_64.whl; ta_lib-0.7.1-cp311-cp311-macosx_14_0_arm64.whl; ta_lib-0.7.1-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl; ta_lib-0.7.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl; ta_lib-0.7.1-cp311-cp311-musllinux_1_2_aarch64.whl; ta_lib-0.7.1-cp311-cp311-musllinux_1_2_x86_64.whl; ta_lib-0.7.1-cp311-cp311-win32.whl; ta_lib-0.7.1-cp311-cp311-win_amd64.whl; ta_lib-0.7.1-cp311-cp311-win_arm64.whl; ta_lib-0.7.1-cp312-cp312-macosx_13_0_x86_64.whl; ta_lib-0.7.1-cp312-cp312-macosx_14_0_arm64.whl
Tags
More Mathematics packages
NetworkX provides data structures and…
permissive · top 1,000 on PyPI
kiwisolverkiwisolver is a Python binding to a fast C++…
permissive · top 1,000 on PyPI
sympySymPy is a Python library for symbolic…
permissive · top 1,000 on PyPI
contourpyContourPy calculates contours of 2D…
permissive · top 1,000 on PyPI
torchPyTorch provides GPU-accelerated tensor…
permissive · top 1,000 on PyPI
onnxruntimeonnxruntime loads and executes Open Neural…
permissive · top 1,000 on PyPI
ft-pandas-taProvides 130+ technical analysis indicators and…
permissive · top 15,000 on PyPI
pandas-ta-classicPandas TA Classic provides 193 technical…
permissive · top 15,000 on PyPI
pandas-taProvides over 150 technical analysis indicators…
unclear · top 5,000 on PyPI
taComputes technical analysis indicators (volume,…
permissive · top 5,000 on PyPI
stockstatsAdds technical analysis indicators and…
permissive · top 15,000 on PyPI
technicalTechnical provides a collection of technical…
copyleft · top 15,000 on PyPI
tushareFetches historical and real-time Chinese stock…
permissive · top 15,000 on PyPI
baostockBaoStock retrieves historical China stock…
permissive · top 15,000 on PyPI
yahooqueryRetrieves financial data from Yahoo Finance…
permissive · top 15,000 on PyPI
openbb-tradingeconomicsIntegrates Trading Economics data into the…
agpl · top 15,000 on PyPI