Ecosystem · Free data All ecosystem services yfinance on GitHub ↗
yfinance — free OHLC, no key
The pragmatic Python library for "just give me prices for an Indian ticker". Excellent for what it does.
What it's great at.
pip install yfinance and you're pulling OHLC for any Indian ticker via the
Yahoo Finance suffix convention (TCS.NS, INFY.NS, 500325.BO). No key, no auth, no quota
paperwork. For "give me a daily price series for backtest scaffolding", this is the right tool.
Compose with Genka when you need primary-source fundamentals, concall transcripts, MF analytics, or
properly corp-action-adjusted long-window returns — data Yahoo's pipeline doesn't model.
Decision matrix
| If you need | Pick |
|---|---|
| Free daily OHLC for an NSE/BSE ticker, no signup | yfinance |
| Quick backtest scaffolding in a Jupyter notebook | yfinance |
Multi-ticker download in one call (Python download(...)) | yfinance |
| Reasonably reliable adj-close (Yahoo's adjustment) | yfinance |
| Quarterly XBRL fundamentals from primary source (FY17+) | Genka |
| Concall transcripts with cited LLM Q&A | Genka |
| Mutual fund screener with SEBI taxonomy | Genka |
| Corp-action handling you can audit (factor per event) | Genka |
| Pre-computed indicator panel (RSI, MACD, DMA, multi-window returns) | Genka |
| Stable production dependency (no Yahoo policy risk) | Genka |
What yfinance is great at
- Zero friction. No account, no key, no quota signup. Single
pip install; works in 30 seconds. - Wide coverage. Any ticker Yahoo Finance lists; for India use the
.NS(NSE) or.BO(BSE) suffix. - Bulk download API.
yf.download(['TCS.NS','INFY.NS'], start='2020-01-01')returns a tidy DataFrame. - Yahoo's adjusted close. Built-in
Adj Closecolumn handles splits/dividends per Yahoo's methodology — not always perfect, but a sensible default. - What to be aware of. Yahoo can change response shapes, rate-limit, or break suffixes without warning — yfinance is a community lib reverse-engineering an internal Yahoo endpoint. For production, treat it as best-effort.
Where Genka complements yfinance
- Primary-source XBRL fundamentals.
/companies/{symbol}/ratios,/balance-sheets,/cash-flow-statements— sourced directly from NSE filings, not scraped from Yahoo's summary page. - Concall corpus. ~23,000 transcripts; BM25 + grounded Q&A. Yahoo doesn't have these.
- MF analytics. 4,700 funds, SEBI taxonomy, 20y NAV, screener, backtester — Yahoo's MF coverage is thin for Indian schemes.
- Auditable corp actions.
/prices/{symbol}/corp-actionsreturns each split/bonus/dividend with a numericfactor. Long-window returns ship in two flavours (raw and_adj) so you see when adjustment matters. - Production stability. Versioned API contract (
genka-Versionheader) and a published deprecation policy. Code that pinned2026-04-25-caracalstill works in three years.
Compose them
yfinance for the quick prototype, Genka for the production dependency:
# Prototype: yfinance for fast price exploration import yfinance as yf df = yf.download("TCS.NS", start="2020-01-01") # Production / agent loop: Genka for stability + depth import requests HDR = {"X-API-Key": os.environ["GENKA_API_KEY"]} prices = requests.get( "https://genka.dev/v1/prices", headers=HDR, params={"symbols": "TCS", "from": "2020-01-01"} ).json() # And get the indicator panel + fundamentals Yahoo doesn't compute: panel = requests.get("https://genka.dev/v1/prices/TCS/latest", headers=HDR).json() ratios = requests.get("https://genka.dev/v1/companies/TCS/ratios", headers=HDR).json()
Relevant Genka endpoints
GET /v1/prices?symbols=A,B&from=1995-01-02— 30y NSE bhavcopy as JSONGET /v1/prices/{symbol}/latest— pre-computed indicator panel (CA-adjusted)GET /v1/prices/{symbol}/corp-actions— auditable corp-action streamGET /v1/companies/{symbol}/ratios— quarterly fundamentals from XBRLPOST /v1/concalls/answer— grounded Q&A across 23k transcripts
Full catalog: /llms.txt
Working with yfinance — gotchas
- Yahoo can rate-limit hard. yfinance reverse-engineers an internal Yahoo endpoint. During heavy use you may get 429s or empty payloads; back off, retry with jitter, or batch via
yf.download(['TCS.NS', 'INFY.NS', ...]). - .NS for NSE, .BO for BSE. Use
RELIANCE.NSfor NSE,500325.BOfor BSE (numeric BSE script code). Some illiquid tickers exist on only one suffix; if NSE returns nothing, try BSE. - Adj Close vs Close.
Adj Closeapplies Yahoo's split + dividend adjustment;Closeis raw. For backtests useAdj Close; for matching exchange records useClose. - Production reliability is best-effort. Yahoo can change the underlying API shape without notice and yfinance breaks until a maintainer ships a fix. For production loops, mirror what you need into your own store.
Other ecosystem services