Google

SERP API Google Query Parameters

Configure Google search queries using Thordata’s SERP API, including localization parameters, geotargeting, pagination, and "advanced parameter" output options.

q ,Search Query(Required)

Defines the search query for scraping (default: q=pizza). Supports any keyword in any language.

Example Request: Example with q:pizza parameter

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1\"}"

Localization

google_domain,Domain(Optional)

Defines the domain used for scraping. Default: google.com.

Modify this or refer to the Google Domains page for a full list of supported domains.

Example Request:

Example results for q : pizza ,google_domain: google.co.ao

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.co.ao/search?q=pizza^&json=1\"}"
gl ,Country(Optional)

Specifies the country/region for localized search results (default: us). Uses a two-letter country code (e.g., us, ru, uk).

For supported codes, see Google’s Country List.

Example Request:

Example results for q : pizza,gl: ru

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&gl=ru^&json=1\"}"
hl ,Language(Optional)

Sets the UI language for search results (default: en). Uses a two-letter language code (e.g., en, es, zh-CN).

Full list: Google Language Codes.

Example Request:

Example results for q : pizza,hl: es

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&hl=es\"}"
cr ,Set Multiple Countries(Optional)

Restricts results to specific countries using | as a separator (e.g., countryFR|countryDE). Combine with gl for consistent UI/content language.

gl and cr can be combined, but the actual effect follows cr as the priority.

Example Request:

Example results for q : pizza,cr: countryFR|countryDE

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&cr=countryFR|countryDE\"}"
lr ,Set Multiple Languages(Optional)

Filters results by language using lang_XX codes (e.g., lang_fr|lang_de). Overrides hl if both are used.

hl andlr can be used together, but the actual effect followslr as the priority.

Example Request:

Example results for q : pizza,lr: lang_en|lang_fr

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{"url": "https://www.google.com/search?q=pizza^&json=1^&lr=lang_en|lang_fr"}"

Geotargeting

location ,Location(Optional)

Simulates searches from a precise location. Must be paired with uule. If omitted, the proxy’s location may be used.

Example Request:

Example results for q : pizza,location:India,uule:w+CAIQICIFSW5kaWE

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&location=India^&uule=w+CAIQICIFSW5kaWE\"}"
uule ,UULE(Optional)

Encodes the target location via Base64. Use with location.

Example Request:

Example results for q : pizza,location:India,uule:w+CAIQICIFSW5kaWE

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&location=India^&uule=w+CAIQICIFSW5kaWE\"}"

Search Types

tbm ,Search type(Optional)

Defines the search result type:

  • tbm=isch – Images

  • tbm=shop – Shopping

  • tbm=nws – News

  • tbm=vid – Videos

Example Request:

Example results for q : pizza,tbm:shop

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&tbm=shop\"}"

Pagination

start ,Result offset(Optional)

Sets the starting result index (default: 0).

Example Request:

Example results for q : pizza,start:30

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&start=30\"}"
num ,Results per page(Optional)

Sets the number of results per page (default: 20).

Example Request:

Example results for q : pizza,num:20

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&num=20\"}"

Advanced Parameters

ludocid ,Google Place ID(Optional)

Triggers Knowledge Graph data for specific entities (e.g., ludocid=14389889685039125943).

Example Request:

Example results for q : pizza,ludocid:14389889685039125943

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=Google^&json=1^&ludocid=14389889685039125943\"}"
kgmid ,Google Knowledge Graph ID(Optional)

Directly calls a Knowledge Graph entry (e.g., /m/0d6lp for San Francisco).

Example Request:

Example results for q : pizza,kgmid:/m/0d6lp

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=Google^&json=1^&kgmid=/m/0d6lp\"}"
ibp ,Google Element Rendering(Optional)

Controls special rendering modes (e.g., ibp=new for enhanced Knowledge Graph).

Code Example:

Example results for q : pizza,ibp:new

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&ibp=new\"}"
lsig ,Google Element Rendering(Optional)

This parameter forces the display of the Knowledge Graph map view. lsigId can also be obtained through the redirect link used by Google in 'Google My Business.'

Code Example:

Example results for q : pizza,lsig:new

curl -X POST https://scraperapi.thordata.com/request \
 -H "Content-Type: application/x-www-form-urlencoded" \
 -H "Authorization: Bearer token" \
 -d "engine=google" \
 -d "q=pizza" \
 -d "json=1" \
 -d "lsig=1"
si,Google Cached Search Parameters ID(Optional)

Using the si parameter allows fetching encrypted cached data from Google Search. This parameter overrides all other parameters except 'start' and 'num' and is suitable for collecting Knowledge Graph tab content.

Code Example:

Example results for q : pizza,si:cat

curl -X POST https://scraperapi.thordata.com/request \
 -H "Content-Type: application/x-www-form-urlencoded" \
 -H "Authorization: Bearer token" \
 -d "engine=google" \
 -d "q=pizza" \
 -d "json=1" \
 -d "si=cat"
uds ,Google Filter Search(Optional)

Using the uds=ADv parameter allows fetching encrypted cached data from Google Search. This parameter overrides all other parameters except 'start' and 'num' and is suitable for collecting Knowledge Graph tab content.

Code Example:

Example results for q : pizza,uds:ADV

curl -X POST https://scraperapi.thordata.com/request \
 -H "Content-Type: application/x-www-form-urlencoded" \
 -H "Authorization: Bearer token" \
 -d "engine=google" \
 -d "q=pizza" \
 -d "json=1" \
 -d "uds=ADV"

Advanced Filters

tbs ,Advanced Search Parameters(Optional)

Advanced filters:

  • Time: qdr:h (1 hour), qdr:y (1 year)

  • Content: sur:f (images), sur:fc (free-to-use images)

Code Example:

Example results for q : pizza,tbs:sur:f

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&tbs=sur:f\"}"
safe ,Safe(Optional)

Filters adult content:

  • safe=active – Strict filtering (default)

  • safe=off – No filtering

Example Request:

Example results for q : pizza,safe:active

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&safe=active\"}"
nfpr ,Exclude Auto-corrected Results(Optional)

Disables autocorrect (e.g., nfpr=1 prevents "googl" → "google").

Code Example:

Example results for q : pizza,nfpr:sur:f

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&nfpr=1\"}"
filter ,Results Filtering(Optional)

Deduplicates results: 1 (enable), 0 (disable).

Code Example:

Example results for q : pizza,filter:1

curl https://scraperapi.thordata.com/request -H "Content-Type: application/json" -H "Authorization: Bearer Token" -d "{\"url\": \"https://www.google.com/search?q=pizza^&json=1^&filter=1\"}"

For further assistance, contact us at [email protected].

Last updated

Was this helpful?