StatMuse Sports Stats Scraper (NBA, NFL, MLB, NHL & More)
Pricing
from $0.40 / 1,000 results
StatMuse Sports Stats Scraper (NBA, NFL, MLB, NHL & More)
Scrapes StatMuse (statmuse.com) answers to natural-language sports questions plus player game logs and team pages for NBA, NFL, MLB, NHL, WNBA, college football, soccer and golf. Returns the answer sentence and stat tables as flat rows. Optional cache skips past-season queries.
Pricing
from $0.40 / 1,000 results
Rating
0.0
(0)
Developer
ActorFlow
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
a day ago
Last modified
Categories
Share
StatMuse Sports Stats Scraper (statmuse.com) - NBA, NFL, MLB, NHL & More
Scrape sports stats from StatMuse (statmuse.com) by asking plain-English questions or pasting a StatMuse page URL. Get the one-sentence answer and the full stat table as flat rows: player game logs, leaderboards, team records, head-to-heads and betting stats such as against-the-spread records for the NBA, NFL, MLB, NHL, WNBA, college football, soccer and PGA golf. Export the sports data as JSON, CSV or Excel, or call the scraper as a StatMuse API.

Target website: statmuse.com
Terms of service caution: StatMuse's Terms of Service prohibit automated data mining and scraping and license the site for non-commercial use only. This actor reads only public pages that need no login, but you are responsible for checking the StatMuse terms and getting any permission you need before you scrape, store or reuse its data, especially commercially. StatMuse also sells official data access.
β¨ Features of this StatMuse sports stats scraper
- Natural-language query scraping β ask "Celtics against the spread record" or "most points in a game 2024-25" and get the answer sentence plus the result table
- Player game logs and team pages β paste a player game log (any season) or a team season page URL
- Eight sports β NBA, NFL, MLB, NHL, WNBA, college football, soccer (FC) and PGA golf
- Flat rows or whole tables β one record per table row with every stat as its own column, or one record per table with nested columns and rows
- Entity ids β player, game and team-season ids from StatMuse on every row, to join with other data
- Only new history (cache) β a cache project name skips queries and pages about finished past seasons you already have
- Proxy support β optional Apify Proxy configuration
- No browser required β plain HTTP requests make runs fast and cheap
π How to scrape StatMuse stats in 5 steps
- Sign up for a free Apify account β includes $5 monthly credit.
- Open the actor page and click Try for free.
- Keep the prefilled StatMuse URL, or type your questions in the search section and pick the sport.
- Click Start and wait for the run to complete.
- Download results from the Output tab in JSON, CSV, or Excel format.
You can also run this actor via the Apify API or integrate it directly into your workflows using Zapier, Make, or n8n.
π° StatMuse scraper pricing
This actor uses pay-per-result billing: you pay for each record saved to the dataset.
- New Apify accounts include $5 of free monthly credit.
- It works with plain HTTP requests instead of a headless browser, so it costs significantly less to run than browser-based scrapers.
- Proxies are off by default, which keeps runs as cheap as possible.
- Max items is counted per question or URL and defaults to 5. A result table holds up to 50 rows, so set it to what you need.
- Set a Cache project name on scheduled runs: past-season history you already scraped is skipped and not charged.
π§ StatMuse scraper input configuration

The numbers in the screenshot mark the fields of the input form:
- StatMuse page URLs (
startUrls): question, player game log or team page URLs. - Cache project name (
cacheProjectName): reuse the same name on scheduled runs to skip past-season queries already scraped. - Max items (
maxItems): maximum records per question or start URL. - Questions (
queries): plain-English sports questions, one per line. - Sport for questions (
sport): the StatMuse section the questions are asked in, such as NBA, NFL or soccer. - One record per table row (
flattenTable): on gives flat rows, off gives one record per table. - Include answer sentence (
includeAnswerText): adds StatMuse's one-sentence answer to each record.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
startUrls | array | β | [] (prefilled with LeBron James last 10 games) | StatMuse question, player game log or team pages. |
cacheProjectName | string | β | β | Same name on each run = skip past-season queries and pages already scraped. Never applies to "this season", last N games or leaderboards. Records get changeType: new. |
maxItems | integer | β | 5 | Maximum records per question or start URL (a table row, or a whole table in whole table mode). |
queries | array | β | [] | Plain-English questions, for example Celtics against the spread record. |
sport | string | β | nba | Sport section the questions are asked in: nba, nfl, mlb, nhl, wnba, cfb, fc (soccer), pga. |
flattenTable | boolean | β | true | One record per table row. Off = one record per table with nested columns and rows. |
includeAnswerText | boolean | β | true | Add StatMuse's answer sentence to each record. |
proxyConfiguration | object | β | {"useApifyProxy": false} | Optional Apify Proxy settings. |
Supported URL types:
- Questions:
https://www.statmuse.com/nba/ask/lebron-james-last-10-games,https://www.statmuse.com/nba/ask?q=celtics+against+the+spread+record,https://www.statmuse.com/fc/ask/messi-goals-2022 - Player game logs:
https://www.statmuse.com/nba/player/lebron-james-1780/game-log?seasonYear=2024(a plain player page is read as its current game log) - Team pages:
https://www.statmuse.com/nba/team/los-angeles-lakers-15/2025
The questions, sport, table mode and answer text fields sit in the collapsible Search by questions and filters section and are never applied to start URLs. The proxy setting is in its own Proxy section.
π¦ StatMuse scraper output data
Each record is a flat JSON object with id, query, sport, answer, sourceUrl, tableName, tableIndex, rowIndex, the stat columns of that table as camelCase fields (for example name, date, tm, opp, pts, reb, ast, fgPct, threePm), entities (type, id, display name and StatMuse path for players, games and teams) and scrapedAt, plus changeType when caching. In whole table mode records have id, query, sport, answer, sourceUrl, tableName, tableIndex, rowCount, columns, rows and scrapedAt. The column set follows how StatMuse interprets each question, so it differs between queries. Missing values are null. The dataset has 1 view, Overview, a table of the answer and the first columns of each row.
Output at a glance:
| Date | Team | Opp. | Min | Pts | Reb | Ast |
|---|---|---|---|---|---|---|
| 2026-04-18 | LAL | HOU | 38 | 19 | 8 | 13 |
| 2026-04-21 | LAL | HOU | 39 | 28 | 8 | 7 |
| 2026-04-24 | LAL | HOU | 45 | 29 | 13 | 6 |
| 2026-04-26 | LAL | HOU | 33 | 10 | 4 | 9 |
| 2026-04-29 | LAL | HOU | 39 | 25 | 3 | 7 |
Sample output (raw JSON):
{"id": "nba-6fcb2cf200b2","query": "lebron james last 10 games","sport": "nba","answer": "LeBron James has averaged 23.2 points, 7.3 assists and 6.7 rebounds in 10 games in his last 10 games.","sourceUrl": "https://www.statmuse.com/nba/ask/lebron-james-last-10-games","tableName": null,"tableIndex": 0,"rowIndex": 0,"name": "LeBron James","date": "2026-04-18T00:00:00","tm": "LAL","alignment": "vs","opp": "HOU","min": 38.4333,"pts": 19,"reb": 8,"ast": 13,"stl": 2,"blk": 1,"fgm": 9,"fga": 15,"fgPct": 0.6,"threePm": 1,"threePa": 2,"threePPct": 0.5,"ftm": 0,"fta": 2,"ftPct": 0,"tsPct": 0.5982,"oreb": 0,"dreb": 8,"tov": 2,"pf": 3,"plusMinus": 11,"entities": {"name": {"type": "player","id": "1780","display": "LeBron James","path": "nba/players/1780"},"date": {"type": "game","id": "78454","display": "4/18/2026 HOU @ LAL","path": "nba/games/78454"},"tm": {"type": "teamSeason","id": "15/2026","display": "2025-26 Los Angeles Lakers","path": "nba/teams/15/2026"},"opp": {"type": "teamSeason","id": "37/2026","display": "2025-26 Houston Rockets","path": "nba/teams/37/2026"}},"scrapedAt": "2026-10-18T05:20:59.354Z"}
π How to scrape StatMuse with Python, JavaScript or the API
Run the actor programmatically with the official Apify clients. Replace <YOUR_API_TOKEN> with the token from your Apify Console.
Python (pip install apify-client):
from apify_client import ApifyClientclient = ApifyClient("<YOUR_API_TOKEN>")run = client.actor("confidential_gnat/statmuse-sports-scraper").call(run_input={"queries": ["celtics against the spread record"],"sport": "nba","maxItems": 20,})for item in client.dataset(run["defaultDatasetId"]).iterate_items():print(item)
JavaScript (npm install apify-client):
import { ApifyClient } from 'apify-client';const client = new ApifyClient({ token: '<YOUR_API_TOKEN>' });const run = await client.actor('confidential_gnat/statmuse-sports-scraper').call({queries: ['celtics against the spread record'],sport: 'nba',maxItems: 20,});const { items } = await client.dataset(run.defaultDatasetId).listItems();console.log(items);
cURL β start a run and wait for the dataset:
curl -X POST "https://api.apify.com/v2/acts/confidential_gnat~statmuse-sports-scraper/run-sync-get-dataset-items?token=<YOUR_API_TOKEN>" \-H "Content-Type: application/json" \-d '{"queries": ["celtics against the spread record"], "sport": "nba", "maxItems": 20}'
π‘ What you can use StatMuse sports stats data for
- Player and team research datasets: game logs, last-N splits, season totals and head-to-heads in one table
- Betting research on against-the-spread and over/under records per team and game
- Fantasy sports and DFS models that need historical stat lines by player and season
- Sports newsletters, bots and dashboards that answer questions with a sentence and a table
- Analytics notebooks that join StatMuse player, game and team ids with other sports data
Analysts, bettors, fantasy players, journalists and sports-data teams typically use this data, subject to the StatMuse terms noted above.
β οΈ StatMuse scraper limitations
- Terms of service β StatMuse prohibits scraping and limits use to non-commercial purposes. Read its terms before using this actor or the data; the responsibility is yours.
- 50 rows per query β a result table holds at most 50 rows and the site has no pagination. Split a question by season or by last N games to get more.
- Columns vary β StatMuse picks its own interpretation of each question, so tables and columns differ between questions. A question it cannot understand returns no records and a warning in the log.
- Offseason "this season" β StatMuse answers "this season" with last season when the new one has not started.
- No live odds β only betting statistics such as against-the-spread and over/under results, not current sportsbook lines.
- Unsupported pages β single game pages, scores and standings are not read; use questions or game logs instead.
- Fresh data β answers are cached by the site for about a minute; past-season history never changes, so use the cache project name for it.
β StatMuse scraper FAQ
Can I scrape StatMuse legally?
The actor only collects data that StatMuse shows to logged-out visitors, with no login or paywalled content. Scraping publicly available data is generally considered lawful (see hiQ Labs v. LinkedIn), but the StatMuse Terms of Service explicitly prohibit automated scraping and commercial use, so review them and your local laws before using the data.
What data does the StatMuse scraper return?
The answer sentence, the question as StatMuse understood it, and every row of the result tables: for example player, date, team, opponent, points, rebounds, assists and shooting splits for a game log, plus StatMuse ids for players, games and team seasons.
How many rows can I scrape from one StatMuse question?
Max items applies per question or start URL and defaults to 5. A single result table holds up to 50 rows, and game log pages are split into one table per month or phase of the season.
Do I need a proxy to scrape statmuse.com?
No. The proxy setting defaults to off and the site answers normal requests, from datacenter proxies too. Turn on Apify Proxy only if you get blocked.
How do I scrape StatMuse with Python?
Use the Python example above with apify-client, then iterate over the dataset items and read the stat fields of each row.
Can I run this StatMuse scraper on a schedule?
Yes, use Apify Schedules. Set the same Cache project name on every run so questions and pages about finished past seasons are not fetched or charged again. Current-season questions, last-N games and leaderboards are always fetched fresh.
What output formats are supported?
JSON, CSV, Excel, XML and RSS, either from the Output tab or through the Apify API.
Why did my question return no records?
StatMuse answers HTTP 422 "I didn't understand your question" for questions it cannot parse, or for a player asked in the wrong sport. Rephrase the question in StatMuse style, check the Sport for questions field, and look at the run log for the warning.
π Other actors you may find useful for sports and betting data
| Scraper | Description |
|---|---|
| π Action Network Odds & Public Betting Scraper | Sportsbook odds, public betting splits, opening lines and line movement. |
| π Kalshi Markets Scraper | Prediction market prices, implied probability, spread and volume. |
| ποΈ Gametime Events Website Scraper | Event, venue and ticket offer data from Gametime. |
| π Facebook Events Scraper | Public Facebook events by keyword, location and date, without login. |
| π° Google News AI Scraper | Google News search with optional article text and AI summaries. |
π¬ Support & contact
If you encounter any issues or have questions, please open an issue.
You can also find more of our actors on the Actor Flow page.