Skip to the page

Custom Search Site Restricted JSON API

It stopped on January 8, 2025. The same call works again.

Google's Custom Search Site Restricted JSON API stopped serving traffic on January 8, 2025, and Google sent its customers to Vertex AI Search. A GitHub code search on November 10, 2026 finds 2,196 public files that still hold its address.

Since November 10, 2026, SpecStream answers that call. Change https://www.googleapis.com to https://api.specstream.ai and put a SpecStream key in key=. GET /customsearch/v1/siterestrict replies in Google's JSON, and siteSearch keeps the search to one site.

It is the most accurate web search API in the world: 97.9 F-score on all 1,000 SimpleQA Verified questions, shown on the benchmarks page. A call of up to 10 results costs $0.005, with no daily limit.

New accounts get $10 of credit, no card. It covers 2,000 searches.

SpecStream, the retired Site Restricted JSON API and Vertex AI Search, from Google's own pages on Nov 10, 2026

SpecStreamSite Restricted JSON API (retired)Vertex AI Search (Agent Search)
StatusAnswers since November 10, 2026 at https://api.specstream.ai/customsearch/v1/siterestrictStopped serving traffic on January 8, 2025Google's named replacement. Its pricing page is titled Agent Search pricing
What you changeThe base address and the key. The path, the parameters and the parser stayGoogle's notice says every customer must move to Google Cloud's Agent SearchThe endpoint and the request, to a POST in a Google Cloud project. Google's migration guide covers Site Restricted JSON API users
The requestGET /customsearch/v1/siterestrict?key=...&q=...&siteSearch=..., as your code sends it. cx is accepted and not usedhttps://www.googleapis.com/customsearch/v1/siterestrict?[parameters], with the same parameters as the Custom Search JSON APIPOST https://discoveryengine.googleapis.com/v1/{servingConfig}:search, with a serving config under a project, location, collection and engine
Which sitesOne site with siteSearch=<site>, or the whole live web without it10 or fewer sites in the engine, with Search the entire web set to offUp to 50 domains
The replyGoogle's JSON: kind customsearch#search, items[] with title, link, snippet and displayLink, searchInformation.totalResults and queries.nextPageThe Custom Search JSON API's reply: items[] with the URL, title and text snippets of each resultThe reply of the servingConfigs.search method
Price per 1,000$5 per 1,000 searches of up to 10 results, $0.005 a call. A busy call gets 429 with Retry-After and is not charged$5 per 1,000 queries$1.50 per 1,000 queries on Standard and $4.00 on Enterprise, plus data storage
Daily limit and free useNo daily limit. A new account gets $10 of credit, no card, which covers 2,000 searchesNo daily query limitA free trial of 10,000 queries per account a month

Why the call works again on SpecStream

Other Site Restricted JSON API replacements

How SpecStream scores

The same numbers as the benchmarks page, from the official tasks and scorers.

How to bring a siterestrict call back

1. Create a key under Agents & API in the workspace. A new account gets $10 of credit, no card, which covers 2,000 searches.

2. Set the base address to https://api.specstream.ai where your code has https://www.googleapis.com, and send the SpecStream key in key=. In Python:

import requests

BASE = "https://api.specstream.ai"  # was https://www.googleapis.com

reply = requests.get(
    f"{BASE}/customsearch/v1/siterestrict",
    params={"key": SPECSTREAM_KEY, "cx": CX, "q": "rate limits", "siteSearch": "docs.github.com", "num": 10},
    timeout=30,
)
reply.raise_for_status()
for item in reply.json().get("items", []):
    print(item["title"], item["link"], item["snippet"])

3. In JavaScript:

const params = new URLSearchParams({ key: process.env.SPECSTREAM_KEY, q: "rate limits", siteSearch: "docs.github.com", num: "10" });
const res = await fetch(`https://api.specstream.ai/customsearch/v1/siterestrict?${params}`);
const data = await res.json();
for (const item of data.items ?? []) console.log(item.title, item.link);

4. Put the site your engine searched in siteSearch. To page, send the startIndex from queries.nextPage[0] as start. On a 429, wait the seconds in Retry-After and send the call again; nothing was charged.

Frequently asked questions

Something we didn't answer? Talk to a human

When did the Custom Search Site Restricted JSON API stop working?
On January 8, 2025. Google's notice says the endpoints ceased to serve traffic that day, and sends its customers to Google Cloud's Vertex AI Search.
Can I still call customsearch/v1/siterestrict?
Yes, at SpecStream since November 10, 2026. Send GET https://api.specstream.ai/customsearch/v1/siterestrict with a SpecStream key in key=, and the reply comes back in Google's JSON.
How do I restrict a search to one site?
Send siteSearch=<site>, for example siteSearch=docs.github.com. cx is accepted and not used, so the engine ID in your code can stay.
Does cse.siterestrict.list still work in Google's client library?
Yes, in google-api-python-client 2.201.0 and googleapis 189.0.0, tested on November 10, 2026. Set the address to https://api.specstream.ai where the client is built and put the SpecStream key where Google's key went.
How much does it cost?
$5 per 1,000 searches, $0.005 a call of up to 10 results, with no daily limit. A busy call gets a 429 with Retry-After and is not charged, and a new account gets $10 of credit, no card.
What did Google replace the Site Restricted JSON API with?
Vertex AI Search, now priced as Agent Search at $1.50 per 1,000 queries on Standard and $4.00 on Enterprise, plus data storage. It takes a POST to a serving config in a Google Cloud project. SpecStream answers the GET your code sends today.

Sources

SpecStream wrote this page. Each Google figure comes from Google's own page. The file count is a GitHub code search for customsearch/v1/siterestrict on Nov 10, 2026: files that hold the address.

  1. Google, Custom Search Site Restricted JSON APIdevelopers.google.com/custom-search/v1/site_restricted_api, read Nov 10, 2026
  2. Google Custom Search JSON API overviewdevelopers.google.com/custom-search/v1/overview, read Nov 10, 2026
  3. Google Custom Search JSON API, using RESTdevelopers.google.com/custom-search/v1/using_rest, read Nov 10, 2026
  4. Google Cloud, Agent Search pricingcloud.google.com/generative-ai-app-builder/pricing, read Nov 10, 2026
  5. Google Cloud, migrate from Custom Searchdocs.cloud.google.com/generative-ai-app-builder/docs/migrate-from-cse?hl=en, read Nov 10, 2026
  6. Google Cloud, servingConfigs.searchcloud.google.com/generative-ai-app-builder/docs/reference/rest/v1/projects.locations.collections.engines.servingConfigs/search, read Nov 10, 2026
  7. Brave Search APIbrave.com/search/api/, read Nov 10, 2026
  8. Brave, alternatives to the Google Search APIbrave.com/learn/google-api-shutdown/, read Nov 10, 2026
  9. GitHub code search, customsearch/v1/siterestrictgithub.com/search?q=%22customsearch%2Fv1%2Fsiterestrict%22&type=code, read Nov 10, 2026
  10. SpecStream benchmarksspecstream.ai/benchmarks, read Nov 10, 2026
  11. SpecStream pricingspecstream.ai/pricing, read Nov 10, 2026
  12. SpecStream for agentsspecstream.ai/agents.md, read Nov 10, 2026