Skip to main content

Data Freshness

yfin returns Yahoo Finance market data through a hosted API. Freshness depends on the market, instrument type, endpoint, session state, and Yahoo Finance availability for that symbol.

What To Expect

Data typeTypical behavior
QuotesBest for current price, day range, volume, market state, and related quote fields.
Historical pricesBest for chart bars over a selected range and interval. Recent intraday bars can update as trading continues.
FundamentalsBest for company profile, valuation, financial statement, and analyst-style data. These fields update less frequently than quotes.
OptionsBest for available expirations and option-chain snapshots. Availability varies by symbol and expiration.
Market summary/timeBest for overview pages and deciding whether a market is open, closed, pre-market, or post-market.

Realtime, Delayed, And Closed Markets

Some symbols may return realtime-looking quote fields while others are delayed or only update during specific sessions. Use response fields such as marketState, regularMarketTime, and the market-time endpoints to display freshness honestly in your app.

For exchange-traded securities, prices may stop changing after the regular or extended trading session ends. For crypto and FX symbols, session behavior can look different because those markets are not tied to the same exchange hours.

Refresh

SDKs and REST calls support refresh for workloads that need a fresh API request.

import yfin

client = yfin.Client(contact="you@example.com")
quote = client.quote(["AAPL", "MSFT"], refresh=True)
const quote = await client.quote(["AAPL", "MSFT"], { refresh: true });

Most applications should avoid forcing refresh on every call. Use it when the user explicitly refreshes a view, when a scheduled job needs a fresh read, or when validating a stale local copy in your own application.

Developer Guidance

  • Show the quote timestamp when data freshness matters to the user.
  • Use /v1/market_time or marketState before assuming an exchange is open.
  • Do not compare quote freshness across asset classes without checking market behavior.
  • Build retry logic around Errors, not around assumptions about a data source.