The basketball data API.
23 NBA seasons, every shot located.
Play-by-play with the location of every NBA and WNBA shot, box scores, win probability, standings and our own team ratings, for the NBA, WNBA and college basketball. Sportsbook lines from 4 to 12 books per regular-season game, 2013-14 to 2023-24. Call it over REST or point Claude at it over MCP. The first 500 credits are free and we do not ask for a card.
500 free credits, no card. Works in Claude, ChatGPT and Cursor: connect over MCP
- plays
- 14.5M+
- games
- 31,000+
- players
- 3,800+
- seasons
- 23
Also in DunkAPI
The WNBA API
Women's National Basketball Association, every season since 2006: play-by-play, shot locations, standings, sportsbook lines and season lines. Same key and credits as the NBA.
See the WNBA data- games
- 4,990
- plays
- 1,934,310
- seasons
- 21
Also in DunkAPI
The college basketball API
NCAA Division I men's basketball, every season since 2013-14: play-by-play, standings, sportsbook lines and season lines. Same key and credits as the NBA.
See the NCAAM data- games
- 76,938
- plays
- 24,730,105
- seasons
- 13
Also in DunkAPI
The women's college basketball API
NCAA Division I women's basketball, every season since 2014-15: play-by-play, standings and season lines. Same key and credits as the NBA.
See the NCAAW data- games
- 66,657
- plays
- 16,121,966
- seasons
- 12
This week
What get_schedule returns right now.
Sample rows; the live page renders from the database. Lines are the median closing number across sportsbooks.
| Tip-off | Away | Home | Line | Total | Game id |
|---|---|---|---|---|---|
| Tue 7:30 PM ET | NY | BOS | BOS -4.5 | 221.5 | 401809001 |
| Tue 10:00 PM ET | DEN | LAL | DEN -2 | 229.5 | 401809002 |
get_schedule · 2 credits · then get_game for the box scores and every book's line
Coverage
Coverage you can inspect before you build.
Play-by-play for NBA games since 2003-04, with the location of every shot in it.
Each sportsbook's moneyline, spread and total: 4 to 12 books per regular-season NBA game from 2013-14 to 2023-24 (10 to 12 from 2020-21), and 4 to 10 for most men's college seasons.
The WNBA since 2006 and Division I men's (from 2013-14) and women's (from 2014-15) college basketball, on the same tools.
| Dataset | Seasons | Volume | Status | Tools |
|---|---|---|---|---|
Games and box scores Scores, both teams' box scores and every player's line: minutes, points, shooting, rebounds, assists, steals, blocks, turnovers, fouls, plus-minus. | 2003-04 to current | Every game, every player | Partial About one game in eight from 2012-13 to 2017-18 has no box score in the source; those lines are counted from the play-by-play (97-100% exact where checked), without minutes or plus-minus. 26 games have a box score but no play-by-play. | |
Play-by-play Every play with clock, score, players involved, shot type and points. | 2003-04 to current | About 450 plays per NBA game | Full | |
Shot locations Each shot's x/y in feet, distance, zone and our expected points. | 2003-04 to current | Every field goal attempt | Full | |
Win probability The home team's win probability after each play, as ESPN computes it. | 2018 to current | After every play | Partial From 2017-18 only. | |
Odds Moneyline, spread and total by sportsbook; opening and closing from 2023-24, the final pregame line before that. | 2013-14 to current | 4 to 12 books per regular-season game to 2023-24, usually one since | Partial No lines before 2012-13; mostly one book per game since 2024-25; no player props. | |
Ratings Our Elo, before and after every game. | 2003-04 to current | Every team, every game | Full | |
Injury report Each listed player's status, injury and expected return, captured daily (NBA and WNBA). | From launch | Daily | Partial Daily captures from launch; no history before that. |
Full detail in the data atlas. Sportsbooks: the books ESPN reports: 4 to 12 per regular-season NBA game from 2013-14 to 2023-24, 10 to 12 from 2020-21 (DraftKings, Caesars, BetMGM, Unibet and Betfair among them in 2023-24), then usually ESPN BET or DraftKings alone. No lines before 2012-13, and most games since 2024-25 have one book.
Last written 2026-10-08 02:09 UTC. Every dataset's own refresh time is in the changelog.
Why trust it
The parts of basketball data that take real work.
Box scores are everywhere. Shot locations joined to a value model, a decade of lines by book, and four leagues on one schema are where shortcuts show.
Located, zoned and valued
Every NBA field goal attempt since 2003-04 carries its spot on the floor in feet, its zone and our expected points for that type of shot from that distance, fitted on the league's own history. A shot chart is one call, not a scraping project.
A decade of lines, by sportsbook
Moneylines, spreads and totals from 4 to 12 sportsbooks per NBA game from 2013-14 to 2023-24 (10 to 12 from 2020-21), and most college seasons, each stored separately, with results against the median close. Enough history to backtest a model across eras, not just last season.
The same tools, one argument apart
The NBA, the WNBA and men's and women's Division I college basketball share one set of endpoints. Pass league and the same box scores, play-by-play, standings and ratings come back for that league, each kept in its own tables.
Tools
Every tool, and what a call costs.
Every tool is one REST endpoint and one MCP tool with the same name, the same parameters, and a fixed credit cost. Empty results are not charged.
- list_gamesGames with scores by season, date, range or team
- get_scheduleUpcoming games with the median line across sportsbooks
- get_standingsStandings from every final game: overall, conference, home, away, last 10
- get_injuriesThe latest injury report: status, injury and expected return (NBA, WNBA)
- get_ratingsOur team Elo ratings, ranked
- get_gameOne game: both box scores, every player's line, each book's line, win probability
- get_playerProfile, per-season averages and shooting splits, last 10 games
- get_player_gamesA player's full game log
- get_leadersSeason leaders per game, by percentage or in total
- get_team_statsPace, offensive, defensive and net rating, and the four factors
- get_oddsEvery sportsbook's moneyline, spread and total for a game (5) or a day (10), with results against the line
Built for
Four jobs, and the endpoints that do them.
23 NBA seasons of shots, with where each was taken
Play-by-play with x/y for every field goal attempt, expected points per shot and shot zones, joined to box scores.
Read more →A decade of sportsbook lines next to the games
Moneyline, spread and total from 4 to 12 books per regular-season game for 2013-14 to 2023-24, joined to the result and our ratings.
Read more →Basketball data your app or agent can query
REST and MCP over the NBA, WNBA and college basketball: games, players, plays, odds and ratings, with stable ids.
Read more →Access
REST or MCP. Same data either way.
Call it from any language over REST. Let Claude or Cursor query it in plain English over MCP.
- GET https://mcp.dunkapi.com/v1/tools public catalogue with JSON Schema
- POST https://mcp.dunkapi.com/v1/{tool}
- MCP https://mcp.dunkapi.com/mcp
curl -X POST https://mcp.dunkapi.com/v1/list_teams \
-H "x-api-key: YOUR_API_KEY"
# every tool: POST /v1/{tool} with a JSON body
# responses carry X-Credits-Used and X-Credits-RemainingPricing
Free to start, then you pay per call.
500 credits on signup, no card. Subscriptions add a monthly allowance; wallet top-ups never expire.
- +All 16 endpoints
- +REST API + MCP access
- +No credit card required
- +10,000 credits/month
- +All 16 endpoints
- +Email support
- +Overage at wallet rates
- +30,000 credits/month
- +All 16 endpoints
- +Priority support
- +Overage at wallet rates
- +125,000 credits/month
- +All 16 endpoints
- +Dedicated support
- +Volume rates available
Full breakdown, credit costs per tool, and FAQ on the pricing page.
Questions
The things people ask before signing up.
Is DunkAPI free?
Every account starts with 500 credits and no card. Calls cost 1 to 10 credits depending on the endpoint, so 500 is a few hundred real requests. Paid plans start at $19/mo for 10,000 credits a month, and wallet top-ups never expire.
How far back does the data go?
NBA play-by-play, with the location of every shot, runs from the 2003-04 season to today; win probability starts in 2017-18. Sportsbook lines start in 2012-13 and carry 4 to 12 books per regular-season game from 2013-14 to 2023-24 (10 to 12 from 2020-21), then usually one. The WNBA runs from 2006, men's college from 2013-14 and women's college from 2014-15, with about ten books per men's college game to 2023-24.
What is MCP, and do I need it?
MCP is the protocol Claude, Cursor and similar assistants use to call tools. Point one at https://mcp.dunkapi.com/mcp with your key and it picks the endpoint and reads the response itself — no client code. If you are writing an application instead, ignore MCP and use the REST endpoints; they are the same 16 tools.
Can I use this commercially?
Yes, inside your own product or model, within the terms. Reselling the data itself as a feed is not permitted. DunkAPI is independent and not affiliated with the NBA, the WNBA or the NCAA.
How current is it?
One update a day, early morning US Eastern (10:00 UTC): scores, box scores and the previous night's play-by-play, the next week's schedule, every book's line for the next two days, the injury report and the ratings. There is no live in-game feed.
Where do the stats come from?
Games, box scores, play-by-play, shot locations, win probability, injuries and sportsbook lines from public ESPN data. Shot zones, expected points per shot, pace, offensive and defensive ratings, standings and team Elo are computed here from those rows. Nothing is licensed from another analytics provider.
What are the rate limits?
60 requests a minute, dropping to 10 if your credit balance falls below 100. The limit is the same on every plan — credits, not requests, are the spend boundary.
Before you write another scraper
Start with 500 credits and no card.
DunkAPI · The basketball data API.