{"slug": "how-to-scrape-google-sports-results", "title": "How to scrape Google sports results", "summary": "SerpApi's Google Sports Results API provides structured JSON data from Google Search for sports matches, tournaments, and teams, including scores, rosters, standings, and highlights, handling web scraping and parsing for developers. The API is available through a free SerpApi account, with paid upgrades for higher capacity.", "body_md": "Google Search can provide detailed information about past sports matches, ongoing games, teams, players, scheduled events, leagues, and tournaments. For individual games, that information can include the score, team rosters, statistics like passes and possession, location, and other facts. Google also provides the same data [through its Gemini chatbot and Google Assistant](https://support.google.com/googlehome/answer/7071998?hl=en).\n\nThe [Google Sports Results API](https://serpapi.com/sports-results) from SerpApi provides all that data in simple JSON format, ready for any programming language or automation. SerpApi handles the web scraping, HTML parsing, proxy network, captcha puzzles, and other challenges for you.\n\n## What can you scrape from Google sports results?\n\nHere's some of the data you can extract for individual sports matches on Google, using SerpApi:\n\n**Title:** The game's main title, like \"Super Bowl LX\" or \"Mexico vs England.\"**League:** The league or tournament for the game, such as \"NFL\" or \"FIFA World Cup 2026.\"**Stage:** The stage of the game's tournament, like \"Round of 16\" or \"Super Bowl.\"**Score:** The game's score, if it has started.**Timeline:** A feed of commentary and other events from the game, with timestamps.**Date:** The time and date of the game.**Status:** The current status of the game, like \"Live\" for an ongoing event, or \"Final\" or \"Full-time\" for a completed match.**Teams:** Information about the teams, which can include their team names, goals, penalties, and lists of players.**Location:** The physical location of the game, such as \"Mexico City Stadium.\"**Highlights:** Videos from the game, with each result containing a title, video URL, thumbnail image URL, and time duration.\n\nYou can also pull information for sports tournaments or leagues using SerpApi, which can include this data:\n\n**Title:** The title of the tournament or league, such as \"FIFA World Cup 2026.\"**Games:** A list of games in the tournament or league, with each game containing the teams, score, start and end time, stadium, highlights, and other information.**Highlighted game:** The current recommended game from Google, like an ongoing match or the next game, with information about the teams and location.**Groups:** The groups or rounds of the tournament, like \"Quarter-finals\" or \"Round of 16.\"**Standings:** The team's standings in any available leagues or tournaments.**Players:** A list of players in the team, with full names, positions/roles, a link to their page on Google, and thumbnail images. The`kgmid`\n\nknowledge graph ID is also available for each player, to fetch additional information about them.\n\nGoogle can provide results for a sports team, which SerpApi also extracts:\n\n**Title:** The name of the team, like \"Canada men's national soccer team.\"**Thumbnail:** The thumbnail image for the team, such as the nation's flag.**Games:** A list of the team's recent games, with each one including a score, teams, tournament, and other information.**Standings:** The team's current standings in an ongoing or recent tournament.\n\nThe [documentation for the Google Sports Results API](https://serpapi.com/sports-results) contains more examples of search results with their structured JSON. For more complete use cases, check out our blog post on [monitoring World Cup scores with SerpApi](https://serpapi.com/blog/monitoring-fifa-world-cup-scores-api/).\n\n## Getting started with SerpApi\n\nBefore getting started with the Google Sports Results API, you need a free SerpApi account. That also includes access to other engines, like the [Google Search API](https://serpapi.com/search-api), [DuckDuckGo Search API](https://serpapi.com/duckduckgo-search-api), and [Yahoo Search API](https://serpapi.com/yahoo-search-api). You can [upgrade to a paid account](https://serpapi.com/pricing) later if you need more search capacity, faster speeds, or other features.\n\nFirst, you need to [create an account](https://serpapi.com/users/sign_up) and verify your email and other details. After that, get the API key from [your account dashboard](https://serpapi.com/manage-api-key).\n\nMake sure to [store your API key in a safe location](https://serpapi.com/blog/how-to-securely-store-api-keys/) if you are sharing or publishing your code. If the key is leaked or stolen, you can make a new one from the SerpApi account dashboard.\n\n### Install the SerpApi library (optional)\n\nYou can use [SerpApi's official libraries](https://serpapi.com/integrations) for Python, JavaScript, Ruby, Java, and other languages. They provide a simple wrapper around the API requests.\n\nHowever, the libraries are not required. You can still make API calls with cURL, `fetch()`\n\nin Node.js, or anything else that can send GET requests and process a JSON response.\n\n### Review the Google Sports Results API documentation\n\nAll the APIs at SerpApi have extensive documentation that covers all the supported parameters and filters, code examples for popular languages, and example JSON responses. This post covers some of the basic usage for parsing Google sports results, and you can find everything else at the [documentation page](https://serpapi.com/sports-results).\n\nSome sports data can be accessed through requests to the Google Search API, using the `q`\n\nparameter for your query (like \"super bowl lx\" or \"mexico football team\"). Some details, like the tournament or stadium, will include a Google Knowledge Graph ID (kgmid) that you can search with the Google Sports API for additional information.\n\nYou can also [find the Google Knowledge Graph ID](https://serpapi.com/blog/how-to-find-google-knowledge-graph-id-kgmid/) with a few other methods, like a query to Wikidata or manual extraction from Google search results.\n\n## How to scrape Google sports results\n\nIf you have your API key, you're ready to start pulling data from Google sports results. The results will be identical across all libraries and GET requests, so use whichever method you want.\n\n### GET request\n\nThis performs a Google search for \"Canada men's football team\" from the US with a simple GET request, which includes a `sports_results`\n\nobject in the JSON response:\n\n```\nhttps://serpapi.com/search.json?engine=google&q=canada+men%27s+football+team&gl=us&hl=en&api_key=YOUR_KEY_GOES_HERE\n```\n\nThat `sports_results`\n\nobject contains a `kgmid`\n\nkey for one of the games, with a value of `/g/11yfm8t8yy`\n\n. You can use search that with the Google Sports API to get full details for the game:\n\n```\nhttps://serpapi.com/search.json?engine=google_sports&gl=us&hl=en&kgmid=%2Fg%2F11yfm8t8yy&sp=ft&type=game&api_key=YOUR_KEY_GOES_HERE\n```\n\nThat API request can be created manually, with the `kgmid`\n\nparameter set to the provided value, `type`\n\nset to `game`\n\n, and `sp`\n\nset to `ft`\n\nfor football. You can also use the pre-made request provided in the `google_sports_serpapi_link`\n\nkey.\n\nYou can also use SerpApi's [JSON Restrictor feature](https://serpapi.com/json-restrictor) to trim the API response to specific values. This is the same search, but only returning sports data, excluding the organic search results and other information from Google:\n\n```\nhttps://serpapi.com/search.json?engine=google&q=canada+men%27s+football+team&gl=us&json_restrictor=sports_results&api_key=YOUR_KEY_GOES_HERE\n```\n\nThis can be useful if you need more efficient parsing, like when using an LLM with a limited context window.\n\n### Python\n\nThis uses the [official SerpApi Python library](https://serpapi.com/integrations/python) to search for the Mexican men's football team, and if a recent game is listed, the full lineup is displayed for both teams in the game:\n\n``` python\nimport serpapi\nclient = serpapi.Client(api_key=YOUR_KEY_GOES_HERE)\n\n# Start initial search\n\nfirstResponse = client.search({\n  \"engine\": \"google\",\n  \"q\": \"mexico men's football team\",\n  \"gl\": \"us\",\n  \"hl\": \"en\"\n})\nfirstGame = firstResponse.get(\"sports_results\", {}).get(\"games\", [None])[0]\nif firstGame:\n  print(f\"Found game at {firstGame['venue']} on {firstGame['date']}\")\n\n# Get more details if an ID is present\n\nif \"kgmid\" in firstGame:\n  secondResponse = client.search({\n    \"engine\": \"google_sports\",\n    \"kgmid\": firstGame[\"kgmid\"],\n    \"gl\": \"us\",\n    \"hl\": \"en\",\n    \"type\": \"game\",\n    \"sp\": \"ft\" # ft for Football\n  })\n  if secondResponse.get(\"game_results\", {}).get(\"lineups\", [None]):\n    for team in secondResponse[\"game_results\"][\"lineups\"][\"teams\"]:\n      print(f\"\\nTeam #{team[\"team_index\"] + 1}:\")\n      for player in team[\"starters\"]:\n        print(f\"{player[\"name\"]} ({player[\"jersey_number\"]})\")\n```\n\n### Ruby\n\nThis searches for a baseball game on Google and retrieves the game's ID, then performs another search with that ID, using the [SerpApi Ruby gem](https://serpapi.com/integrations/ruby). Finally, the data for all innings from the second search is displayed:\n\n```\nrequire \"serpapi\"\n\n# Start initial search\nfirst_req = SerpApi::Client.new(\n  engine: \"google\",\n  q: \"blue jays mariners game\",\n  gl: \"us\",\n  hl: \"en\",\n  api_key: YOUR_KEY_GOES_HERE\n)\n\n# Find the game ID and search it for more information\ngame_id = first_req.search.dig(:sports_results, :game_spotlight, :kgmid)\nif game_id\n  second_req = SerpApi::Client.new(\n    engine: \"google_sports\",\n    hl: \"en\",\n    kgmid: game_id,\n    sp: \"bb\",\n    type: \"game\",\n    api_key: YOUR_KEY_GOES_HERE\n  )\n  # Get the list of teams\n  game_teams = second_req.search.dig(:game_results, :info, :teams)\n  # Display the innings for each team\n  for team in game_teams do\n    puts \"\\n#{team[:name]} - Total score: #{team[:score]}\\n=====\"\n    for inning in team.dig(:linescore) do\n      puts \"#{inning[:title]}: #{inning[:score]}\"\n    end\n  end\nend\n```\n\n### JavaScript and Node.js\n\nHere's how you can use the [SerpApi JavaScript library](https://serpapi.com/integrations/javascript) to search for a football team, and if there is a recent (or ongoing) game, use that game's ID to show all statistics:\n\n``` js\nimport { getJson } from 'serpapi';\n\n// Start initial search and get game ID\nconst firstSearch = await getJson({\n  engine: \"google\",\n  q: \"US women's football team\",\n  gl: \"us\",\n  hl: \"en\",\n  api_key: YOUR_KEY_GOES_HERE\n});\nconst gameID = firstSearch?.sports_results?.games?.[0]?.kgmid;\n\n// Start second search to get more details\nif (gameID) {\n  const secondSearch = await getJson({\n    engine: \"google_sports\",\n    kgmid: gameID,\n    gl: \"us\",\n    hl: \"en\",\n    sp: \"ft\", // Football\n    type: \"game\",\n    api_key: YOUR_KEY_GOES_HERE\n  });\n  const teams = secondSearch?.game_results?.info?.teams;\n  for (const i in teams) {\n    console.log(`\\n${teams[i].name} - Score ${teams[i].score}\\n=====`);\n    // Print all available stats for each team\n    const stats = secondSearch?.game_results?.team_stats?.teams?.[i]?.stats;\n    for (const a in stats) {\n      console.log(`${stats[a].title} - ${stats[a].value}`);\n    }\n  }\n}\n```\n\n### cURL\n\nHere's how you can retrieve details about a football game, like per-team statistics and highlights, using a cURL request:\n\n```\ncurl --get https://serpapi.com/search \\\n -d api_key=\"YOUR_KEY_GOES_HERE\" \\\n -d engine=\"google_sports\" \\\n -d hl=\"en\" \\\n -d kgmid=\"/g/11n3xxgprk\" \\\n -d sp=\"ft\" \\\n -d type=\"game\"\n```\n\n### Other languages and no-code solutions\n\nYou can still use the API directly with [GET requests](#get-request), even if there isn't an official SerpApi integration for your preferred environment or language. SerpApi also works with [Make.com](https://serpapi.com/blog/announcing-serpapis-make-app/), [N8N](https://serpapi.com/blog/boost-your-n8n-workflows-with-serpapis-verified-node/), and other tools.\n\n## Conclusion\n\nGoogle Search has access to a wide range of past and live sports data, across football, cricket, ice hockey, American football, and other sports. With the [Google Search API](https://serpapi.com/search-api) and [Google Sports Results API](https://serpapi.com/sports-results) from SerpApi, you can pull all those results into any automation or programming language.\n\nIf you need help using SerpApi, please [contact us](https://serpapi.com/#contact).", "url": "https://wpnews.pro/news/how-to-scrape-google-sports-results", "canonical_source": "https://serpapi.com/blog/how-to-scrape-google-sports-results/", "published_at": "2026-07-08 19:05:01+00:00", "updated_at": "2026-07-21 18:19:54.760485+00:00", "lang": "en", "topics": ["developer-tools"], "entities": ["SerpApi", "Google Sports Results API", "Google Search API", "DuckDuckGo Search API", "Yahoo Search API"], "alternates": {"html": "https://wpnews.pro/news/how-to-scrape-google-sports-results", "markdown": "https://wpnews.pro/news/how-to-scrape-google-sports-results.md", "text": "https://wpnews.pro/news/how-to-scrape-google-sports-results.txt", "jsonld": "https://wpnews.pro/news/how-to-scrape-google-sports-results.jsonld"}}