Skip to content

Data

NBA shot chart data

The x/y location of every NBA field goal attempt in the play-by-play since 2003-04, with distance, zone, result and expected points. REST or MCP.

DunkAPI serves the location of every field goal attempt in the NBA play-by-play since 2003-04: x and y in feet with the basket at (25, 0), the distance, the shot type, whether it went in, its zone (restricted area, paint, midrange, corner three, above-the-break three) and our expected points for a shot of that type from that spot.

get_shot_chart rolls a player's, a team's or a team's opponents' season up by zone, with attempts, percentage, points per shot and expected points per shot, and include_shots adds every shot's x/y for drawing the chart. The table below is read from the database.

Coverage by season

Counted from the database on October 8, 2026: finished regular-season and playoff games.

SeasonGamesCoveredShot attempts
20261,322100%236,045
20251,321100%235,140
20241,319100%233,774
20231,320100%232,858
20221,323100%232,314
20211,171100%206,872
20201,143100%202,418
20191,312100%233,813
20181,312100%282,325
20171,309100%283,898
20161,316100%280,052
20151,311100%279,464
20141,319100%280,665
20131,314100%273,022
20121,074100%222,821
20111,311100%276,265
20101,312100%278,329
20091,315100%277,462
20081,316100%278,208
20071,30999%273,766
20061,319100%277,457
20051,314100%278,462
20041,27199%260,492

How to get it

get_shot_chart, 10 credits a call. A full 2026 season is 1,322 calls and 13,220 credits, which fits in one month of Pro ($49/mo).

curl -X POST https://mcp.dunkapi.com/v1/get_shot_chart \
  -H "Content-Type: application/json" \
  -H "x-api-key: YOUR_API_KEY" \
  -d '{
  "game_id": "401585601",
  "include_shots": true
}'

What comes back

season
zones[]List of objects
zones[].zone
zones[].attempts
zones[].made
zones[].pct
zones[].points_per_shot
zones[].expected_points_per_shot
field_goal_attempts
share
share.restricted_area
share.paint
share.midrange
share.corner_3

Every field and a real response: get_shot_chart docs.

Questions

What coordinate system do the shots use?

Feet on a half court: x runs 0 to 50 across the court and y is the distance from the basket, which sits at (25, 0). Shots from the far half have large y values.

How is expected points calculated?

The league's historical make rate for shots of the same type from the same distance, times the points the shot was worth. Rare combinations lean on the make rate at that distance.

Can I see where a team allows shots?

Yes. get_shot_chart with a team and opponent: true returns the shots its opponents took, by zone.

Is it free?

Every account starts with 500 free credits and no card. A shot chart is 10 credits.

What it will not do

  • Locations are ESPN's charting, rounded to the foot.
  • Free throws have no location.
  • include_shots returns up to 3,000 shots per call.

Works with

Start with 500 free credits

No card. REST or MCP.