Skip to content

Livematches in play

Demo: Matchboard, opens in a new tab

Ice hockey · North America · 32 teams

NHL API with shot maps, three stars and playoff series

An NHL API for live scores by period, conference and division tables, line-ups, events and shot maps on league id 201302, with seasons back to 2005/06. Goals arrive typed as power-play, short-handed or empty-net, each penalty comes with its length, and every playoff game links to the rest of its series.

  • Seasons since 2005/06
  • 32 teams
  • League id 201302
  • Shot maps by strength from Pro

NHL

GET /v2/leagues/201302

League id
201302
Category
North America
Tier
1
Archive
Seasons since 2005/06
Teams
32 teams
Live channel
league:201302

In the data

The NHL in the API

What league id 201302 holds, and how its seasons are laid out.

Seasons, conferences and divisions

GET /v2/leagues/201302 names the Carolina Hurricanes as title holder and the Montréal Canadiens as the club with the most titles, 25, and dates the 2026/27 season from 29 September 2026 to 20 June 2027. /seasons reaches back to 2005/06, with 2006/07 and 2007/08 missing. /standings serves the league table by default, and group=all adds both conferences and all four divisions, each row with overtimeLosses: defeats in overtime or a shoot-out, worth a point apiece. The NHL publishes no home or away tables, so type=home and type=away are built from finished regular-season games, and meta.source says so.

Periods, penalties and team numbers

A game runs over three periods, period1 to period3; overtime goals go into overtime, and the clock stops and starts with play, so it advances only while running is true. /v2/fixtures/{id}/events sets each goal's detail to regular, powerPlay, shortHanded or emptyNet and lists its assists, two at most; a penalty is a row of type suspension carrying the reason, the length in durationSeconds and the player who drew it. /statistics adds the team side: shots on goal, hits, takeaways, powerPlayConversion, faceoffsWon and the advanced corsiPercentage and fenwickPercentage.

Shots, stars and the playoffs

From Pro, /v2/fixtures/{id}/shotmap puts every shot on the rink with its outcome, its technique, from wrist and snap to slap and backhand, and the strength it came at: even, power play or short-handed. After the game, /lineups flags the first, second and third stars in star, with plusMinus on the skaters' lines and savePercentage on the goalies'. In the playoffs, each side's series score counts the games it has won in the matchup, and /v2/fixtures/{id}/series lists all of that matchup's games by id.

First request

The NHL in three calls

Every call starts from the league id, 201302. The seasons list gives the season ids, newest first, and the season id is what the tables, rounds, leaderboards and statistics ask for.

The answers use the usual { data, meta } envelope and the same field names as every other ice hockey competition, so the code works unchanged for the next league you add.

# Every season, newest first, with its season id
curl "https://api.datasportsapi.com/v2/leagues/201302/seasons" \
  -H "Authorization: Bearer $DATASPORTSAPI_API_KEY"

# Both conferences, the four divisions and the league table
curl "https://api.datasportsapi.com/v2/leagues/201302/standings?season={seasonId}&group=all" \
  -H "Authorization: Bearer $DATASPORTSAPI_API_KEY"

# The season's best single-game figures (Pro and up)
curl "https://api.datasportsapi.com/v2/leagues/201302/top-performances?season={seasonId}" \
  -H "Authorization: Bearer $DATASPORTSAPI_API_KEY"
GET /v2/leagues/201302 · trimmed
{ "data": {
    "id": 201302, "name": "NHL", "sport": "ice-hockey",
    "category": "North America", "tier": 1,
    …
} }

History

How much of the NHL each plan reads

The archive goes back to 2005/06. Each plan reads back a set time from today; nothing live or upcoming is ever held back.

TopicHistoryWhat it covers of the NHL
FreeLast 7 daysLive and upcoming games, the table and statistics of a season still being played, and finished games from the last 7 days.
StarterLast 30 daysLive and upcoming games, the table and statistics of a season still being played, and finished games from the last 30 days.
ProLast 6 monthsLive and upcoming games, the table and statistics of a season still being played, and finished games from the last 6 months.
BusinessLast 12 monthsLive and upcoming games, the table and statistics of a season still being played, and finished games from the last 12 months.
EnterpriseFull historyThe whole archive: seasons since 2005/06.

Questions

NHL API, answered

Anything else? The full FAQ covers quota, plans and the data in general.

How does a shoot-out show in the NHL score?

The hockey way: the side that wins the shoot-out gets one goal added to current, and penalties reads 1 for the winner and 0 for the loser. A game level at 3-3 after overtime therefore ends 4-3 or 3-4, and the winner's periods add up to one goal less than its current, which is expected rather than an error.

Can I plot NHL shots on a rink?

Yes. From Pro, /v2/fixtures/{id}/shotmap gives each shot a position in rink units, x running from about 0 to 240, with its outcome, technique and strength. On Enterprise, /v2/fixtures/{id}/tracking/timeline adds shots, goals with their assists, penalties, faceoffs and hits, filled live about 5 seconds behind play on a 0 to 100 grid where the home side always attacks towards x = 100.

How do I follow the NHL playoffs?

Each playoff game leads to its whole series: /v2/fixtures/{id}/series returns the ids of all the games in the matchup, in the source's order, and each side's series field holds its wins so far. For the postseason leaders, /v2/leagues/201302/top-players and /top-performances take type=playoffs. The NHL Preseason, held from 2018, is a competition of its own, so its games stay out of these tables.

How far back does NHL data go?

To the 2005/06 season. How far back a key can read is set by its plan, counted back from today: Free 7 days, Starter 30 days, Pro 6 months, Business 12 months, and Enterprise the whole archive. Live and upcoming games, and the table and statistics of a season still being played, are open on every plan.

Can I follow NHL games live on the free plan?

Yes. Live and upcoming games are never held back by a plan, so a Free key follows every NHL game in play through /v2/livescores or /v2/fixtures/{id}, with score, status and clock current to the second, within the plan's request quota. On Business and Enterprise, the WebSocket channel league:201302 pushes every change instead.

Keep reading

Other competitions

Everything in the ice hockey data Sports statistics API Live scores API

Build on the NHL today.

1,000 free requests a day during the beta. No card, no sales call.