# Yahoo Finance Scraper - Quotes, Fundamentals, Options & News (`parsebird/yahoo-finance-scraper`) Actor

Extract Yahoo Finance data: live quotes, historical OHLCV candles, fundamentals, analyst ratings, options chains, news, ticker search, and screeners. Export JSON, CSV, Excel via API.

- **URL**: https://apify.com/parsebird/yahoo-finance-scraper.md
- **Developed by:** [ParseBird](https://apify.com/parsebird) (community)
- **Categories:** News, Automation, Agents
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.70 / 1,000 record scrapeds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### Yahoo Finance Scraper - Quotes, Fundamentals, Options & News

Yahoo Finance Scraper pulls structured market data straight from [Yahoo Finance](https://finance.yahoo.com): live quotes, historical OHLCV prices, fundamentals, analyst ratings, options chains, news, ticker search, and predefined screeners for stocks, ETFs, indices, and crypto.

<table><tr>
<td style="border-left:4px solid #1C1917;padding:12px 16px;font-weight:600">One actor, eight operations — quotes, historical candles, 34-line-item fundamentals, analyst ratings, options chains, news, search, and screeners — for any Yahoo Finance ticker, index, or crypto pair.</td>
</tr></table>

<img src="https://s.yimg.com/cv/apiv2/cv/apiv2/social/images/yahoo-finance-default-logo.png" alt="Yahoo Finance logo" width="180">

##### Copy to your AI assistant

Copy this block into ChatGPT, Claude, Cursor, or any LLM to start using this actor.

```
parsebird/yahoo-finance-scraper on Apify. Call: ApifyClient("TOKEN").actor("parsebird/yahoo-finance-scraper").call(run_input={"operation":"quotes","tickers":["AAPL","MSFT","BTC-USD","^GSPC"]}), then client.dataset(run["defaultDatasetId"]).list_items().items for results. Key inputs: operation (string, one of quotes|historical|fundamentals|analysis|options|news|search|screener, default "quotes"), tickers (array of symbols or Yahoo quote URLs), query (string, for search/news), range (string, historical lookback, default "1mo"), interval (string, candle size, default "1d"), startDate/endDate (YYYY-MM-DD, overrides range), includeEvents (boolean, adds dividend/split rows), optionsExpirations (integer, default 1), screenerId (string, default "day_gainers"), maxItems (integer cap), proxy (object, defaults to residential Apify Proxy). Output fields vary by operation: quotes return 60+ live fields (regularMarketPrice, marketCap, trailingPE...), historical returns OHLCV candles, fundamentals returns 34 line items per annual/quarterly period, options returns per-contract Greeks and pricing, news returns article metadata. Full actor spec: GET https://api.apify.com/v2/acts/parsebird~yahoo-finance-scraper (Bearer TOKEN). Get token: https://console.apify.com/account/integrations
```

### What is Yahoo Finance Scraper?

Yahoo Finance Scraper is an [Apify Actor](https://apify.com/actors) that acts as a **Yahoo Finance API alternative** — it extracts the same data that powers [finance.yahoo.com](https://finance.yahoo.com) quote pages, chart tabs, statistics tabs, options tabs, and news feeds, and returns it as clean structured rows. Point it at any stock, ETF, market index, or crypto pair and it handles Yahoo's session/crumb authentication for you.

Use it as a **Yahoo Finance data scraper**, a **stock market API**, or a repeatable data pipeline for research, screening, and monitoring. Results download as JSON, CSV, Excel, XML, or HTML, or you can pull them programmatically through the [Apify API](https://docs.apify.com/api/v2).

### What can Yahoo Finance Scraper do?

- 📈 Fetch **live quotes** — price, change %, market cap, P/E, 52-week range, dividend yield — for any ticker, index, or crypto pair
- 🕯️ Pull **historical OHLCV candles** from 1-minute to 3-month intervals, with optional dividend and split event rows
- 📊 Extract **fundamentals**: 34 annual and quarterly statement line items per period — revenue, gross profit, EBIT, free cash flow, total debt, stockholders' equity, and more
- 🎯 Get **analyst ratings**: price targets, recommendation trend, earnings estimate revisions, and upgrade/downgrade history
- 🔗 Pull full **options chains** across multiple expiration dates, with strike, bid/ask, implied volatility, and open interest
- 📰 Search **news** by ticker or free text, with publisher, link, and related-ticker metadata
- 🔍 Run ticker/company **search** or pull predefined **screeners** (day gainers, day losers, most active, and more)
- ⚙️ Run on demand, schedule recurring runs, or connect results to Apify [integrations](https://apify.com/integrations) like Google Sheets, Zapier, Make, and webhooks
- 📤 Export data in JSON, CSV, Excel, XML, RSS, or HTML from the Apify dataset

### What data can you extract from Yahoo Finance?

| Field | Operation | Description |
|-------|-----------|-------------|
| `regularMarketPrice` / `marketCap` / `trailingPE` | quotes | Live price and valuation snapshot |
| `targetMeanPrice` / `recommendationKey` | quotes, analysis | Analyst consensus target and rating |
| `open`, `high`, `low`, `close`, `adjClose`, `volume` | historical | OHLCV per candle, adjusted close included |
| `type` = `dividend` / `split` | historical | Corporate action rows when `includeEvents` is on |
| `period` + `endDate` | fundamentals | Annual or quarterly statement period |
| `totalRevenue` … `freeCashFlow` | fundamentals | 34 statement line items per period |
| `strike` / `impliedVolatility` / `openInterest` | options | Per-contract options data |
| `earningsTrend` / `upgradeDowngradeHistory` | analysis | EPS estimate revisions and rating changes |
| `publishedAt` / `relatedTickers` | news | Article metadata |

### Input parameters

| Parameter | Type | Required | Default | Description |
|-----------|------|----------|---------|-------------|
| `operation` | string | No | `quotes` | One of `quotes`, `historical`, `fundamentals`, `analysis`, `options`, `news`, `search`, `screener` |
| `tickers` | array of strings | Depends\* | — | Symbols or Yahoo quote URLs, e.g. `AAPL`, `^GSPC`, `BTC-USD` |
| `query` | string | No | — | Free text for `search` (also usable for `news`) |
| `range` | string | No | `1mo` | Historical lookback: `1d` … `10y`, `ytd`, `max` |
| `interval` | string | No | `1d` | Candle size: `1m` … `3mo` |
| `startDate` / `endDate` | string | No | — | Explicit `YYYY-MM-DD` window (overrides `range`) |
| `includeEvents` | boolean | No | `false` | Emit dividend & split rows too |
| `optionsExpirations` | integer | No | `1` | Expiration dates per ticker for `options` |
| `screenerId` | string | No | `day_gainers` | Predefined screener to pull |
| `maxItems` | integer | No | — | Hard cap on rows for the run |
| `proxy` | object | No | Residential (built-in) | Optional proxy override |

\*`tickers` is required for `quotes`, `historical`, `fundamentals`, `analysis`, and `options`. `search` and `news` accept either `tickers` or `query`.

**Example input (quotes):**

```json
{
  "operation": "quotes",
  "tickers": ["AAPL", "MSFT", "BTC-USD", "^GSPC"]
}
```

**Example input (historical with dividends/splits):**

```json
{
  "operation": "historical",
  "tickers": ["TSLA"],
  "range": "5y",
  "interval": "1d",
  "includeEvents": true
}
```

### Output example

`quotes` (truncated — 60+ fields per row):

```json
{
  "symbol": "AAPL",
  "longName": "Apple Inc.",
  "quoteType": "EQUITY",
  "currency": "USD",
  "exchange": "NasdaqGS",
  "marketState": "REGULAR",
  "regularMarketPrice": 333.74,
  "regularMarketChangePercent": 1.02,
  "marketCap": 3160000000000,
  "trailingPE": 32.9,
  "forwardPE": 28.4,
  "fiftyTwoWeekHigh": 360.1,
  "dividendYield": 0.0051,
  "beta": 1.21,
  "totalRevenue": 416160000000,
  "grossMargins": 0.469,
  "freeCashflow": 98767000000,
  "recommendationKey": "buy",
  "numberOfAnalystOpinions": 43,
  "targetMeanPrice": 318.25,
  "sector": "Technology",
  "industry": "Consumer Electronics",
  "website": "https://www.apple.com"
}
```

`historical`:

```json
{
  "symbol": "AAPL",
  "type": "candle",
  "date": "2026-06-18T13:30:00.000Z",
  "open": 298.11,
  "high": 300.57,
  "low": 295.62,
  "close": 298.01,
  "adjClose": 298.01,
  "volume": 85962200,
  "interval": "1d",
  "currency": "USD"
}
```

`fundamentals`:

```json
{
  "symbol": "AAPL",
  "period": "annual",
  "endDate": "2025-09-30",
  "currency": "USD",
  "totalRevenue": 416160000000,
  "grossProfit": 195234000000,
  "netIncome": 112010000000,
  "eBIT": 133050000000,
  "freeCashFlow": 98767000000,
  "totalDebt": 106629000000,
  "stockholdersEquity": 73733000000,
  "capitalExpenditure": -12715000000
}
```

`options`:

```json
{
  "symbol": "AAPL",
  "underlyingPrice": 333.74,
  "type": "call",
  "contractSymbol": "AAPL260720C00205000",
  "expiration": "2026-07-20T00:00:00.000Z",
  "strike": 205,
  "lastPrice": 127.1,
  "bid": 127.35,
  "ask": 130.5,
  "volume": 2,
  "openInterest": 2,
  "impliedVolatility": 2.83
}
```

`news`:

```json
{
  "query": "TSLA",
  "title": "Tesla Remains One of the Last Great Founder-Led Tech Giants…",
  "publisher": "Motley Fool",
  "link": "https://finance.yahoo.com/m/…/elon-musk%27s-tesla-remains-one.html",
  "publishedAt": "2026-07-19T19:25:00.000Z",
  "relatedTickers": ["TSLA", "MSFT", "NVDA"]
}
```

Download in JSON, HTML, CSV, or Excel from the dataset page, or fetch rows programmatically through the API.

### How to scrape Yahoo Finance data

1. Open Yahoo Finance Scraper on Apify and click **Try for free**.
2. Pick an `operation` (quotes, historical, fundamentals, analysis, options, news, search, or screener).
3. Enter `tickers` (symbols or Yahoo quote URLs) or a `query`, and adjust `range`/`interval`/`maxItems` as needed.
4. Start the run and wait for the dataset to populate — most runs finish in seconds.
5. Download results as JSON, CSV, Excel, HTML, XML, or RSS, or open them straight in Google Sheets.
6. Automate it with [Apify scheduling](https://docs.apify.com/platform/schedules), [integrations](https://apify.com/integrations), or the [Apify API](https://docs.apify.com/api/v2).

### How to use the Yahoo Finance API in Python

```python
from apify_client import ApifyClient

client = ApifyClient("YOUR_APIFY_TOKEN")

run = client.actor("parsebird/yahoo-finance-scraper").call(run_input={
    "operation": "historical",
    "tickers": ["TSLA"],
    "range": "5y",
    "interval": "1d",
    "includeEvents": True,
})

items = client.dataset(run["defaultDatasetId"]).list_items().items
print(items[:2])
```

### How to use the Yahoo Finance API in JavaScript

```javascript
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: 'YOUR_APIFY_TOKEN' });

const run = await client.actor('parsebird/yahoo-finance-scraper').call({
    operation: 'quotes',
    tickers: ['AAPL', 'MSFT', 'BTC-USD', '^GSPC'],
});

const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);
```

### Use cases

- **Portfolio tracking** — Pull live quotes for a watchlist and feed them into dashboards or alerts
- **Backtesting** — Download years of OHLCV historical prices with adjusted close and corporate actions
- **Fundamental screening** — Compare revenue, margins, free cash flow, and debt across annual or quarterly periods
- **Sentiment and news monitoring** — Track headlines and related tickers for specific companies
- **Options analysis** — Pull full options chains to model implied volatility or open interest across strikes
- **Market scanning** — Run Yahoo's predefined screeners (day gainers, most active) on a schedule

### How it works

1. Opens a Yahoo Finance session and negotiates the crumb/cookie pair Yahoo's own frontend uses to authenticate API calls
2. Resolves each ticker input — plain symbols or full Yahoo quote URLs — to a clean symbol
3. Calls the operation-specific Yahoo Finance endpoint (quote, chart, fundamentals timeseries, quoteSummary, options chain, or search/screener)
4. Normalizes the response into flat rows: candles, statement periods, option contracts, or article records
5. Pushes rows to the dataset and stops early once `maxItems` or your spending limit is reached

### How much does it cost to scrape Yahoo Finance?

Yahoo Finance Scraper uses pay-per-event pricing — you pay per row returned, not per API call made internally.

| Event | Price per event | Price per 1,000 |
|-------|-----------------|-----------------|
| `record-scraped` | $0.0009 (Free) / $0.0008 (Bronze, Silver) / $0.0007 (Gold) | **$0.90 / $0.80 / $0.70** |

A `quotes` run for 4 tickers costs a fraction of a cent. A `historical` run for 1 ticker over 5 years (~1,260 daily candles) costs roughly $1.13 on the Free plan. Apify's free trial credits cover typical test runs.

### Is it legal to scrape Yahoo Finance data?

Yahoo Finance Scraper extracts publicly available market data from the same endpoints Yahoo Finance's own website uses to render quote, chart, and options pages. Scraping publicly accessible data is generally lawful, but you're responsible for how you use the results — always review [Yahoo's Terms of Service](https://legal.yahoo.com/us/en/yahoo/terms/otos/index.html) and Apify's guide on [the legality of web scraping](https://blog.apify.com/is-web-scraping-legal/) before running large or automated workloads. This actor does not provide investment advice.

### Related ParseBird finance and market data scrapers

| Actor | Best for |
|-------|----------|
| [DexScreener Crypto Scraper](https://apify.com/parsebird/dexscreener-crypto-scraper) | Real-time DEX token prices, liquidity, and volume |
| [Congress Stock Trades & Financial Disclosures](https://apify.com/parsebird/congress-stock-trades-scraper) | U.S. congressional stock trade disclosures |
| [Superinvestor Portfolio Scraper](https://apify.com/parsebird/dataroma-superinvestor-scraper) | Dataroma superinvestor holdings and allocations |

### FAQ

**Do I need a Yahoo Finance API key?**
No. Yahoo doesn't offer a public, documented finance API. This actor handles the session/crumb handshake Yahoo's own frontend uses, so you don't need any credentials.

**Which tickers are supported?**
Any symbol Yahoo Finance recognizes: stocks (`AAPL`), indices (`^GSPC`), crypto pairs (`BTC-USD`), and ETFs. You can also paste a full Yahoo quote URL and the actor extracts the symbol.

**Why does `fundamentals` return 34 fields but not a full income statement?**
Yahoo deprecated its legacy detailed statement API in 2024. This actor uses Yahoo's current fundamentals-timeseries endpoint, which still exposes revenue, margins, cash flow, debt, and equity metrics per annual and quarterly period.

**Can I schedule recurring runs?**
Yes. Use [Apify scheduling](https://docs.apify.com/platform/schedules) to run daily, hourly, or at any interval, then connect the dataset to integrations or webhooks.

**Does this actor require a proxy?**
A residential Apify Proxy is enabled by default because Yahoo Finance rate-limits repeated requests from the same IP. You can override it in the `proxy` input if you have your own proxy group.

**How do I pull multiple years of options data?**
Increase `optionsExpirations` to pull more of a ticker's upcoming expiration dates in a single run.

**How do I report a problem or request a field?**
Open an issue from the Actor page in Apify Console and include the run ID, input, and operation used.

# Actor input Schema

## `operation` (type: `string`):

What to fetch from Yahoo Finance.

## `tickers` (type: `array`):

Stock, ETF, index, or crypto symbols (e.g. AAPL, ^GSPC, BTC-USD) or full Yahoo Finance quote URLs. Required for quotes, historical, fundamentals, analysis, and options. Optional for news (used as the search query per ticker).

## `query` (type: `string`):

Free text used for the search operation, or as a fallback query for news when Tickers is empty.

## `range` (type: `string`):

Historical lookback window. Ignored when Start Date / End Date are set.

## `interval` (type: `string`):

Candle size for the historical operation.

## `startDate` (type: `string`):

Explicit start date (YYYY-MM-DD). Overrides Range when set together with End Date.

## `endDate` (type: `string`):

Explicit end date (YYYY-MM-DD). Overrides Range when set together with Start Date.

## `includeEvents` (type: `boolean`):

Emit extra dividend and split rows alongside historical candles.

## `optionsExpirations` (type: `integer`):

Number of upcoming expiration dates to pull per ticker for the options operation.

## `screenerId` (type: `string`):

Predefined Yahoo Finance screener to pull for the screener operation.

## `maxItems` (type: `integer`):

Hard cap on the number of rows returned for the run. Leave empty for no cap.

## `proxy` (type: `object`):

Yahoo Finance rate-limits datacenter IPs. Residential Apify Proxy is used by default; override only if you have your own proxy group.

## Actor input object example

```json
{
  "operation": "quotes",
  "tickers": [
    "AAPL",
    "MSFT",
    "BTC-USD",
    "^GSPC"
  ],
  "query": "Apple Inc",
  "range": "1mo",
  "interval": "1d",
  "startDate": "",
  "endDate": "",
  "includeEvents": false,
  "optionsExpirations": 1,
  "screenerId": "day_gainers",
  "proxy": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "operation": "quotes",
    "tickers": [
        "AAPL",
        "MSFT",
        "BTC-USD",
        "^GSPC"
    ],
    "query": "Apple Inc",
    "range": "1mo",
    "interval": "1d",
    "screenerId": "day_gainers",
    "proxy": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("parsebird/yahoo-finance-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "operation": "quotes",
    "tickers": [
        "AAPL",
        "MSFT",
        "BTC-USD",
        "^GSPC",
    ],
    "query": "Apple Inc",
    "range": "1mo",
    "interval": "1d",
    "screenerId": "day_gainers",
    "proxy": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("parsebird/yahoo-finance-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "operation": "quotes",
  "tickers": [
    "AAPL",
    "MSFT",
    "BTC-USD",
    "^GSPC"
  ],
  "query": "Apple Inc",
  "range": "1mo",
  "interval": "1d",
  "screenerId": "day_gainers",
  "proxy": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call parsebird/yahoo-finance-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,parsebird/yahoo-finance-scraper"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/0C5PenergoGhu8wnD/builds/Qcc0vrVz6SQWWJhxb/openapi.json
