Google Light Search API
Our Google Light Search API allows you to scrape results from the Google Search page with lightning-fast speeds. The Google Light Search engine contains all the most critical data, but without the extra-rich results you usually find on a regular Google Search page. This allows for faster response times compared to our regular Google Search API.
The API is accessed through the following endpoint: /search?engine=google_light
.
You can query: https://serpapi.com/search?engine=google_light&q=coffee
utilizing a GET
request. Head to the playground for a live and interactive demo.
API Parameters
Search Query
q
Required
Parameter defines the query you want to search. You can use anything that you would use in a regular Google search. e.g. inurl:
, site:
, intitle:
. We also support advanced search query parameters such as as_dt and as_eq. See the full list of supported advanced search query parameters.
Geographic Location
location
Optional
Parameter defines from where you want the search to originate. If several locations match the location requested, we'll pick the most popular one. Head to the /locations.json API if you need more precise control. The location and uule parameters can't be used together. It is recommended to specify location at the city level in order to simulate a real user’s search. If location is omitted, the search may take on the location of the proxy.
Localization
google_domain
Optional
Parameter defines the Google domain to use. It defaults to google.com
. Head to the Google domains page for a full list of supported Google domains.
gl
Optional
Parameter defines the country to use for the Google search. It's a two-letter country code. (e.g., us
for the United States, uk
for United Kingdom, or fr
for France). Head to the Google countries page for a full list of supported Google countries.
hl
Optional
Parameter defines the language to use for the Google search. It's a two-letter language code. (e.g., en
for English, es
for Spanish, or fr
for French). Head to the Google languages page for a full list of supported Google languages.
lr
Optional
Parameter defines one or multiple languages to limit the search to. It uses lang_{two-letter language code}
to specify languages and |
as a delimiter. (e.g., lang_fr|lang_de
will only search French and German pages). Head to the Google lr languages page for a full list of supported languages.
Advanced Filters
safe
Optional
Parameter defines the level of filtering for adult content. It can be set to active
or off
, by default Google will blur explicit content.
nfpr
Optional
Parameter defines the exclusion of results from an auto-corrected query when the original query is spelled wrong. It can be set to 1
to exclude these results, or 0
to include them (default). Note that this parameter may not prevent Google from returning results for an auto-corrected query if no other results are available.
Pagination
Serpapi Parameters
device
Optional
Parameter defines the device to use to get the results. It can be set to desktop
(default) to use a regular browser, tablet
to use a tablet browser (currently using iPads), or mobile
to use a mobile browser (currently using iPhones).
no_cache
Optional
Parameter will force SerpApi to fetch the Google Light results even if a cached version is already present. A cache is served only if the query and all parameters are exactly the same. Cache expires after 1h. Cached searches are free, and are not counted towards your searches per month. It can be set to false
(default) to allow results from the cache, or true
to disallow results from the cache. no_cache and async parameters should not be used together.
async
Optional
Parameter defines the way you want to submit your search to SerpApi. It can be set to false
(default) to open an HTTP connection and keep it open until you got your search results, or true
to just submit your search to SerpApi and retrieve them later. In this case, you'll need to use our Searches Archive API to retrieve your results. async and no_cache parameters should not be used together. async should not be used on accounts with Ludicrous Speed enabled.
zero_trace
Optional
Enterprise only. Parameter enables ZeroTrace mode. It can be set to false
(default) or true
. Enable this mode to skip storing search parameters, search files, and search metadata on our servers. This may make debugging more difficult.
API Results
JSON Results
JSON output includes structured data for Organic Results, Knowledge Graph, Related Questions, Related Searches, Top Stories.
A search status is accessible through search_metadata.status
. It flows this way: Processing
-> Success
|| Error
. If a search has failed, error
will contain an error message. search_metadata.id
is the search ID inside SerpApi.
HTML Results
HTML output is useful to debug JSON results or support features not supported yet by SerpApi.
HTML output gives you the raw HTML results from Google.
API Examples
Example with q: Coffee
{
"search_metadata": {
"id": "66697abfde983452041209f4",
"status": "Success",
"json_endpoint": "https://serpapi.com/searches/3a1e74c36ecb63f0/66697abfde983452041209f4.json",
"created_at": "2024-06-12 10:38:55 UTC",
"processed_at": "2024-06-12 10:38:55 UTC",
"google_light_url": "https://www.google.com/search?q=Coffee&oq=Coffee&hl=en&gl=us&sourceid=chrome&ie=UTF-8&gbv=1",
"raw_html_file": "https://serpapi.com/searches/3a1e74c36ecb63f0/66697abfde983452041209f4.html",
"total_time_taken": 0.8
},
"search_parameters": {
"engine": "google_light",
"q": "Coffee",
"google_domain": "google.com",
"hl": "en",
"gl": "us",
"device": "desktop"
},
"search_information": {
"query_displayed": "Coffee",
"organic_results_state": "Results for exact spelling"
},
"organic_results": [
{
"position": 1,
"title": "Coffee - Wikipedia",
"link": "https://en.wikipedia.org/wiki/Coffee",
"displayed_link": "en.wikipedia.org › wiki › Coffee",
"snippet": "Coffee is a beverage brewed from roasted coffee beans. Darkly colored, bitter, and slightly acidic, coffee has a stimulating effect on humans, primarily due ...",
"sitelinks": {
"inline": [
{
"title": "Coffee bean",
"link": "https://en.wikipedia.org/wiki/Coffee_bean"
},
{
"title": "History",
"link": "https://en.wikipedia.org/wiki/History_of_coffee"
},
{
"title": "Coffee production",
"link": "https://en.wikipedia.org/wiki/Coffee_production"
},
{
"title": "Coffee preparation",
"link": "https://en.wikipedia.org/wiki/Coffee_preparation"
}
]
}
},
{
"position": 2,
"title": "Starbucks Coffee Company",
"link": "https://www.starbucks.com/",
"displayed_link": "www.starbucks.com",
"snippet": "Download the app for half off a handcrafted drink during your first week.* Plus, tap into mobile ordering, exclusive offers and so much more."
},
{
"position": 3,
"title": "What is Coffee? - National Coffee Association",
"link": "https://www.ncausa.org/About-Coffee/What-is-Coffee",
"displayed_link": "www.ncausa.org › About Coffee",
"snippet": "Coffee traces its origin to a genus of plants known as Coffea. Within the genus there are over 500 genera and 6,000 species of tropical trees and shrubs.",
"sitelinks": {
"inline": [
{
"title": "History",
"link": "https://www.ncausa.org/About-Coffee/History-of-Coffee"
},
{
"title": "National Coffee Association USA",
"link": "https://www.ncausa.org/about-coffee/coffee-around-the-world"
},
{
"title": "10 Steps from Seed to Cup",
"link": "https://www.ncausa.org/About-Coffee/10-Steps-from-Seed-to-Cup"
}
]
}
},
...
],
"related_questions": [
{
"question": "Is coffee actually healthy for you?",
"snippet": "Hu said that moderate coffee intake—about 2–5 cups a day—is linked to a lower likelihood of type 2 diabetes, heart disease, liver and endometrial cancers, Parkinson's disease, and depression. It's even possible that people who drink coffee can reduce their risk of early death.",
"snippet_highlighted_words": [
"moderate coffee intake—about 2–5 cups a day—is linked to a lower likelihood of type 2 diabetes, heart disease, liver and endometrial cancers, Parkinson's disease, and depression"
],
"title": "Is coffee good or bad for your health? | News - HSPH.Harvard.edu",
"link": "https://www.hsph.harvard.edu/news/hsph-in-the-news/is-coffee-good-or-bad-for-your-health/",
"displayed_link": "www.hsph.harvard.edu › news › hsph-in-the-news › is-coffee-good-or-bad...",
"more_results_link": "https://www.google.com/search?sca_esv=cc5c935eaa1cb0b8&gl=us&hl=en&gbv=1&ei=wXppZsjCFtSPwbkP7ZGUwAc&q=Is+coffee+actually+healthy+for+you?&sa=X&ved=2ahUKEwiIp-Tq79WGAxXURzABHe0IBXgQzmd6BAgBEAc"
},
{
"question": "What is the history of coffee in the world?",
"snippet": "Wild coffee plants, probably from Kefa (Kaffa), Ethiopia, were taken to southern Arabia and placed under cultivation in the 15th century. The popularity of coffee in the Arab world led to the creation of the coffeehouse, first in Mecca and then in Constantinople in the 15th and 16th centuries, respectively.",
"snippet_highlighted_words": [
"Wild coffee plants, probably from Kefa (Kaffa), Ethiopia, were taken to southern Arabia and placed under cultivation in the 15th century"
],
"title": "Coffee | Origin, Types, Uses, History, & Facts | Britannica",
"link": "https://www.britannica.com/topic/coffee",
"displayed_link": "www.britannica.com › topic › coffee",
"more_results_link": "https://www.google.com/search?sca_esv=cc5c935eaa1cb0b8&gl=us&hl=en&gbv=1&ei=wXppZsjCFtSPwbkP7ZGUwAc&q=What+is+the+history+of+coffee+in+the+world?&sa=X&ved=2ahUKEwiIp-Tq79WGAxXURzABHe0IBXgQzmd6BAgBEA4"
},
{
"question": "What do you mean by coffee?",
"snippet": "The seeds of the Coffea plant's fruits are separated to produce unroasted green coffee beans. The beans are roasted and then ground into fine particles typically steeped in hot water before being filtered out, producing a cup of coffee. It is usually served hot, although chilled or iced coffee is common.",
"title": "Coffee - Wikipedia",
"link": "https://en.wikipedia.org/wiki/Coffee",
"displayed_link": "en.wikipedia.org › wiki › Coffee",
"more_results_link": "https://www.google.com/search?sca_esv=cc5c935eaa1cb0b8&gl=us&hl=en&gbv=1&ei=wXppZsjCFtSPwbkP7ZGUwAc&q=What+do+you+mean+by+coffee?&sa=X&ved=2ahUKEwiIp-Tq79WGAxXURzABHe0IBXgQzmd6BAgBEBU"
},
...
],
"related_searches": [
{
"query": "Coffee near me",
"link": "https://www.google.com/search?sca_esv=cc5c935eaa1cb0b8&gl=us&hl=en&gbv=1&q=Coffee+near+me&sa=X&ved=2ahUKEwiIp-Tq79WGAxXURzABHe0IBXgQ1QJ6BAgCEAI",
"serpapi_link": "https://serpapi.com/search.json?device=desktop&engine=google_light&gl=us&google_domain=google.com&hl=en&q=Coffee+near+me"
},
{
"query": "Coffee brands",
"link": "https://www.google.com/search?sca_esv=cc5c935eaa1cb0b8&gl=us&hl=en&gbv=1&q=Coffee+brands&sa=X&ved=2ahUKEwiIp-Tq79WGAxXURzABHe0IBXgQ1QJ6BAgCEAQ",
"serpapi_link": "https://serpapi.com/search.json?device=desktop&engine=google_light&gl=us&google_domain=google.com&hl=en&q=Coffee+brands"
},
{
"query": "Coffee beans",
"link": "https://www.google.com/search?sca_esv=cc5c935eaa1cb0b8&gl=us&hl=en&gbv=1&q=Coffee+beans&sa=X&ved=2ahUKEwiIp-Tq79WGAxXURzABHe0IBXgQ1QJ6BAgCEAY",
"serpapi_link": "https://serpapi.com/search.json?device=desktop&engine=google_light&gl=us&google_domain=google.com&hl=en&q=Coffee+beans"
},
...
],
"serpapi_pagination": {
"current": 1,
"next": "https://serpapi.com/search.json?device=desktop&engine=google_light&gl=us&google_domain=google.com&hl=en&q=Coffee&start=10"
}
}