How to get Yahoo Finance stock data (quotes, fundamentals, financials) without running yfinance
4 Nov 2026 · benthepythondev
If you've ever kept a yfinance script alive, you've probably hit the usual problems: crumb tokens, cookies, and 429 Too Many Requests. The Yahoo Finance Scraper takes a list of ticker symbols and returns one record per ticker. Each record holds only the data blocks you ask for. You don't need a Yahoo account or a Yahoo API key.
What you get
Every record has a symbol and a scraped_at timestamp. The rest depends on the dataTypes you request:
- quote: live price, previous close, open, day high and low, volume, market cap, 50-day and 200-day averages, and the 52-week high and low (11 fields).
- info: the company profile (name, exchange, currency, sector, industry, description, website, employee count, address and phone), valuation ratios (P/E, forward P/E, PEG, price to book, price to sales), dividend yield and rate, beta, EPS, revenue, gross profit, EBITDA, net income, margins, returns, debt to equity, liquidity ratios, free cash flow, and analyst targets with a consensus recommendation (43 fields).
- history: daily OHLCV bars for the
historyPeriodyou set. The README's AAPL test run returned 252 bars for1y. - financials: four years of the income statement, balance sheet and cash flow statement.
- holders: major holders, the top 10 institutions and the top 10 mutual funds.
- recommendations: analyst rating counts by month.
- earnings: past and upcoming earnings dates, each with the EPS estimate and the surprise.
- dividends and splits: the full payment and split history.
- news: up to 20 recent headlines, each with its publisher and a link.
The keys are easier to read than yfinance's. longName becomes name, trailingPE becomes pe_ratio, and fullTimeEmployees becomes employees.
Real example output
Here is an excerpt from a real run with quote and info for AAPL. I removed some fields and shortened the description:
{
"symbol": "AAPL",
"scraped_at": "2026-10-07T07:48:49.947457",
"quote": {
"price": 333.6300048828125,
"previous_close": 332.85,
"volume": 30425700,
"market_cap": 4869056344660.645,
"fifty_day_average": 322.3479998779297,
"year_high": 345.3399963378906,
"year_low": 243.4199981689453
},
"info": {
"name": "Apple Inc.",
"exchange": "NMS",
"currency": "USD",
"sector": "Technology",
"industry": "Consumer Electronics",
"employees": 150000,
"pe_ratio": 38.26032,
"forward_pe": 34.81532,
"dividend_yield": 0.32,
"profit_margin": 0.27618998,
"free_cash_flow": 107721875456,
"target_mean_price": 328.09384,
"recommendation": "buy",
"analyst_count": 39
}
}
The same run returned a second record for MSFT ("Microsoft Corporation", industry "Software - Infrastructure", price 529.2999877929688) with the same layout.
Use cases
1. Screening a watchlist on fundamentals. Pass "AAPL, MSFT, GOOGL" with quote and info, then sort or filter on pe_ratio, profit_margin, debt_to_equity or target_mean_price in a spreadsheet or in code. For a scheduled CSV or Google Sheets setup, see the watchlist-to-spreadsheet guide.
2. Pulling financial statements. Add financials and you get the income statement, balance sheet and cash flow statement in the same record as the quote.
3. Feeding a model with market data. Add history with a historyPeriod for daily prices, or news for recent headlines. Every block goes into that ticker's single record.
4. Replacing a self-hosted yfinance script. The README shows a swap of about ten lines:
from apify_client import ApifyClient
client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("benthepythondev/yahoo-finance-scraper").call(
run_input={"tickers": "AAPL", "dataTypes": ["quote", "info"]})
info = client.dataset(run.default_dataset_id).list_items().items[0]["info"]
That snippet is written for apify-client 3.x. On 2.x, use run["defaultDatasetId"] on the last line.
AI agents can reach the same Actor through the Apify MCP server as benthepythondev/yahoo-finance-scraper. The smallest useful input is {"tickers": "AAPL", "dataTypes": ["quote", "info", "financials"]}.
How to run it
On Apify: open the Actor page, enter your tickers separated by commas, and pick the data blocks you want. Results export to JSON, CSV or Excel. You can also run it on a schedule, call it through the Apify API, or connect it to Make, Zapier or n8n.
As an API on RapidAPI: the same scraper is listed at rapidapi.com/benthepythondev0/api/yahoo-finance-scraper3. Use that listing if you already handle API keys and billing through RapidAPI.
Pricing on Apify
You pay once per ticker record, no matter how many blocks the record contains, plus one Actor Start charge per run. These are the README prices from 2026-11-04:
| Plan | Per ticker record | Actor Start |
|---|---|---|
| Free | $0.005 | $0.00005 |
| Bronze | $0.0045 | $0.000045 |
| Silver | $0.00425 | $0.0000425 |
| Gold and up | $0.004 | $0.00004 |
Errors and empty results cost nothing.
Honest limits
- Plain quotes for a large list are cheaper elsewhere. The README says so directly: if you only need prices for many tickers, a per-row tool costs less. This one pays off when you also want financials, news or history for each ticker.
- Unknown symbols return nothing. A typo or a delisted ticker writes no record and isn't charged. If you check your output against your input list, a missing
symbolmeans Yahoo didn't recognize it. - Numbers come back raw. Prices keep their full float precision (
333.6300048828125), so round them yourself. Market cap appears in bothquoteandinfo, and the two values differ slightly (4869056344660.645 vs 4869056364544). - Check the units before you compare fields. In the sample,
dividend_yieldis 0.32 whileprofit_marginis 0.276. The dividend yield looks like a percentage and the margin looks like a fraction, so confirm the units before mixing them in a formula. - The data comes from Yahoo. What Yahoo shows for a ticker is what you get. Smaller or non-US listings may have fewer filled fields than AAPL or MSFT.
Affiliate if you still need an Apify account: apify.com/?fpr=qolupv. I may earn a commission; the price you pay does not change.