> For the complete documentation index, see [llms.txt](https://docs.serphouse.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.serphouse.com/google-apis/google-lite-web-search-api.md).

# Google Lite Web Search API

Retrieve real-time Google Web Search results with a fast, lightweight response, including organic listings, website titles, links, and snippets.

{% hint style="danger" %}
Requires authentication
{% endhint %}

<mark style="color:green;">`POST`</mark> `https://api.serphouse.com/web-search-lite`

#### Headers

| Name                                            | Type   | Description              |
| ----------------------------------------------- | ------ | ------------------------ |
| Authorization<mark style="color:red;">\*</mark> | String | Bearer \<YOUR\_API\_KEY> |
| Content-Type<mark style="color:red;">\*</mark>  | String | application/json         |

#### Request Body

<table><thead><tr><th>Name</th><th>Type</th><th width="222">Description</th></tr></thead><tbody><tr><td>q<mark style="color:red;">*</mark></td><td>string</td><td>Search phrase that you want to search</td></tr><tr><td>domain<mark style="color:red;">*</mark></td><td>string</td><td>Choose google domain.<br><br>You can retrieve the list of supported Google domains by making a separate request to the  <a href="https://docs.serphouse.com/extra-apis/domains-list">List of Search Engines</a></td></tr><tr><td>lang<mark style="color:red;">*</mark></td><td>string</td><td>You can set language for e.g. <code>en</code> for english <code>fr</code> for french.<br>Get the list of available languages by making a separate request to the <a href="/pages/T3o6bzC5LzinD9qIGamk">List of Language</a></td></tr><tr><td>gl<mark style="color:red;">*</mark></td><td>string</td><td>Optional field if you specify <code>loc</code><br><br><strong>The request must include either <code>loc</code> or <code>gl</code></strong><br><br>The <code>gl</code> parameter accepts only two-letter ISO country codes (e.g. <code>IN</code>, <code>US</code>, <code>GB</code>). You can retrieve the list of supported country codes from the <a href="/pages/jHif4hVWEf1ax1cYtvip">List of Locations</a> endpoint.</td></tr><tr><td>loc<mark style="color:red;">*</mark></td><td>string</td><td>Optional field if you specify <code>gl</code>  <br><br><strong>The request must include either <code>loc</code> or <code>gl</code></strong><br><br>You can receive the list of available locations of search engines with their loc_id by making a separate request to the <a href="https://docs.serphouse.com/extra-apis/locations-list">List of Locations</a></td></tr><tr><td>page</td><td>integer</td><td>Give specific page to get the result of that page number. By default it will get you first page.</td></tr><tr><td>date_range</td><td>String</td><td><p>Sometimes you may want to only find information published during a specific time frame. To limit Google results by date</p><p>Parameter values can be comma seprated date range <code>YYYY-MM-DD,YYYY-MM-DD</code> OR</p><p><code>h</code> Past hour</p><p><code>d</code> Past 24 hours</p><p><code>w</code> Past week</p><p><code>m</code> Past month</p><p><code>y</code> Past year </p></td></tr><tr><td>verbatim</td><td>integer</td><td>Set Google Verbatim search, Parameter value can be <code>0</code> or <code>1</code></td></tr><tr><td>no_trace</td><td>string | integer</td><td>Enterprise only. Enables NoTrace mode. Accepted values: <code>0</code>, <code>1</code>, <code>true</code>, and <code>false</code>. When enabled (<code>1</code> or <code>true</code>), search parameters, files, and metadata are not stored on our servers.</td></tr></tbody></table>

{% tabs %}
{% tab title="200: OK" %}

```json
{
    "status": "error",
    "msg": "Please try again",
    "error": ""
}
```

{% endtab %}

{% tab title="200: OK" %}

```json
{
    "status": "success",
    "msg": "Completed",
    "results": {
        "search_parameters": {
            "q": "AI coding assistant"
        },
        "results": {
            "organic": [
                {
                    "title": "8 Best AI Coding Assistants [Updated May 2026]",
                    "site_title": "Augment Code",
                    "link": "https://www.augmentcode.com/tools/8-top-ai-coding-assistants-and-their-best-use-cases",
                    "snippet": "8 Best AI Coding Assistants [Updated May 2026] · 1. Augment Code · 2. Cursor · 3. GitHub Copilot · 4. Amazon Q Developer · 5. JetBrains AI Assistant."
                },
                {
                    "title": "AI Code",
                    "site_title": "DeepAI",
                    "link": "https://deepai.org/chat/ai-code",
                    "snippet": "An AI coding assistant designed to help with programming-related queries. Provides assistance by suggesting code snippets, debugging code, explaining ..."
                },
                {
                    "title": "Best AI assistant for coding right now? (Beginner who ...",
                    "site_title": "Reddit&nbsp;·&nbsp;r/vibecoding",
                    "link": "https://www.reddit.com/r/vibecoding/comments/1mqd4zx/best_ai_assistant_for_coding_right_now_beginner/",
                    "snippet": "(Edit: am looking and no problem with paid ai assistant for best results ) Hey everyone, I am sorry if this question have been asked many times before, ..."
                },
                {
                    "title": "I Tested Every AI Coding Assistant: Here&#39;s What Actually ...",
                    "site_title": "Stackademic",
                    "link": "https://blog.stackademic.com/i-tested-every-ai-coding-assistant-heres-what-actually-works-a87b50c78852",
                    "snippet": "Cursor wins on speed, but Copilot had fewer bugs in the generated code. I spent 8 extra minutes debugging Cursor's suggestions vs 3 minutes with ..."
                },
                {
                    "title": "Gemini Code Assist",
                    "site_title": "codeassist.google",
                    "link": "https://codeassist.google/products/business",
                    "snippet": "Secure generative AI coding assistance and agents to help you with tasks across the Software Development Lifecycle."
                },
                {
                    "title": "Code Assist",
                    "site_title": "Oracle",
                    "link": "https://www.oracle.com/application-development/code-assist/",
                    "snippet": "Oracle Code Assist is an AI code companion to boost developer velocity, enhance code consistency, and is optimized for Java, SuiteScript, PL/SQL, and ..."
                },
                {
                    "title": "CodeGPT - AI Coding Assistant with Your Own API Key",
                    "site_title": "CodeGPT",
                    "link": "https://codegpt.co/",
                    "snippet": "CodeGPT empowers developers and businesses to build and deploy AI coding agents securely and flexibly. It integrates directly into Visual Studio Code with a ..."
                },
                {
                    "title": "The Best AI Coding Assistants: 20 Tools Reviewed for 2026",
                    "site_title": "Axify",
                    "link": "https://axify.io/blog/the-best-ai-coding-assistants-a-full-comparison-of-20-tools",
                    "snippet": "An AI coding assistant is a tool that helps you generate code. It interprets your natural language prompts and offers you intelligent code ..."
                },
                {
                    "title": "Best AI Coding Agents Summer 2025 - Martin ter Haak - Medium",
                    "site_title": "Medium&nbsp;·&nbsp;Martin ter Haak",
                    "link": "https://martinterhaak.medium.com/best-ai-coding-agents-summer-2025-c4d20cd0c846",
                    "snippet": "Out of all AI tools, I found Windsurf to be the best at helping you write code quickly. Its suggestions save you lots of clicking and typing ( ..."
                },
                {
                    "title": "We Tier Ranked Every AI Coding Assistant",
                    "site_title": "YouTube&nbsp;·&nbsp;Syntax",
                    "link": "https://www.youtube.com/watch?v=tCGju2JB5Fw",
                    "snippet": "We put today's biggest AI coding assistants to the test, Copilot, Cursor, Claude, bolt.new, v0, and more, and ranked them from S-tier to ..."
                }
            ]
        }
    }
}
```

{% endtab %}

{% tab title="400: Bad Request " %}

```json
{
    "status": "error",
    "msg": "validation_error",
    "error": {
        "q": [
            "The q field is required."
        ]
    }
}
```

{% endtab %}

{% tab title="402: Payment Required" %}

```json
{
    "status": "error",
    "msg": "Your SERPHouse account has either run out of available credits (try upgrading your Plan), or there is a payment problem.",
    "error": ""
}
```

{% endtab %}

{% tab title="400: Bad Request " %}

```json
{
    "status": "error",
    "msg": "Missing required fields.",
    "error": ""
}
```

{% endtab %}

{% tab title="401: Unauthorized" %}

```json
{
    "status": "error",
    "msg": "Unauthenticated"
}
```

{% endtab %}
{% endtabs %}

## Example request:

{% tabs %}
{% tab title="BASH" %}

<pre class="language-bash"><code class="lang-bash">curl --location --request <a data-footnote-ref href="#user-content-fn-1">POST </a>'https://api.serphouse.com/web-search-lite' \
--header 'Authorization: Bearer &#x3C;YOUR_API_KEY>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "data": {
        "q": "AI coding assistant",
        "domain": "google.com",
        "lang": "en", 
        "loc": "US"
    }
}'
</code></pre>

{% endtab %}

{% tab title="RUBY" %}

```ruby
require "uri"
require "json"
require "net/http"

url = URI("https://api.serphouse.com/web-search-lite")

https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Content-Type"] = "application/json"
request["Authorization"] = "Bearer <YOUR_API_KEY>"
request.body = JSON.dump({
  "data": {
    "q": "AI coding assistant",
    "domain": "google.com",
    "lang": "en",
    "loc": "US"
  }
})

response = https.request(request)
puts response.read_body
```

{% endtab %}

{% tab title="PYTHON" %}

```python
import requests
import json

url = "https://api.serphouse.com/web-search-lite"

payload = json.dumps({
  "data": {
    "q": "AI coding assistant",
    "domain": "google.com",
    "lang": "en", 
    "loc": "US"
  }
})
headers = {
  'Authorization': 'Bearer <YOUR_API_KEY>',
  'Content-Type': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

```

{% endtab %}

{% tab title="NODE.JS" %}

```javascript
var axios = require('axios');
var data = JSON.stringify({
  "data": {
    "q": "AI coding assistant",
    "domain": "google.com",
    "lang": "en", 
    "loc": "US"
  }
});

var config = {
  method: 'post',
  url: 'https://api.serphouse.com/web-search-lite',
  headers: { 
    'Content-Type': 'application/json', 
    'Authorization': 'Bearer <YOUR_API_KEY>'
  },
  data : data
};

axios(config)
.then(function (response) {
  console.log(JSON.stringify(response.data));
})
.catch(function (error) {
  console.log(error);
});

```

{% endtab %}

{% tab title="JAVA" %}

```java

OkHttpClient client = new OkHttpClient().newBuilder().build();
MediaType mediaType = MediaType.parse("application/json");

JSONObject jsonObject = new JSONObject();
JSONObject dataObject = new JSONObject();
dataObject.put("q", "AI coding assistant");
dataObject.put("domain", "google.com");
dataObject.put("lang", "en");
dataObject.put("loc", "US");
jsonObject.put("data", dataObject);

String bodyJson = jsonObject.toString();
RequestBody body = RequestBody.create(mediaType,bodyJson);

Request request = new Request.Builder()
        .url("https://api.serphouse.com/web-search-lite")
        .method("POST", body)
        .addHeader("Content-Type", "application/json")
        .addHeader("Authorization", "Bearer <YOUR_API_KEY>")
        .build();
Response response = client.newCall(request).execute();
System.out.println(response.body().string());git
```

{% endtab %}

{% tab title="JAVASCRIPT" %}

```javascript
var myHeaders = new Headers();
myHeaders.append("Authorization", "Bearer <YOUR_API_KEY>");
myHeaders.append("Content-Type", "application/json");

var raw = JSON.stringify({
  "data": {
    "q": "AI coding assistant",
    "domain": "google.com",
    "lang": "en",
    "loc": "US",
  }
});

var requestOptions = {
  method: 'POST',
  headers: myHeaders,
  body: raw,
  redirect: 'follow'
};

fetch("https://api.serphouse.com/web-search-lite", requestOptions)
  .then(response => response.text())
  .then(result => console.log(result))
  .catch(error => console.log('error', error));
```

{% endtab %}

{% tab title="GO" %}

```go
package main

import (
  "fmt"
  "strings"
  "net/http"
  "io/ioutil"
)

func main() {

  url := "https://api.serphouse.com/web-search-lite"
  method := "POST"

  payload := strings.NewReader(`{
    "data": {
        "q": "AI coding assistant",
        "domain": "google.com",
        "lang": "en", 
        "loc": "US"
    }
}`)

  client := &http.Client {
  }
  req, err := http.NewRequest(method, url, payload)

  if err != nil {
    fmt.Println(err)
    return
  }
  req.Header.Add("Content-Type", "application/json")
  req.Header.Add("Authorization", "Bearer <YOUR_API_KEY>")

  res, err := client.Do(req)
  if err != nil {
    fmt.Println(err)
    return
  }
  defer res.Body.Close()

  body, err := ioutil.ReadAll(res.Body)
  if err != nil {
    fmt.Println(err)
    return
  }
  fmt.Println(string(body))
}
```

{% endtab %}

{% tab title="C#/.NET" %}

```csharp
var client = new RestClient("https://api.serphouse.com/web-search-lite");
client.Timeout = -1;
var request = new RestRequest(Method.POST);
request.AddHeader("Content-Type", "application/json");
request.AddHeader("Authorization", "Bearer <YOUR_API_KEY>");
var body = @"{
	""data"": {
			""q"": ""AI coding assistant"",
			""domain"": ""google.com"",
			""lang"": ""en"",
			""loc"": ""US"",
	 }
}";
request.AddParameter("application/json", body,  ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
Console.WriteLine(response.Content);
```

{% endtab %}
{% endtabs %}

[^1]:
