Skip to content

MLB Stats API

Teams, schedules, game feeds and player stats of Major League Baseball.
Status
Working
API key
Not needed
Browser calls
Runs in the browser
Latency
834 ms

Build snapshot, not live. One verifier run on , from the machine that built this site. How we check

Example request

GEThttps://statsapi.mlb.com/api/v1/teams/147

Sent from your browser straight to statsapi.mlb.com. No proxy: this site never sees the request or the answer.

Copy the request

Shell
curl -s 'https://statsapi.mlb.com/api/v1/teams/147'

Response stored by the verifier

This is what statsapi.mlb.com answered when the verifier sent the request above on : HTTP 200, application/json. Arrays are cut to two items and long strings are shortened. It comes from the build snapshot.

application/json · stored
{
  "copyright": "Copyright 2026 MLB Advanced Media, L.P.  Use of any content on this page acknowledges agreement to the terms posted h...",
  "teams": [
    {
      "springLeague": {
        "id": 115,
        "name": "Grapefruit League",
        "link": "/api/v1/league/115",
        "abbreviation": "GL"
      },
      "allStarStatus": "N",
      "id": 147,
      "name": "New York Yankees",
      "link": "/api/v1/teams/147",
      "season": 2026,
      "venue": {
        "id": 3313,
        "name": "Yankee Stadium",
        "link": "/api/v1/venues/3313"
      },
      "springVenue": {
        "id": 2523,
        "link": "/api/v1/venues/2523"
      },
      "teamCode": "nya",
      "fileCode": "nyy",
      "abbreviation": "NYY",
      "teamName": "Yankees",
      "locationName": "Bronx",
      "firstYearOfPlay": "1903"
    }
  ]
}

Availability

Up 1 of 1 day checked · 30-day window

What counts as up for this API: an answer within five seconds, a 2xx status, and the JSON body must contain the field "teams".

Last check: — passed, HTTP 200 in 834 ms.

The check runs from our infrastructure, not from where you are. If you need certainty, send the request yourself above. How the verifier works.

Questions

Does the MLB Stats API need an API key?

No. The sample request on this page was answered without a key, token or account. Note: Undocumented by the league; the linked reference is maintained by the community.

Can I call the MLB Stats API from the browser?

Yes. statsapi.mlb.com answered our verifier with an Access-Control-Allow-Origin header on Oct 3, 2026, so a fetch call from a web page can read the response.

Is the MLB Stats API working?

At the check on Oct 3, 2026 it returned HTTP 200 with the expected data in 834 ms. The status at the top of this page shows the most recent result we have.