Stock Market Scraper avatar

Stock Market Scraper

Pricing

from $10.00 / 1,000 results

Go to Apify Store
Stock Market Scraper

Stock Market Scraper

Scrape stock market data — the world's most popular free financial data source. Extract real-time prices, company profiles, financial statements, dividends, analyst ratings, institutional holders, and options chains for any publicly traded stock, ETF, index, or cryptocurrency

Pricing

from $10.00 / 1,000 results

Rating

0.0

(0)

Developer

Jamshaid Arif

Jamshaid Arif

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

4 days ago

Last modified

Share

📈 Stock Market Scraper

**Scrape stock market data — the world's most popular free financial data source. Extract real-time prices, company profiles, financial statements, dividends, analyst ratings, institutional holders, and options chains for any publicly traded stock, ETF, index, or cryptocurrency.

No API key needed. No login required.


What does this actor do?

This actor fetches comprehensive financial data for any ticker symbol available. It uses the yfinance Python library to access Yahoo's publicly available market data APIs.

Use it to:

  • Track stock prices and build historical price databases
  • Monitor company valuations (P/E, market cap, EV/EBITDA)
  • Download quarterly and annual financial statements
  • Track dividend history for income investing research
  • Aggregate analyst price targets and buy/sell recommendations
  • Identify institutional and insider ownership changes
  • Fetch options chain data for derivatives research
  • Compare multiple stocks side-by-side

Supported ticker types

TypeExample tickers
US StocksAAPL, MSFT, GOOGL, TSLA, AMZN, META, NVDA
International StocksBABA (Alibaba), TM (Toyota), SAP (SAP SE)
ETFsSPY, QQQ, VTI, ARKK, VOO
Indices^GSPC (S&P 500), ^DJI (Dow Jones), ^IXIC (NASDAQ)
CryptoBTC-USD, ETH-USD, SOL-USD, DOGE-USD
ForexEURUSD=X, GBPUSD=X, JPY=X
FuturesGC=F (Gold), CL=F (Crude Oil), SI=F (Silver)

How to use

Step 1: Enter ticker symbols

Type one or more ticker symbols, separated by commas:

AAPL, MSFT, GOOGL, TSLA, AMZN

Step 2: Select data modules

Choose which data you want to scrape. You can select multiple:

ModuleWhat you get
Company InfoName, sector, price, market cap, P/E, margins, beta, 52-week range, and 40+ metrics
Price HistoryOHLCV candles (open, high, low, close, volume) for any period and interval
Financial StatementsIncome statement, balance sheet, and cash flow — annual or quarterly
Dividends & SplitsFull dividend payment history and stock split history
Analyst Price TargetsConsensus low, mean, median, and high price targets
RecommendationsAnalyst buy/hold/sell/strong buy ratings over time
Institutional HoldersTop institutional investors and insider transactions
Options ChainCall and put options with strike, bid, ask, volume, open interest

Step 3: Run and export

Click Start, wait for results, and export as JSON, CSV, or Excel.


Input parameters

Core settings

FieldTypeDefaultDescription
tickersTextAAPL, MSFT, GOOGL, TSLA, AMZNComma-separated ticker symbols
data_modulesMulti-selectcompany_info, price_historyWhich data to scrape (see table above)

Price history settings

FieldTypeDefaultDescription
history_periodSelect1moTime range: 1d, 5d, 1mo, 3mo, 6mo, 1y, 2y, 5y, 10y, ytd, max
history_intervalSelect1dCandle size: 1m, 5m, 15m, 30m, 1h, 1d, 1wk, 1mo

Note: Intraday intervals (1m–90m) only work for the last 60 days. 1-minute data is limited to the last 7 days.

Financials settings

FieldTypeDefaultDescription
financials_typeSelectannualannual or quarterly financial statements

Options settings

FieldTypeDefaultDescription
options_expirySelectnearestnearest = closest expiry only, all = all available dates (up to 5)

Input examples

Example 1: Quick stock comparison — FAANG companies

{
"tickers": "AAPL, AMZN, GOOGL, META, NFLX",
"data_modules": ["company_info"],
}

Example 2: Full analysis of a single stock

{
"tickers": "NVDA",
"data_modules": [
"company_info",
"price_history",
"financials",
"dividends",
"analyst_targets",
"recommendations",
"holders"
],
"history_period": "1y",
"history_interval": "1d",
"financials_type": "quarterly"
}

Example 3: Crypto price history

{
"tickers": "BTC-USD, ETH-USD, SOL-USD",
"data_modules": ["company_info", "price_history"],
"history_period": "3mo",
"history_interval": "1d"
}

Example 4: Dividend research for income stocks

{
"tickers": "JNJ, PG, KO, PEP, MCD, T, VZ",
"data_modules": ["company_info", "dividends"]
}

Example 5: Options data for a volatile stock

{
"tickers": "TSLA",
"data_modules": ["company_info", "options"],
"options_expiry": "all"
}

Example 6: Intraday 5-minute candles (last 5 days)

{
"tickers": "SPY",
"data_modules": ["price_history"],
"history_period": "5d",
"history_interval": "5m"
}

Output format

Each record in the dataset has a type field indicating the data module. One ticker with multiple modules produces multiple records.

Company Info record

{
"type": "company_info",
"ticker": "AAPL",
"name": "Apple Inc.",
"sector": "Technology",
"industry": "Consumer Electronics",
"country": "United States",
"website": "https://www.apple.com",
"employees": 161000,
"description": "Apple Inc. designs, manufactures, and markets smartphones...",
"price": 228.50,
"currency": "USD",
"previous_close": 227.10,
"change": 1.40,
"change_pct": "+0.62%",
"day_high": 230.00,
"day_low": 226.80,
"52w_high": 260.10,
"52w_low": 164.08,
"volume": 54123456,
"market_cap": 3510000000000,
"market_cap_fmt": "$3.51T",
"pe_ratio": 37.2,
"forward_pe": 31.5,
"price_to_book": 62.4,
"dividend_yield": 0.0044,
"beta": 1.24,
"profit_margin": 0.267,
"return_on_equity": 1.572,
"debt_to_equity": 151.86,
"free_cash_flow": 111500000000,
"scraped_at": "2026-04-05T12:00:00+00:00"
}

Price History record

{
"type": "price_history",
"ticker": "AAPL",
"period": "1mo",
"interval": "1d",
"candles": 22,
"stats": {
"period_high": 230.50,
"period_low": 210.30,
"period_open": 215.00,
"period_close": 228.50,
"period_change": 6.28,
"total_volume": 1234567890
},
"data": [
{
"Date": "2026-03-05T00:00:00",
"Open": 215.00,
"High": 217.30,
"Low": 214.50,
"Close": 216.80,
"Volume": 58123456
}
]
}

Financial Statements record

{
"type": "financials",
"ticker": "AAPL",
"frequency": "annual",
"income_statement": [ { "Date": "2025-09-30", "Total Revenue": 400000000000, "...": "..." } ],
"balance_sheet": [ { "Date": "2025-09-30", "Total Assets": 350000000000, "...": "..." } ],
"cash_flow": [ { "Date": "2025-09-30", "Free Cash Flow": 111500000000, "...": "..." } ]
}

Analyst Price Targets record

{
"type": "analyst_targets",
"ticker": "AAPL",
"data": {
"current": 228.50,
"low": 180.00,
"high": 300.00,
"mean": 248.75,
"median": 250.00
}
}

Options Chain record

{
"type": "options",
"ticker": "TSLA",
"available_expiries": ["2026-04-11", "2026-04-18", "2026-04-25"],
"fetched_expiries": 1,
"chains": [
{
"expiry_date": "2026-04-11",
"calls_count": 45,
"puts_count": 45,
"calls": [ { "strike": 250.0, "lastPrice": 12.50, "bid": 12.30, "ask": 12.70, "volume": 5432, "openInterest": 12345 } ],
"puts": [ { "strike": 250.0, "lastPrice": 8.20, "bid": 8.00, "ask": 8.40, "volume": 3210, "openInterest": 9876 } ]
}
]
}

What each metric means

Valuation metrics

MetricWhat it tells you
pe_ratioPrice-to-Earnings — how much investors pay per dollar of earnings
forward_peP/E based on estimated future earnings
peg_ratioP/E adjusted for growth — under 1.0 may suggest undervaluation
price_to_bookPrice vs. book value — common in bank/financial analysis
ev_to_ebitdaEnterprise Value to EBITDA — industry-standard valuation metric
market_capTotal market value of outstanding shares

Profitability metrics

MetricWhat it tells you
profit_marginNet income as a % of revenue
operating_marginOperating income as a % of revenue
return_on_equityHow efficiently the company uses shareholder equity
return_on_assetsHow efficiently the company uses its total assets

Risk metrics

MetricWhat it tells you
betaStock volatility relative to the market (1.0 = same as market)
debt_to_equityTotal debt divided by shareholder equity
current_ratioAbility to pay short-term obligations (above 1.0 is healthy)
short_ratioDays to cover all short positions — high values may signal short squeeze risk

How much does it cost to run?

This actor is lightweight — it fetches data via API calls, no browser rendering needed.

TickersModulesEstimated timeApify credits
5 tickersCompany Info only~15 seconds< $0.01
5 tickersAll 8 modules~2 minutes~$0.01
20 tickersInfo + History~1 minute~$0.01
50 tickersInfo + Financials~5 minutes~$0.02
100 tickersCompany Info only~3 minutes~$0.02

Scheduling and integrations

Daily price tracking

Set up a scheduled run in Apify Console to scrape prices every trading day. Combine with Google Sheets to build an auto-updating stock tracker.

Example schedule: Every weekday at 4:30 PM ET (after market close):

{
"tickers": "AAPL, MSFT, GOOGL, TSLA, AMZN, NVDA, META",
"data_modules": ["company_info"],
}

Weekly portfolio analysis

Schedule a weekend run with full financials:

{
"tickers": "VTI, BND, VXUS, VNQ",
"data_modules": ["company_info", "price_history", "dividends"],
"history_period": "1mo"
}

Connect via API (Python)

from apify_client import ApifyClient
client = ApifyClient("YOUR_API_TOKEN")
run = client.actor("your-username/yahoo-finance-scraper").call(run_input={
"tickers": "AAPL, MSFT, GOOGL",
"data_modules": ["company_info", "price_history"],
"history_period": "3mo",
})
dataset = client.dataset(run["defaultDatasetId"])
items = dataset.list_items().items
# Filter for company info records
companies = [i for i in items if i.get("type") == "company_info"]
for c in companies:
print(f"{c['ticker']}: ${c['price']} | {c['market_cap_fmt']} | P/E: {c['pe_ratio']}")

Available export formats

After each run, download your data from the dataset tab:

  • JSON — Best for programmatic use and integrations
  • CSV — Best for spreadsheets and quick analysis
  • Excel (.xlsx) — Best for sharing with non-technical stakeholders
  • Google Sheets — Auto-sync with the Apify integration

Tips and best practices

  • Start with company_info only to verify your tickers work, then add more modules.
  • Use price_history with 1d interval for most analysis. Intraday data (1m, 5m) is only available for the last 7–60 days.
  • Quarterly financials give more recent data; annual gives a cleaner trend view.
  • Crypto tickers use the format BTC-USD, ETH-USD — you'll get price history but not financials.
  • Index tickers start with ^ (e.g., ^GSPC for S&P 500) — limited to price data only.
  • Options data can be large — use nearest expiry unless you need the full chain.
  • If a module returns an error for a ticker, the actor continues with the next module/ticker. Check the error field in the output.

Disclaimer

This actor is for educational and research purposes only. It is not financial advice. Always do your own research before making investment decisions.


Changelog

v1.0.0 (2026-04-05)

  • Initial release
  • 8 data modules: company info, price history, financials, dividends, analyst targets, recommendations, holders, options
  • Support for stocks, ETFs, indices, crypto, forex, and futures
  • Batch processing for multiple tickers
  • Clean JSON output with formatted market cap, change %, and NaN handling
  • Period stats computed for price history (high, low, change %)