robin-stocks
A Python wrapper around the Robinhood API
What it is and what it does
Robin-stocks is a Python wrapper that abstracts the APIs of three major financial platforms—Robinhood, Gemini, and TD Ameritrade—into a unified interface. It lets you query real-time stock, options, and cryptocurrency data, retrieve account information, and execute trades programmatically without writing direct HTTP calls to each broker's API.
The library is designed for developers building trading algorithms, robo-investors, or financial analysis tools. It depends on requests for HTTP communication, pyotp for two-factor authentication, python-dotenv for credential management, and cryptography for secure operations. The package requires Python 3.9 or later and installs with low friction.
Use it for:
- Build a robo-investor that automatically rebalances a portfolio across stocks and crypto on a schedule.
- Fetch real-time cryptocurrency prices from Gemini and trigger alerts or trades based on technical indicators.
- Retrieve historical price data from TD Ameritrade to backtest trading strategies before deploying them.
- Monitor open orders and account positions across Robinhood without logging into the web interface.
- Aggregate market data from multiple brokers into a single dashboard or analysis tool.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides a Python interface to the Robinhood, Gemini, and TD Ameritrade APIs for querying stocks, options, and cryptocurrency data, and executing trades.
Yes, with conditions. The package is well-maintained enough for learning and experimentation—it has 2109 stars and recent commits—but the 453-day gap since the last release and aging maintenance status suggest it may lag behind broker API changes. Use it for personal projects, backtesting, and algorithmic trading, but verify that the specific broker APIs you need are still functional before deploying to production. No known security vulnerabilities.
Install
robin-stocks on PyPI
pip
pip install robin-stocksuv
uv add robin-stockspoetry
poetry add robin-stocksInstalling robin-stocks
Before you install
Low install friction with four common dependencies (requests, pyotp, python-dotenv, cryptography). Maintenance status is aging—last release was 453 days ago, though the repository remains active with 2109 stars and a recent commit on 2026-02-11.
License in practice
MIT license is permissive, allowing commercial use, modification, and distribution with minimal restrictions—suitable for most use cases.
Quickstart
pip install robin_stocks
import robin_stocks.robinhood as rh
import robin_stocks.gemini as gem
import robin_stocks.tda as tda
# Example calls
btc_ticker = gem.get_pubticker("btcusd")
open_orders = rh.get_all_open_crypto_orders()
price_history = tda.get_price_history("tsla")
Requires Python 3.9 or later. Authentication with Robinhood, Gemini, or TD Ameritrade requires API credentials and may require two-factor authorization setup.
Verify before relying
- Whether the package still maintains active support for all three APIs (Robinhood, Gemini, TD Ameritrade) given the 453-day gap since last release.
- Current status of Robinhood API compatibility, as Robinhood has made breaking changes to its unofficial API in the past.
- Whether all documented functions remain functional or if some endpoints have been deprecated by the brokers.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 4 — requests, pyotp, python-dotenv, cryptography |
| Maintenance | aging — 453 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 100,294/month — #12,994 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: robin_stocks-3.4.0-py3-none-any.whl
Keywords: robinhood, robin stocks, finance app, stocks, options, trading, investing
Tags
More Internet packages
Botocore provides low-level, data-driven access…
permissive · top 100 on PyPI
aiobotocoreProvides an async client for AWS services using…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
filelockProvides a platform-independent file locking…
permissive · top 100 on PyPI
fastapiFastAPI is a Python web framework for building…
permissive · top 100 on PyPI
googleapis-common-protosProvides common Protocol Buffer message…
permissive · top 100 on PyPI
shioajiShioaji is a trading API for Taiwan's financial…
unclear · top 15,000 on PyPI
smartapi-pythonA Python client library for Angel Broking's…
unclear · top 15,000 on PyPI
tradingview-screenerQuery TradingView's screener API to retrieve…
permissive · top 15,000 on PyPI
tdxpyTdxPy provides a pure-Python interface to read…
permissive · top 15,000 on PyPI
alpaca-pyAlpaca-py is the official Python SDK for…
permissive · top 5,000 on PyPI
yahooqueryRetrieves financial data from Yahoo Finance…
permissive · top 15,000 on PyPI
fyers-apiv3Official Python client library for the Fyers…
permissive · top 15,000 on PyPI
metatrader5Connects Python to MetaTrader 5 Terminal to…
permissive · top 15,000 on PyPI
finvizfinanceScrapes financial data from FinViz website,…
permissive · top 15,000 on PyPI
finnhub-pythonFinnhub-python is a client library for the…
permissive · top 15,000 on PyPI