Yahoo Finance APIyahoofinance.com ↗
Access real-time stock quotes, OHLCV history, company profiles, and financial news for any ticker via the Yahoo Finance API. 5 endpoints, global exchange coverage.
What is the Yahoo Finance API?
The Yahoo Finance API exposes 5 endpoints covering real-time quotes, historical OHLCV data, company fundamentals, stock news, and ticker search across global exchanges. The get_quote endpoint returns a full market snapshot per ticker — including regularMarketPrice, regularMarketVolume, marketCap, and bid/ask — while get_company_profile delivers structured financial modules down to analyst recommendation keys and PEG ratios.
curl -X GET 'https://api.parse.bot/scraper/4bf1943d-6bf2-4dcc-bc83-994300c2633d/get_quote?symbols=AAPL%2CMSFT' \ -H 'X-API-Key: $PARSE_API_KEY'
Typed, relational, agent-ready
A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.
- Fully typed · autocompletes
- Objects link to objects
- Typed errors & pagination
Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:
uv add parse-sdk uv run parse init uv run parse add --marketplace yahoofinance-com-api
uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.
from parse_apis.yahoo_finance_api import YahooFinance, HistoricalRange, HistoricalInterval
yahoo = YahooFinance()
# Search for tickers matching "Tesla"
for match in yahoo.tickermatches.search(query="Tesla", limit=3):
print(match.symbol, match.long_name, match.exchange, match.quote_type)
# Get a stock and retrieve its real-time quote
aapl = yahoo.stock("AAPL")
for q in aapl.quote():
print(q.symbol, q.regular_market_price, q.market_cap, q.market_state)
# Fetch historical data with enum-typed range and interval
history = aapl.history(range=HistoricalRange.THREE_MONTHS, interval=HistoricalInterval.ONE_DAY)
print(history.symbol, history.currency)
for record in history.history[:3]:
print(record.timestamp, record.open, record.close, record.volume)
# Get company profile
profile = aapl.profile()
print(profile.asset_profile.sector, profile.asset_profile.industry)
print(profile.financial_data.recommendation_key, profile.summary_detail.trailing_pe)
# Get latest news
for article in aapl.news(count=5):
print(article.title, article.publisher, article.provider_publish_time)
Retrieve real-time stock quotes including current price, bid/ask, volume, market cap, and market status for one or more tickers. Supports batch lookups via comma-separated symbols. Each quote carries the full market snapshot visible on the Yahoo Finance quote page.
| Param | Type | Description |
|---|---|---|
| symbolsrequired | string | Comma-separated list of stock ticker symbols (e.g., AAPL,MSFT,TSLA). |
{
"type": "object",
"fields": {
"quotes": "array of Quote objects with real-time market data including regularMarketPrice, regularMarketChange, regularMarketVolume, marketCap, bid, ask, and symbol"
},
"sample": {
"data": {
"quotes": [
{
"ask": 291.94,
"bid": 292.11,
"symbol": "AAPL",
"currency": "USD",
"exchange": "NMS",
"marketCap": 4282539048960,
"shortName": "Apple Inc.",
"marketState": "POST",
"regularMarketPrice": 291.58,
"regularMarketChange": 1.03,
"regularMarketVolume": 49237715
}
]
},
"status": "success"
}
}About the Yahoo Finance API
Quotes and Historical Prices
The get_quote endpoint accepts a comma-separated symbols string, making batch lookups possible in a single request. Each returned Quote object includes regularMarketPrice, regularMarketChange, regularMarketVolume, marketCap, and current market status — matching the snapshot visible on any Yahoo Finance quote page. For time-series data, get_historical_data takes a symbol, an optional interval (from 1-minute intraday up to monthly), and an optional range. It returns an array of PriceRecord objects with timestamp, open, high, low, close, and volume, plus the currency field. Note that intraday intervals (1m–90m) are restricted to shorter ranges (1d–5d).
Company Profiles and Fundamentals
get_company_profile returns four structured modules for a given ticker. assetProfile contains the business summary, sector, industry, headquarters address, and a companyOfficers array. financialData provides totalRevenue, profitMargins, currentPrice, and recommendationKey. summaryDetail covers dividendRate, dividendYield, trailingPE, marketCap, and 52-week range. defaultKeyStatistics adds enterpriseValue, forwardPE, pegRatio, sharesOutstanding, and bookValue.
News and Search
get_stock_news accepts a symbol and an optional count parameter, returning an array of NewsArticle objects each with title, publisher, link, providerPublishTime, and relatedTickers. This makes it straightforward to surface recent coverage for any equity. The search_tickers endpoint accepts a free-text query and returns matching TickerMatch objects with symbol, shortname, longname, exchange, quoteType, sector, and industry — covering equities, ETFs, and other instrument types across global exchanges.
The Yahoo Finance API is a managed, monitored endpoint for yahoofinance.com — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when yahoofinance.com changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.
This isn't an official yahoofinance.com API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.
Will this API break when the source site changes?+
Is this an official API from the source site?+
Can I fix or extend this API myself if I need a new endpoint or field?+
What happens if I call an endpoint that has an issue?+
- Build a portfolio tracker that polls
get_quotefor liveregularMarketPriceandmarketCapacross a watchlist. - Feed
get_historical_dataOHLCV records into a charting library or backtesting framework. - Populate a company research page using
assetProfile,financialData, anddefaultKeyStatisticsfromget_company_profile. - Aggregate financial news headlines and publisher metadata from
get_stock_newsfor a sentiment analysis pipeline. - Resolve user-entered company names to canonical ticker symbols using
search_tickersbefore querying other endpoints. - Screen dividend-paying stocks by comparing
dividendYieldandtrailingPEvalues fromsummaryDetailacross a list of tickers. - Monitor analyst consensus shifts by tracking
recommendationKeychanges fromfinancialDataover time.
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 100 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does Yahoo Finance have an official developer API?+
What does `get_company_profile` return beyond the basic price data?+
get_company_profile returns four modules: assetProfile (sector, industry, business summary, officers), financialData (revenue, profit margins, analyst recommendation), summaryDetail (dividend yield, P/E, 52-week range), and defaultKeyStatistics (enterprise value, forward P/E, PEG ratio, shares outstanding). It does not duplicate real-time price data — use get_quote for live pricing.Are intraday intervals available for all date ranges in `get_historical_data`?+
Does the API return options chains or futures data?+
Can I retrieve earnings call transcripts or SEC filing data through this API?+
get_company_profile and get_stock_news, but earnings transcripts and SEC filings are not part of the response shape. You can fork this API on Parse and revise it to add endpoints targeting that content.