Skip to content

Livematches in play

Demo: Matchboard, opens in a new tab
Docs v2

Race sports

Race laps

GET

/v2/races/{id}/laps

Pro and up

View as MarkdownTry in Playground →

Lap-by-lap progress of a race session: every driver’s position at the end of each lap (lap 0 is the starting grid), their tyre compound, their pit stops (recorded on the in-lap) and the lap on which they retired. Available on Pro, Business and Enterprise plans.

Covers Formula 1 race sessions (verified on the 2026 Mexico GP). Sessions and series for which our data source has no lap chart — qualifying, practice, MotoGP — return an empty list. Lap times and gaps are not included; use /results for the timed classification.

Parameters

id

pathrequired

race id issued by DataSportsAPI, a positive integer

session

query

which session to chart, by id from /v2/races/{id}; without it the main race session is used

Response

meta
race, session (the session whose laps are shown), count
errors
403 history_not_in_plan — your plan’s history does not reach back to the race’s start404 not_found — the id is not a race id, or the session belongs to a different race

Any /v2 call can also come back with one of the common errors.

curl -H "Authorization: Bearer sk_live_…" \
    "https://api.datasportsapi.com/v2/races/{id}/laps"
Example
{ "data": [ { "competitor": { "id": 700001, "name": "Max Verstappen", "code": "VER", … }, "team": { "id": 700010, "name": "Red Bull Racing", … }, "number": 3,
      "laps": [ { "lap": 0, "position": 5, "tyre": "medium", "pitStop": false, "retired": false },
                { "lap": 27, "position": 2, "tyre": "medium", "pitStop": true, "retired": false },
                { "lap": 28, "position": 5, "tyre": "soft", "pitStop": false, "retired": false }, …,
                { "lap": 71, "position": 1, "tyre": "soft", "pitStop": false, "retired": false } ] },
    { "competitor": { "name": "Fernando Alonso", … }, …, "laps": [ …, { "lap": 6, "position": null, "tyre": "soft", "pitStop": false, "retired": true } ] }, … ],
  "meta": { "race": 812345, "session": 812350, "count": 22 } }