A Google Custom Search JSON API alternative for live organic results

According to Google's documentation, the Custom Search JSON API is closed to new customers, and existing customers have until January 1, 2027 to transition. Serper.live is not a drop-in replacement: it returns the live organic results of a Google search in a chosen country as JSON.

Published: Updated:
A Google Custom Search JSON API alternative for live organic results
On this page
01

What is changing

According to Google's documentation, the Custom Search JSON API is closed to new customers, and existing customers have until January 1, 2027 to transition to an alternative solution. The same page describes the API as retrieving web and image results from a Programmable Search Engine, the engine you configure and identify with cx.

Dates and terms are Google's and can change; confirm them on Google's page before you set a deadline.

02

What Serper.live returns instead

Serper.live is a live Google SERP API: each request runs a real Google search for the country and device you choose and returns the organic results shown at that moment, up to 100 per request (10 by default), as JSON.

It is not a search engine of its own and not a site search: no engine to configure, no index of your pages. A request usually takes 2–3 seconds because it loads Google live, and it is billed per request from a prepaid balance.

If your Custom Search integration showed you what Google ranks for a query, this is the closer fit. If it powered search inside your own site or across a fixed list of domains, you need a site search product instead: Google's documentation points to Vertex AI Search for that case.

03

Parameter mapping

Custom Search JSON API on the left, Serper.live on the right:

  • q → query: the keyword, 2–120 characters.
  • gl → country: two-letter code of an open market, from GET /v1/countries (currently Germany, France, United Kingdom, Türkiye, Ukraine, and United States).
  • hl → language: Google's interface language; optional, defaults to the language of the country.
  • num → limit: organic results per request, 1–100 (10 by default; each started block of 10 costs one market price).
  • start → no equivalent: instead of paging, raise limit and one call returns up to 100 organic results.
  • cx → not needed: there is no engine to configure, the request searches Google for the market.
  • key → an Authorization: Bearer header with your sl_live_ token.
  • items[] → organic[]: link becomes url, displayLink roughly becomes domain; title and snippet keep their names, and snippet can be null.
04

Migration steps

The request below is the whole integration; the steps around it:

  1. Create an account and a token, add credit from $5 in USDT or USDC.
  2. Replace the GET to the Custom Search endpoint with POST https://api.serper.live/v1/search, a JSON body and the Authorization header.
  3. Map the parameters as above; drop cx and start.
  4. Read organic[] instead of items[], rename link to url, and handle a null snippet.
  5. Raise the HTTP timeout to at least 100 seconds and queue the call instead of running it inside the user's request: a live search usually takes 2–3 seconds, the first one for a market after a pause longer.
  6. Send an Idempotency-Key, so a repeated call is never charged twice.
  7. Run both side by side for a few days, compare, then switch.
curl
curl -X POST https://api.serper.live/v1/search \
  -H "Authorization: Bearer sl_live_YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"query":"best coffee shops","country":"DE"}'
JavaScript
const response = await fetch('https://api.serper.live/v1/search', {
    method: 'POST',
    headers: {
        Authorization: 'Bearer sl_live_YOUR_TOKEN',
        'Content-Type': 'application/json',
    },
    body: JSON.stringify({ query: 'best coffee shops', country: 'DE' }),
    signal: AbortSignal.timeout(100000),
});
const result = await response.json();

console.log(result.organic);
Python
import requests

response = requests.post(
    "https://api.serper.live/v1/search",
    headers={"Authorization": "Bearer sl_live_YOUR_TOKEN"},
    json={"query": "best coffee shops", "country": "DE"},
    timeout=100,
)
print(response.json()["organic"])
FAQ

Migration questions

Is Serper.live a drop-in replacement for the Google Custom Search JSON API?

No. The endpoint, the authentication, the parameters and the response shape are different, and the results come from a live Google search rather than an engine you configure. Plan for a small adapter, not a URL swap.

Does the Custom Search JSON API shutdown affect existing customers?

According to Google's documentation, yes: existing customers have until January 1, 2027 to transition to an alternative solution. Check Google's page for the current wording before you fix a date.

Can I restrict results to my own site like a Programmable Search Engine?

Not by configuration. Serper.live searches Google for the market and returns the organic results up to limit: the top 10 by default, up to 100; filter organic[] by domain on your side. Whether Google honours search operators in the keyword is Google's call, so test it in the playground first.

Start with a few dollars of credit.

No subscription and no minimum contract. Create a Serper.live account, add USDT or USDC and send your first live request in minutes.