yfinance — Yahoo Finance Market Data Connector
The most popular open-source Yahoo Finance connector — historical prices, fundamentals, options chains, and real-time quotes as pandas DataFrames.
yfinance — Yahoo Finance Market Data Connector
yfinance is the de-facto open-source connector for Yahoo Finance data, providing easy access to OHLCV price history, dividends, splits, fundamental data (balance sheet, income statement, cash flow), options chains, analyst ratings, and real-time quotes — all as pandas DataFrames.
Key Features
- Historical OHLCV data for equities, ETFs, indices, forex, crypto, futures
- Fundamental data: financials, balance sheet, cash flow, earnings calendar
- Options chain data (calls and puts)
- Real-time quotes and news headlines
- Batch download for multiple tickers in one call
- Proxy support and rate-limit friendly
Quick Start
import yfinance as yf
# Single ticker
msft = yf.Ticker("MSFT")
print(msft.history(period="1y").tail())
print(msft.info["trailingPE"])
# Batch download
df = yf.download(["AAPL","GOOG","AMZN"], start="2023-01-01", end="2024-12-31")
print(df["Close"])
npx ai-supply add yfinance-market-data-connector
Curated mirror of the open-source yfinance (Apache-2.0). Get it from the source.
Compromise signals — malicious or tampered code (leaked secrets, backdoors, a dropped executable) — reduce the score, and known dependency CVEs carry a bounded penalty (they warrant review but never QUARANTINE — update the dependency to clear). Other dangerous-by-capability traits are risk surface, expected for some capabilities. Every finding is mapped to its OWASP control below.
Findings mapped to the OWASP Top 10 for LLM Applications (2025) and the OWASP Machine Learning Security Top 10. Expand any flagged control for the exact findings — compromise reduces the score; expected/risk-surface do not, except a known CVE, which carries a small bounded penalty (high/critical → Review).
The same gate an agent runs before installing (POST /api/v1/trust/yfinance-market-data-connector/check). Click a policy:
Consume yfinance — Yahoo Finance Market Data Connector programmatically. Authenticate with an API key or session — see Authorize an agent.
# Agents: CHECK BEFORE YOU INSTALL (no auth) — score, grade, level, capability manifest
curl https://ai-supply.store/api/v1/trust/yfinance-market-data-connector
# Gate against your org policy (returns { pass, violations })
curl -X POST https://ai-supply.store/api/v1/trust/yfinance-market-data-connector/check \
-H "Content-Type: application/json" \
-d '{"minGrade":"B","denyPermissions":["shell"],"denyUnknownEgress":true}'
# CLI
npx ai-supply add yfinance-market-data-connector
# REST (install → download)
curl -X POST https://ai-supply.store/api/v1/listings/yfinance-market-data-connector/install \
-H "Authorization: Bearer $AIM_KEY"
# MCP tool
install_listing({ "slug": "yfinance-market-data-connector" })OpenAPI spec →Curated mirror — latest upstream source. See the repository for tagged releases.