Support
The API and site will always remain free at point of access. If you love our service and find this site useful you can sign up as a Patreon supporter for
$2 or more to get special features such as livescores. You can cancel anytime. This allows us to pay for the servers and bandwidth and develop new features.

API Keys
You can use the test API key "1" during development of your app or for educational use(see test links below)
However you must sign up on Patreon if you wish to have a production API key if releasing publicly on an appstore or web service.
The test key may be revoked at any time if abused.

Upgrade
All Patreon supporters have access to special features on the API and quicker livescore updates.
You also get personal support from us via email.

Contact
Email: zag (at) kodi.tv (please state if you are a Patreon Supporter)

Search

Search for team by name
https://www.thesportsdb.com/api/v1/json/1/searchteams.php?t=Arsenal

Search for team short code
https://www.thesportsdb.com/api/v1/json/{APIKEY}/searchteams.php?sname={TeamShortCode}

Search for all players from team
https://www.thesportsdb.com/api/v1/json/1/searchplayers.php?t=Arsenal

Search for players by name
https://www.thesportsdb.com/api/v1/json/1/searchplayers.php?p=Danny%20Welbeck
https://www.thesportsdb.com/api/v1/json/{APIKEY}/searchplayers.php?t={TeamName}&p={Playername}

Search for event by event name
https://www.thesportsdb.com/api/v1/json/1/searchevents.php?e=Arsenal_vs_Chelsea
https://www.thesportsdb.com/api/v1/json/1/searchevents.php?e=Arsenal_vs_Chelsea&s=1617

Search for event by event file name
https://www.thesportsdb.com/api/v1/json/1/searchfilename.php?e=English_Premier_League_2015-04-26_Arsenal_vs_Chelsea

NOTE: You can replace spaces '%20' with underscores if you want, when requesting multi word strings.

List

List all sports
https://www.thesportsdb.com/api/v1/json/1/all_sports.php

List all leagues
https://www.thesportsdb.com/api/v1/json/1/all_leagues.php

List all Leagues in a country
https://www.thesportsdb.com/api/v1/json/1/search_all_leagues.php?c=England
https://www.thesportsdb.com/api/v1/json/1/search_all_leagues.php?c=England&s=Soccer

List all Seasons in a League
https://www.thesportsdb.com/api/v1/json/1/search_all_seasons.php?id=4328

List all Teams in a League
https://www.thesportsdb.com/api/v1/json/1/search_all_teams.php?l=English%20Premier%20League
https://www.thesportsdb.com/api/v1/json/1/search_all_teams.php?s=Soccer&c=Spain

List All teams details in a league by Id
https://www.thesportsdb.com/api/v1/json/1/lookup_all_teams.php?id=4328

List All players in a team by Team Id
https://www.thesportsdb.com/api/v1/json/1/lookup_all_players.php?id=133604

List all users loved teams and players
https://www.thesportsdb.com/api/v1/json/1/searchloves.php?u=zag

Lookups

League Details by Id
https://www.thesportsdb.com/api/v1/json/1/lookupleague.php?id=4346

Team Details by Id
https://www.thesportsdb.com/api/v1/json/1/lookupteam.php?id=133604

Player Details by Id
https://www.thesportsdb.com/api/v1/json/1/lookupplayer.php?id=34145937

Event Details by Id
https://www.thesportsdb.com/api/v1/json/1/lookupevent.php?id=441613

Player Honours by Player Id
https://www.thesportsdb.com/api/v1/json/1/lookuphonors.php?id=34147178

Player Former Teams by Player Id
https://www.thesportsdb.com/api/v1/json/1/lookupformerteams.php?id=34147178

Player Contracts by Player Id
https://www.thesportsdb.com/api/v1/json/1/lookupcontracts.php?id=34147178

Event TV by Event Id
https://www.thesportsdb.com/api/v1/json/1/lookuptv.php?id=584911

Lookup Table by League ID and Season
https://www.thesportsdb.com/api/v1/json/1/lookuptable.php?l=4328&s=1819
https://www.thesportsdb.com/api/v1/json/1/lookuptable.php?l=4328&s=1213

Schedules

Next 5 Events by Team Id
https://www.thesportsdb.com/api/v1/json/1/eventsnext.php?id=133602

Next 15 Events by League Id
https://www.thesportsdb.com/api/v1/json/1/eventsnextleague.php?id=4328

Last 5 Events by Team Id
https://www.thesportsdb.com/api/v1/json/1/eventslast.php?id=133602

Last 15 Events by League Id
https://www.thesportsdb.com/api/v1/json/1/eventspastleague.php?id=4328

Events in a specific round by league id/round/season
https://www.thesportsdb.com/api/v1/json/1/eventsround.php?id=4328&r=38&s=1415

Events on a specific day
https://www.thesportsdb.com/api/v1/json/1/eventsday.php?d=2014-10-10
https://www.thesportsdb.com/api/v1/json/1/eventsday.php?d=2014-10-10&s=Soccer
https://www.thesportsdb.com/api/v1/json/1/eventsday.php?d=2014-10-10&l=Australian_A-League


TV Events on a day
https://www.thesportsdb.com/api/v1/json/1/eventstv.php?d=2018-07-07
https://www.thesportsdb.com/api/v1/json/1/eventstv.php?d=2018-07-07&s=Fighting

TV Events on a channel (Latest)
https://www.thesportsdb.com/api/v1/json/1/eventstv.php?c=TSN_1

All events in specific league by season
https://www.thesportsdb.com/api/v1/json/1/eventsseason.php?id=4328&s=1415

Images

Preview Images
Most of the time you won't want to download the original large image, just get a small preview. This is possible simple by adding ''/preview'' onto the end URL. This will give you a small 200px version. This will work with JPG images only.
Original Image - https://www.thesportsdb.com/images/media/league/fanart/xpwsrw1421853005.jpg
Small Image - https://www.thesportsdb.com/images/media/league/fanart/xpwsrw1421853005.jpg/preview

Livescores
*For Patreon Supporters ONLY (email us once signed up for a full API key)

Soccer Livescores
https://www.thesportsdb.com/api/v1/json/1/latestsoccer.php (this is just a static example for non-patreon)
NOTE: Updated every 2mins for Patreon

Golf Livescores
https://www.thesportsdb.com/api/v1/json/1/latestgolf.php (this is just a static example for non-patreon)
NOTE: Updated every 2mins for Patreon

Basketball Livescores
https://www.thesportsdb.com/api/v1/json/1/latestbasketball.php (this is just a static example for non-patreon)
NOTE: Updated every 2mins for Patreon

American Football Livescores
https://www.thesportsdb.com/api/v1/json/1/latestamericanfootball.php (this is just a static example for non-patreon)
NOTE: Updated every 2mins for Patreon