Google Search APIQuickstartAPI Parameters

API Parameters

The Google Search API is driven by the parameters below. They are passed inside the input object of the request (see Getting Started). Only q is required; every other parameter is optional and refines the location, language, pagination, or result type.

ParameterRequiredDescription
urlfalseComplete access link of Google Search. Mutually exclusive with all other parameters. If this parameter is filled in, all other request parameters do not need to be passed and will be automatically ignored if passed.
qtrueDefines the query you want to search. You can use anything that you would use in a regular Google search, e.g. inurl:, site:, intitle:. Advanced search query parameters such as as_dt and as_eq are also supported.
locationfalseDefines from where you want the search to originate. If several locations match, the most popular one is used. location and uule can’t be used together. It is recommended to specify location at the city level to simulate a real user’s search. If omitted, the search may take on the location of the proxy.
uulefalseThe Google-encoded location you want to use for the search. uule and location can’t be used together.
ludocidfalseDefines the id (CID) of the Google My Business listing you want to scrape. Also known as Google Place ID.
lsigfalseAn id you might have to use to force the knowledge graph map view to show up. The lsig ID is available via the Local Pack API or Google Local API, and also via a redirect Google uses within Google My Business.
kgmidfalseDefines the id (KGMID) of the Google Knowledge Graph listing you want to scrape. Searches with kgmid return results for the originally encrypted search parameters. For some searches, kgmid may override all other parameters except start and num.
sifalseDefines the cached search parameters of the Google Search you want to scrape. Searches with si return results for the originally encrypted search parameters. For some searches, si may override all other parameters except start and num. si can be used to scrape Google Knowledge Graph Tabs.
ibpfalseResponsible for rendering layouts and expansions for some elements (e.g., gwp;0,7 to expand searches with ludocid for an expanded knowledge graph).
udsfalseEnables filtering of the search. It’s a string provided by Google as a filter. uds values are provided under the section: filters, with uds, q, and serpapi_link values provided for each filter.
google_domainfalseDefines the Google domain to use. Defaults to google.com. See the Google domains page for a full list of supported domains.
glfalseDefines the country to use for the Google search. It’s a two-letter country code (e.g., us for the United States, uk for United Kingdom, fr for France).
hlfalseDefines the language to use for the Google search. It’s a two-letter language code (e.g., en for English, es for Spanish, fr for French).
crfalseDefines one or multiple countries to limit the search to. Uses country{two-letter upper-case country code} and | as a delimiter (e.g., countryFR|countryDE searches only French and German pages).
lrfalseDefines one or multiple languages to limit the search to. Uses lang_{two-letter language code} and | as a delimiter (e.g., lang_fr|lang_de searches only French and German pages).
tbsfalse(to be searched) Defines advanced search parameters that aren’t possible in the regular query field (e.g., advanced search for patents, dates, news, videos, images, apps, or text contents).
safefalseDefines the level of filtering for adult content. Can be set to active or off. By default Google will blur explicit content.
nfprfalseExcludes results from an auto-corrected query when the original query is spelled wrong. Set to 1 to exclude these results, or 0 to include them (default). May not always prevent auto-corrected results when no others are available.
filterfalseDefines if the filters for ‘Similar Results’ and ‘Omitted Results’ are on or off. Set to 1 (default) to enable, or 0 to disable.
tbmfalse(to be matched) Defines the type of search. Can be set to: (no tbm) regular Google Search, isch: Google Images API, lcl: Google Local API, vid: Google Videos API, nws: Google News API, shop: Google Shopping API, pts: Google Patents API, or any other Google service.
startfalseDefines the result offset for pagination (e.g., 0 (default) is the first page, 10 the 2nd page, 20 the 3rd page). Google Local Results only accepts multiples of 20.
devicefalseDefines the device used to get the results. Currently only supports the desktop version.

Full reference: API Parameters on Scrapeless API docs.