Skip to main content
The H2H endpoint returns every recorded meeting between two competitors, ordered most-recent first.

Endpoint

Sport-scoped variant: GET /api/v1/{sport}/h2h/{id1}/{id2} (recommended — routes through the correct sport host).

Example: Real Madrid vs FC Barcelona

Response (envelope shown, games array trimmed):

Resolving team IDs first

If you don’t already know the IDs, run Search and grab competitors[].id:

Common patterns

  • Pre-match widget — fetch H2H + last 5 results for each side (/competitor/{id}/results).
  • Streak detection — walk games[] and count consecutive isWinner on one side.
  • Cross-competition — H2H spans every competition both teams have ever met in. Group by competitionDisplayName if you only want league meetings.
Last modified on June 29, 2026