Run it on Apify: apify.com/clearfetch/flashscore-baseball-scraper
Baseball results from Flashscore as clean JSON: fixtures for the days you choose, live scores, final results, and the complete inning-by-inning line score for every game. MLB, NPB, KBO and the domestic leagues below them. No login, no API key and no proxy. $0.001 per game.
- The full line score. One entry per inning with the runs scored in it, and they reconcile with the final total, which the test suite asserts on every finished game rather than assuming.
- An unbatted final inning is marked, not zeroed. When the home team is ahead and never bats in the ninth,
the feed says
Xand so does this Actor:home: null, notBatted: true. Reporting a 0 there would quietly corrupt any per-inning analysis you build on it. - Status from Flashscore's own stage codes, so a game in the seventh reads as live, plus
stageDetailnaming the exact stage such asSEVENTH_INNINGorEXTRA_INNING. - Teams and competition with IDs, three-letter codes, logos and the Flashscore URL.
raw: all 57 original feed fields, so nothing is lost if you need something not mapped above.
A game where the home team took the lead and never batted in the ninth:
{
"matchId": "SCvI5Ra5",
"url": "https://www.flashscore.com/match/SCvI5Ra5/",
"sport": "baseball",
"status": "finished",
"stage": "finished",
"stageDetail": "FINISHED",
"stageCode": 3,
"stageDetailCode": 3,
"startTime": "2026-09-04T14:00:00.000Z",
"lastUpdate": "2026-09-04T17:06:50.000Z",
"note": null,
"tournament": {
"name": "Extraliga",
"fullName": "CZECH REPUBLIC: Extraliga - Play Offs",
"country": "Czech Republic",
"phase": "Play Offs",
"id": "CGQXGxlC",
"stageId": "IynvQfzT",
"path": "/baseball/czech-republic/extraliga/",
"url": "https://www.flashscore.com/baseball/czech-republic/extraliga/"
},
"home": {
"name": "Kotlarka Prague",
"fullName": "Kotlarka Prague",
"id": "YT9IySyA",
"slug": "kotlarka-prague",
"url": "https://www.flashscore.com/team/kotlarka-prague/YT9IySyA/",
"code": "KPR",
"image": "https://static.flashscore.com/res/image/data/MqhqrJA6-KpjmilWG.png"
},
"away": {
"name": "Hrosi Brno",
"fullName": "Hrosi Brno",
"id": "tfDQZ56M",
"slug": "hrosi-brno",
"url": "https://www.flashscore.com/team/hrosi-brno/tfDQZ56M/",
"code": "HBR",
"image": "https://static.flashscore.com/res/image/data/WdB8doVH-l4zuNCEt.png"
},
"score": {
"home": 8,
"away": 6,
"innings": [
{
"inning": 1,
"home": 0,
"away": 0,
"notBatted": false
},
{
"inning": 2,
"home": 0,
"away": 0,
"notBatted": false
},
{
"inning": 3,
"home": 1,
"away": 0,
"notBatted": false
},
{
"inning": 4,
"home": 2,
"away": 1,
"notBatted": false
},
{
"inning": 5,
"home": 0,
"away": 1,
"notBatted": false
},
{
"inning": 6,
"home": 3,
"away": 0,
"notBatted": false
},
{
"inning": 7,
"home": 0,
"away": 4,
"notBatted": false
},
{
"inning": 8,
"home": 2,
"away": 0,
"notBatted": false
},
{
"inning": 9,
"home": null,
"away": 0,
"notBatted": true
}
]
},
"winner": "home",
"inPlay": false,
"ok": true,
"dayOffset": -1,
"scrapedAt": "2026-09-05T19:21:46.730Z"
}| Field | Type | Default | Description |
|---|---|---|---|
mode |
string | matches |
matches for fixtures, live scores and results; matchDetails for inning scores, statistics and head to head. |
days |
array | ["0"] |
Day offsets from today, from -7 to 7. Note that a night game in the Americas lands on the following UTC day. |
status |
array | all | scheduled, live, finished, postponed, cancelled or interrupted. |
countries |
array | all | For example USA, Japan, South Korea. |
tournamentFilter |
string | — | Case-insensitive regular expression on the competition name, e.g. mlb. |
matchIds |
array | — | Details mode: match IDs or full flashscore.com/match/... URLs. |
details |
array | all three | Details mode: summary, statistics, h2h. |
maxItems |
integer | 0 |
Stop after this many rows; 0 means no limit. |
maxConcurrency |
integer | 5 |
Parallel requests in details mode. |
timeoutSecs |
integer | 30 |
Per-request timeout. |
proxyConfiguration |
object | off | Optional. Not needed in normal use. |
$0.001 per game, and $0.01 per game in details mode however many sections you request. A full day across every league is a few hundred games, so under a dollar. Games that fail or have no data are free.
- Modelling and sabermetrics: per-inning run distributions across leagues and seasons, including the games most feeds flatten by reporting an unbatted ninth as a zero.
- Live scoreboards and bots: poll for in-progress scores and push updates.
- Fantasy and prediction games: populate fixtures and settle results.
- Media: daily results digests with the line score.
- AI agents: a tool that answers "how did last night's games finish, inning by inning".
curl -X POST "https://api.apify.com/v2/acts/clearfetch~flashscore-baseball-scraper/run-sync-get-dataset-items?token=YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{"days": ["-1"], "countries": ["USA"]}'from apify_client import ApifyClient
client = ApifyClient("YOUR_TOKEN")
run = client.actor("clearfetch/flashscore-baseball-scraper").call(run_input={"days": ["-1"]})
for game in client.dataset(run["defaultDatasetId"]).iterate_items():
line = " ".join("X" if i["notBatted"] else str(i["home"]) for i in game["score"]["innings"] or [])
print(game["home"]["name"], game["score"]["home"], "-", game["score"]["away"], game["away"]["name"], line)Works with the Apify integrations for n8n, Make, Zapier, Google Sheets, Slack and webhooks, with scheduled runs, and with AI agents through the Apify MCP server.
Do the innings always add up? Yes, and it is asserted on every finished game in the test set rather than assumed. If a game ever fails that check, it means the feed changed and I want to know.
Why is an inning null instead of 0? Because the home team did not bat in it. A zero would say they batted and failed to score, which is a different fact and would skew any per-inning statistic.
Do I need a proxy? No. A proxy input exists for completeness.
Is this legal? It reads the same public endpoints a browser reads, with no login and no personal data. Scores are facts. What you do with the data, including redistribution, is your responsibility.
- 1.0.0 (2026-09) — first release: games mode with day ranges and filters, full line scores with unbatted innings preserved, details mode with statistics and head to head, status from Flashscore's own stage codes.