POST /search
Google Search API
The BestSERP Google Search API returns the organic results of a live Google search as JSON. Send a query with a country and language, and get each result's position, title, final link, snippet, site name and domain, plus the video carousel and Top stories when Google shows them. One page costs one credit.
Last updated:
Key takeaways
- /search returns organic, videos, news with title, link, snippet, displayedLink, source and more.
- Target any country with gl and any language with hl; city-level location is not supported yet.
- 1 credit per page of results ($0.50 per 1,000 after 3,000 free); failed searches are refunded.
- POST a JSON body or GET with the same parameters; the key goes in the X-API-KEY header.
Try the Google Search API
Pick a suggested query to see a saved response, or type your own for a live search (3 free per day).
Loading the live demo
Send a request
POST a JSON body to
https://api.bestserp.com/search with your key in the X-API-KEY header. Replace YOUR_API_KEY and run.curl -X POST 'https://api.bestserp.com/search' \
-H 'X-API-KEY: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{"q":"best running shoes"}'Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
qrequired | string | Search query (1–256 characters). | |
gl | string | us | Country, 2-letter code (us, gb, vn, de…). The search runs from an IP in that country when one is free, else from another one (see ipCountry). |
hl | string | en | Interface language (en, vi, de…). |
num | integer | 10 | Maximum results per page: 10, 20, 30, 40 or 50 (Google may return fewer, e.g. 8 or 9 of 10). Each 10 costs 1 credit. |
page | integer | 1 | Page to return, 1–5 (page × num/10 ≤ 5). Pages 1…page are fetched and charged. |
tbs | string | Recency: qdr:h (hour), qdr:d (day), qdr:w (week), qdr:m (month), qdr:y (year). Also accepted: timeRange = hour|day|week|month|year. | |
resolveLinks | boolean | true | Replace Google redirect links with final URLs. Results come back at once with linksPending: true; poll the request for final links. |
noCache | boolean | false | Skip the 1-hour result cache (5 minutes for news). |
async | boolean | false | Answer 202 immediately with a requestId to poll. |
timeout | number | 60 | Seconds to wait before answering 202 (1–120). |
autocorrect | boolean | Accepted for compatibility; no effect. |
Response fields
Results are in
organic (plus videos and news when Google shows a video carousel or Top stories). Empty fields are left out.organic[]
| Field | Meaning |
|---|---|
position | Rank of the result in Google's order, from 1. |
title | Title of the result as Google shows it. |
link | Destination URL. With resolveLinks (the default) Google redirect links are replaced by the final URL; unresolvedLinks counts any that are left. |
snippet | Text shown under the title. |
displayedLink | The URL line as Google displays it, e.g. https://example.com › guides. |
source | Site name shown next to the result. |
domain | Host name of the result, without www. |
favicon | Site icon: a data: URI taken from the page, or a favicon service URL for the domain. |
videos[]
| Field | Meaning |
|---|---|
position | Rank of the video, from 1. |
title | Video title. |
link | Video page URL. |
snippet | Description shown under the title, when there is one. |
duration | Length as displayed, e.g. 12:41. |
channel | Channel or uploader. |
platform | Site hosting the video, e.g. YouTube. |
date | Upload date as displayed. |
imageUrl | Thumbnail as an inline data: URI, only with includeThumbnails: true (about 20 KB each). |
news[]
| Field | Meaning |
|---|---|
position | Rank of the article, from 1. |
title | Headline. |
link | Article URL (Google redirect links are resolved as for web results). |
snippet | Summary shown under the headline, when there is one. |
date | Publish time as displayed, e.g. "2 hours ago" (ISO 8601 when the RSS fallback was used). |
publishedAt | Publish time in ISO 8601 UTC, when it can be determined. |
source | Publisher name. |
imageUrl | Thumbnail as an inline data: URI, only with includeThumbnails: true (about 20 KB each). |
domain | Host name of the article, without www. |
favicon | Publisher icon. |
origin | google_search for the News tab; google_news_rss when the News tab was blocked and the Google News RSS feed was used instead (its ranking differs). |
Every response
| Field | Meaning |
|---|---|
searchParameters | Your request after validation, with defaults filled in (q, gl, hl, type, page or pages...). |
requestId | ID of this request. Poll GET /requests/{requestId} for async requests and for final links. |
credits | Credits charged for this request (refunded automatically if it fails). |
cached | true when the answer came from the recent-result cache (1 hour, 5 minutes for news). |
linksPending | true while Google redirect links are being replaced by final URLs; poll the request to get them. |
unresolvedLinks | Links that are still Google redirects: they work, but are not the final URL. |
durationMs | Time the search took, in milliseconds. |
ipCountry | Country of the IP the search ran from (same code as gl). Another country than gl when no IP there was free: the search runs anyway instead of waiting. Missing when unknown. |
Sample response
A trimmed response for "best running shoes". Your results reflect Google at the time of the request.
{
"searchParameters": {
"q": "best running shoes",
"gl": "us",
"hl": "en",
"type": "search",
"num": 10,
"page": 1,
"engine": "google"
},
"organic": [
{
"position": 1,
"title": "The 12 Best Running Shoes of 2026, Tested by Runners",
"link": "https://www.runnersgearlab.com/best-running-shoes",
"snippet": "We ran 1,200 miles in 60 pairs to find the best daily trainers, race shoes and trail runners for every budget.",
"displayedLink": "https://www.runnersgearlab.com › best-running-shoes",
"source": "Runners Gear Lab",
"domain": "runnersgearlab.com",
"favicon": "https://www.google.com/s2/favicons?domain=runnersgearlab.com&sz=64"
},
{
"position": 2,
"title": "Best Running Shoes for Beginners: A Buying Guide",
"link": "https://www.stridemag.com/guides/running-shoes-beginners",
"snippet": "Cushioning, drop, fit and price explained. Our picks for new runners, from $80 trainers to carbon racers.",
"displayedLink": "https://www.stridemag.com › guides",
"source": "Stride Magazine",
"domain": "stridemag.com",
"favicon": "https://www.google.com/s2/favicons?domain=stridemag.com&sz=64"
},
{
"position": 3,
"title": "Running shoe - Wikipedia",
"link": "https://en.wikipedia.org/wiki/Running_shoe",
"snippet": "Running shoes are designed for running. Modern running shoes have a cushioned midsole, a durable outsole and a breathable upper.",
"displayedLink": "https://en.wikipedia.org › wiki › Running_shoe",
"source": "Wikipedia",
"domain": "en.wikipedia.org",
"favicon": "https://www.google.com/s2/favicons?domain=en.wikipedia.org&sz=64"
},
{
"position": 4,
"title": "Men's Running Shoes | Free Shipping on Orders Over $50",
"link": "https://www.trailandroad.com/mens/running-shoes",
"snippet": "Shop road and trail running shoes from top brands. Free returns within 60 days.",
"displayedLink": "https://www.trailandroad.com › mens › running-shoes",
"source": "Trail & Road",
"domain": "trailandroad.com",
"favicon": "https://www.google.com/s2/favicons?domain=trailandroad.com&sz=64"
}
],
"videos": [
{
"position": 1,
"title": "I Tested 10 Running Shoes for 500 Miles",
"link": "https://www.youtube.com/watch?v=runshoe500",
"duration": "18:42",
"channel": "The Run Lab",
"platform": "YouTube",
"date": "2 weeks ago"
}
],
"requestId": "5b0c8a52-3f0e-4d55-9a2a-0f3a8e2d1c11",
"credits": 1,
"cached": false,
"linksPending": false,
"unresolvedLinks": 0,
"durationMs": 1840
}What you can build
Rank tracking
Record where your pages appear for each keyword and country, every day.
Rank tracking guideAI agents and RAG
Give a model fresh results with links and snippets it can cite.
AI agents and RAG guideSEO tools
Power SERP analysis, content gap and competitor research features.
SEO tools guide
Current limits
What this API does not do yet, so you can decide before you build on it.
- Organic results, the video carousel (videos) and Top stories (news) are returned. Ads, featured snippets, People Also Ask, the knowledge panel and related searches are not returned yet.
- num is a maximum: a page holds up to 10 organic results and Google sometimes shows 8 or 9.
- Up to 5 pages per request (page x num/10 <= 5); each page costs 1 credit.
- Targeting is by country (gl) and interface language (hl). City-level location is not supported yet: a request with location is refused with an explicit error.
- Results are what a desktop browser sees. There is no mobile SERP option yet.
- 60 searches per minute per account by default; ask on Telegram for more.
Pricing: 1 credit per page of results, 3,000 free credits, then $0.50 per 1,000. See pricing
Frequently asked questions
How many results does one request return?
Up to 10 organic results per page. Ask for num 20, 30, 40 or 50 to fetch more pages in one request; each page of 10 costs 1 credit. Google sometimes shows 8 or 9 results on a page, so num is a maximum.
Are the links the final URLs?
Yes by default. Google now serves some result links as redirects; with resolveLinks (on by default) they are replaced by the destination URL. The response comes back at once with linksPending: true if some are still being resolved, and unresolvedLinks tells you how many redirects remain.
Can I search a specific country and language?
Yes. Set gl to a two-letter country code (us, gb, de, vn...) and hl to a language code (en, de, vi...). City-level location is not supported yet.
Can I filter by date?
Yes. Send tbs: qdr:h, qdr:d, qdr:w, qdr:m or qdr:y (or timeRange: hour, day, week, month, year) to limit results to the last hour, day, week, month or year.
Does it return featured snippets or People Also Ask?
Not yet. The web search returns organic results, plus videos and Top stories when the page has them.
Other Google APIs
- Google Images APIImage results with full-size image URLs, dimensions and the page that hosts each image.
- Google News APINews articles with source, publish time and site icon, from the Google News tab.
- Google Videos APIVideo results with duration, channel and platform.
- Google Shopping APIProducts with price, numeric price, discount, delivery and rating.
- Google Places APILocal businesses with rating, category, address and opening hours.
- Google Maps APIGoogle Maps places with coordinates, place id and CID.
Start with 3,000 free searches
No credit card. Sign in with Google, create a key, send your first request.