# Google search API: what to use after Custom Search ends

> Every Google product people call a search API, which still return public results, what the January 1, 2027 cutoff means, and how to get Google results by API instead, with migration code and prices at your volume.

Canonical: https://keirolabs.cloud/google-search-api · Updated: 2026-11-20

> **Quick answer.** Google has **no official API for public Google search results** for new projects. The **Custom Search JSON API** is closed to new customers and **stops working on January 1, 2027**, and its suggested successor, Vertex AI Search, only searches **your own** content. To get Google results by API you now use a **SERP API**.
>
> **Keirolabs `/search/google` is the near drop-in replacement for Custom Search**: the same title, URL and snippet results, by country and language, up to 20 per call instead of 10, with **no daily cap**, at **$1.78 to $5.33 per 1,000**, cheaper than Custom Search's $5 on most plans. Signup gives **500 free searches with no card**, and the migration is a few lines (code below). If you need good web results rather than Google's exact ranking, Keirolabs lite costs **$0.03 to $0.10 per 1,000**. Other options: Serper ($0.30 to $1.00 per 1,000) for bulk raw results and SerpApi ($3.75 to $25) for the full results page.

## Is there an official Google Search API?

Not for new projects. Here is every Google product people mean by "Google search API" and whether it still returns public Google results:

| Google product | Returns public Google results? | Status in November 2026 |
| :--- | :--- | :--- |
| **Custom Search JSON API** (`customsearch/v1`) | Yes, from a Programmable Search Engine set to search the whole web | Closed to new customers; ends **January 1, 2027** |
| **Programmable Search Engine** (the embeddable search box) | Yes, but as a widget on your site, not an API | Still offered as a widget |
| **Vertex AI Search** | No. It searches data you index: your site, documents, databases | Google's suggested replacement for site search |
| **Grounding with Google Search** in Gemini | Indirectly. Gemini searches Google and answers; you get the answer and source links, not a results list | Available on the Gemini API, billed per grounded request |
| **Google Search Console API** | No. It reports how your own site performs in search | Available |

So if you want the list of results Google shows for a query, as data, Google itself no longer sells it to new customers. Third-party SERP APIs fill that gap.

Source: [Google's Custom Search JSON API overview](https://developers.google.com/custom-search/v1/overview).

## What happens on January 1, 2027?

Existing Custom Search JSON API integrations stop returning results. Before then:

- **New projects** cannot enable the API. Tutorials that say "enable Custom Search API in the console" no longer work for new accounts.
- **Existing projects** keep their pricing until the cutoff: 100 queries a day free, then $5 per 1,000, with a hard cap of 10,000 queries a day.

If your product calls `customsearch/v1`, the replacement has to ship before the end of 2026. Our [Custom Search migration guide](https://keirolabs.cloud/blog/google-custom-search-api) maps every request and response field.

## Ways to get Google search results by API

| Option | What you get | Price per 1,000 | Free to start |
| :--- | :--- | :--- | :--- |
| **Keirolabs `/search/google`** | Google organic results: title, URL, snippet, rank; country and language | $5.33 (Essential) to $1.78 (Startup) | 1,000 credits (500 searches), no card |
| **Serper** | Google results as JSON | $1.00, down to $0.30 at 12.5M | 2,500 queries once, no card |
| **SerpApi** | The full Google results page plus Maps, Shopping, Scholar, News and other engines | $25.00 (Starter) to $3.75 (1M a month) | 250 a month |
| Custom Search JSON API | Google results from a Programmable Search Engine | $5.00, max 10,000 a day | 100 a day; ends January 1, 2027 |

Prices from each vendor's pricing page, November 20, 2026. Keirolabs is our product.

### How to choose

- **You are replacing Custom Search in an app:** Keirolabs or Serper. Both return organic results with title, URL and snippet, which is what most Custom Search integrations used. Keirolabs costs less than Custom Search's $5 per 1,000 on every plan and has no daily cap.
- **You need ads, local results, People also ask, Shopping or Scholar:** SerpApi. It parses the whole page and other Google properties.
- **You want the lowest price for bulk Google results:** Serper.
- **You are building an AI agent:** you probably don't need Google's exact ranking. See below.

## Migrating from Custom Search to Keirolabs

Before:

```python
import requests

r = requests.get(
    "https://www.googleapis.com/customsearch/v1",
    params={"key": GOOGLE_KEY, "cx": ENGINE_ID, "q": "best crm for startups", "gl": "us", "num": 10},
)
items = r.json().get("items", [])
results = [{"title": i["title"], "url": i["link"], "snippet": i["snippet"]} for i in items]
```

After:

```python
import os, requests

r = requests.post(
    "https://api.keirolabs.cloud/api/v2/search/google",
    headers={"Authorization": f"Bearer {os.environ['KEIRO_API_KEY']}"},
    json={"query": "best crm for startups", "country": "US", "maxResults": 10},
    timeout=30,
)
results = r.json()["results"]  # already [{title, url, snippet}]
```

| Custom Search | Keirolabs | Notes |
| :--- | :--- | :--- |
| `q` | `query` | |
| `num` (max 10) | `maxResults` (max 20) | One call returns up to 20 |
| `gl` | `country` | Two-letter country code |
| `cr` | `cr` | Restrict to sites from a country |
| `lr` / `hl` | `lang` | Language code, such as `en` or `pt-BR` |
| `cx` | not needed | Searches the whole web |
| `items[].link` | `results[].url` | |
| `items[].title`, `items[].snippet` | `results[].title`, `results[].snippet` | |
| 10,000 a day cap | no daily cap | Plan rate limits apply |

What doesn't carry over: `siteSearch` and engines restricted to your own sites, image search, `dateRestrict`, `start` pagination past the first 20, and `pagemap` structured data.

## What a Google search API costs at your volume

| Searches a month | Custom Search (until Jan 2027) | Keirolabs `/search/google` | Serper | SerpApi |
| :--- | :--- | :--- | :--- | :--- |
| 3,000 (100 a day) | $0 | free credits, then $29.99 | free credits | $75 (Developer, 5,000) |
| 15,000 | $60 | $49.99 (Pro) | $50 (Starter pack, 50,000) | $150 (Production) |
| 50,000 | $235 | $99.99 (Startup) | $50 | $725 (Searcher, 100,000) |
| 300,000 | about $1,485 (the daily cap) | custom volume price | $375 (Standard pack, 500,000) | $2,750 (Infrastructure, 500,000) |

Custom Search costs assume 100 free queries a day and $5 per 1,000 after. Serper packs are one-time credit purchases; SerpApi plans are monthly.

## Do you need Google's results, or good results?

Google's exact ranking matters for **SEO and rank tracking**, where "position 4 on Google" is the measurement. For **AI agents, RAG and research**, what matters is whether the pages are relevant and readable, and a general web search API does that for much less:

| Need | Endpoint | Price per 1,000 on a plan |
| :--- | :--- | :--- |
| Google's exact ranking | `/search/google` | $1.78 to $5.33 |
| Ranked web results (title, URL, snippet) | `/search/lite` | $0.03 to $0.10 |
| Results plus each page as markdown | `/search/content` | $1.33 to $4.00 |
| An answer with citations | `/answer` | $0.89 to $2.67 |

The Bing Search API, the other big-tech option, was retired in August 2025, which is why Custom Search's end leaves so many projects looking at the same short list. Background: [the 2026 search API crackdown](https://keirolabs.cloud/blog/search-api-crackdown-2026-serpapi-lawsuit-bing-shutdown).

## Is it allowed to get Google results through a third party?

SERP APIs collect results from Google's public pages. Google sued SerpApi under the DMCA in December 2025; on July 20, 2026 the court dismissed that claim, holding that ordinary search results are not copyrighted works. Google can still change its pages or block collection, so treat any SERP API as a dependency with some risk and keep a fallback. This is not legal advice.

## Verdict

There is no official Google search API for new projects, and the old one ends on January 1, 2027. For Google's organic results in an app, Keirolabs `/search/google` is a near drop-in for Custom Search at $1.78 to $5.33 per 1,000 with no daily cap. Serper is cheaper for bulk raw results, and SerpApi covers the full page. If your real need is good web results for a model, skip Google's ranking and use a general search API at a fraction of the cost.

## FAQ

### Is there an official Google Search API?

Not for new projects. Google's Custom Search JSON API, the only official API for public Google results, is closed to new customers and stops working on January 1, 2027. Vertex AI Search searches your own content, not the public web.

### When does the Google Custom Search JSON API shut down?

Existing integrations stop on January 1, 2027. New customers already cannot enable it.

### How much does the Google Custom Search API cost?

Until it ends: 100 queries a day free, then $5 per 1,000 queries, with a hard cap of 10,000 queries a day, about 300,000 a month.

### What is the best alternative to the Google Custom Search API?

A SERP API that returns Google organic results. Keirolabs /search/google returns title, URL and snippet by country and language at $1.78 to $5.33 per 1,000 with no daily cap. Serper is cheaper in bulk at $0.30 to $1.00 per 1,000; SerpApi returns the full results page at $3.75 to $25 per 1,000.

### Is Vertex AI Search a replacement for Custom Search?

Only for searching your own site or documents. Vertex AI Search does not return public Google web results, so it is not a drop-in for apps that used Custom Search to search the web.

### How do I get Google search results in Python?

Call a SERP API. With Keirolabs: POST https://api.keirolabs.cloud/api/v2/search/google with an Authorization: Bearer key and a JSON body {"query": "...", "country": "US"}. The response's results list holds title, url and snippet in Google's rank order.

### Is it legal to get Google results through a third-party API?

SERP APIs collect results from Google's public pages. In July 2026 a US court dismissed Google's DMCA claim against SerpApi, holding that ordinary search results are not copyrighted works. Google can still block or change access. This is not legal advice.

### Do AI agents need a Google search API?

Usually not. Agents need relevant, readable pages, not Google's exact ranking. A general search API such as Keirolabs /search/lite costs $0.03 to $0.10 per 1,000, 18 to 50 times less than Google SERP results on the same plan.

## Related

- [Google Custom Search API migration](https://keirolabs.cloud/blog/google-custom-search-api): Field-by-field mapping and code for the January 2027 cutoff.
- [Keirolabs SERP API](https://keirolabs.cloud/serp-api): Google organic results as JSON by country and language.
- [Google search APIs compared](https://keirolabs.cloud/blog/google-search-apis-2026): Every provider of Google results, side by side.
- [The 2026 search API crackdown](https://keirolabs.cloud/blog/search-api-crackdown-2026-serpapi-lawsuit-bing-shutdown): SearchGuard, the Bing shutdown and Google v. SerpApi.
- [Cheapest web search API](https://keirolabs.cloud/cheapest-web-search-api): Ten APIs ranked by price per 1,000.
