Scrape Google Search
scrape_googleRun a Google search from a chosen country and return organic results, with optional AI Overview extraction (include.aioverview) and People-Also-Ask AI answers (include.paaAioverview). Two modes: structured (query + country, with optional location/uule/pages) or url (a complete google.com/search URL that owns query, location, and pagination). Supports desktop, mobile, iOS, and Android emulation and multi-page results.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| gl | No | ISO 3166-1 alpha-2 code for the result geography, sent to Google as gl (e.g. "us"). Use list_countries to see supported codes per model. Required in query mode; in url mode it is read from the URL's gl parameter unless supplied here, and an explicit value wins. | |
| hl | No | Optional Google interface-language code, sent as hl (e.g. "de", "pt-br"). Defaults to the language derived from gl — set it when the geography's dominant language is not the one you want. In url mode it is read from the URL's hl parameter unless supplied here, and an explicit value wins. | |
| url | No | A complete google.com/search URL to fetch instead of building one from structured fields. When set, query/location/uule/pages must be omitted (the URL owns them); gl and hl are read from the URL's gl/hl parameters unless supplied explicitly. | |
| uule | No | Optional Google UULE location parameter. Mutually exclusive with location. | |
| pages | No | Number of result pages to fetch (1-10). Defaults to 1. | |
| query | No | The search query. Required unless url is provided. | |
| device | No | Device to emulate: desktop, mobile, ios (Safari on iPhone), or android (Chrome on Android). mobile is an alias for android. Defaults to desktop. | desktop |
| country | No | ISO 3166-1 alpha-2 country code to geo-target the request from (e.g. "US"). Use list_countries to see supported codes per model. Deprecated — use gl instead; country is kept for compatibility and must not disagree with gl. | |
| include | No | Optional flags. Set aioverview: true to extract Google's AI Overview (or { markdown: true } for markdown), paaAioverview: true to hydrate AI answers in People Also Ask. Leave unset for organic results only. | |
| location | No | Optional location name to target search results (e.g. "Austin, Texas, United States"). Mutually exclusive with uule. |