Google Forums API
Find forum discussions matching a query.
What is this API?
Serqo’s Google Forums API returns forum and discussion results shown for a Google query as structured JSON. Use engine: "google" and type: "forums"; entries may include discussion titles, source communities, displayed dates and answer previews.
Common use cases
- Find public discussions and questions related to a product or topic.
- Collect the wording and sources of questions people discuss online.
- Monitor whether forum pages appear for selected search queries.
Request example
POST https://api.serqo.io/v1/search
| Field | Value |
|---|---|
| engine | google |
| type | forums |
Request headers
Create an API key and store it on your server. Send the API key in the x-api-key header.
| Header | Value | Description |
|---|---|---|
| Content-Type | application/json | JSON request body. |
| x-api-key | YOUR_API_KEY | API key used to authenticate the request. |
export SERP_API_KEY='YOUR_API_KEY'
curl https://api.serqo.io/v1/search \
-H "x-api-key: $SERP_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"q": "self hosted photo backup",
"engine": "google",
"type": "forums",
"gl": "us",
"hl": "en"
}' Code examples
Use the same API key with a standard HTTP client. These examples require Node.js 22 or later, or Python 3.
const response = await fetch('https://api.serqo.io/v1/search', {
method: 'POST',
headers: { 'x-api-key': process.env.SERP_API_KEY, 'Content-Type': 'application/json' },
body: JSON.stringify({"q": "self hosted photo backup","engine":"google","type":"forums"}),
});
const result = await response.json();
if (!response.ok) throw new Error(`${response.status}: ${result.error?.message ?? 'Search failed'}`);
console.log(result.data);import json
import os
from urllib.request import Request, urlopen
payload = {"q": "self hosted photo backup","engine":"google","type":"forums"}
request = Request(
'https://api.serqo.io/v1/search',
data=json.dumps(payload).encode(),
headers={
'x-api-key': os.environ['SERP_API_KEY'],
'Content-Type': 'application/json',
},
)
with urlopen(request) as response:
result = json.load(response)
print(result['data'])Parameters
The number of results returned per request depends on the search engine and may vary.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| q | string | Yes | — | Non-empty search query. |
| engine | string | No | Use google for this API. | |
| type | string | No | web | Use forums for this API. |
| gl | string | No | — | Two-letter lowercase country code, for example us. |
| hl | string | No | — | Interface language code, for example en. |
| start | integer | No | — | Offset from 0 to 1000000. Use nextStart from the response. |
| safe | off | active | No | — | Explicit-content filter: off disables it, active enables it. |
| tbs | string | No | — | Google time filter, such as qdr:d, qdr:w or qdr:m. |
Only q is required by the API, but keep engine and type as shown for this search. A dash means the API does not assign a default. Unknown parameters return 422 INVALID_PARAM.
Response
HTTP 200. A real API response, trimmed to the first three results for readability. Field availability and result groups vary by the returned page; values can be null.
{
"success": true,
"requestId": "req_bcc9a112-06c6-48e4-b263-53334b5b5c2d",
"data": {
"engine": "google",
"type": "forums",
"query": {
"q": "self hosted photo backup",
"gl": "us",
"hl": "en"
},
"searchInformation": {
"totalResults": 395000,
"timeTakenMs": 300,
"displayed": "About 395,000 results"
},
"results": [
{
"position": 1,
"type": "forum",
"title": "BEST photos solution in 2024? What are you using?",
"url": "https://www.reddit.com/r/selfhosted/comments/196khet/best_photos_solution_in_2024_what_are_you_using/",
"displayedUrl": null,
"domain": "reddit.com",
"source": "Reddit · r/selfhosted",
"date": null,
"snippet": "My new years resolution is to go FOSS (or at least self-hosted) meaning I need to get away from my current Google Photos and Adobe Lightroom ...",
"snippetHighlightedWords": [],
"thumbnail": null,
"favicon": null,
"duration": null,
"price": null,
"rating": null,
"sitelinks": [
{
"title": "96 answers",
"url": "https://www.google.com/goto?url=CAESqAEB6zswFcrnALKlR6AS5CYpYanaOH0zGGSFbHPrLm15KNurGYccL1XwaESMrJ2W6ui9Tk6GJLU4yMDg-3mlU8xNItVSurC2pPhhViE6u_tItc1xuNzacDCvchJr5oDkZmKgqeFeHogRyZn3Te75aSZQEPNG3Jg0y6_dKdXjPRW_5MbPWZQhI5-yk_-zvrtpBRb8lbPbtM7vPe2APmo87N4gU2dxR-MeD3k"
},
{
"title": "Self hosted photo management 2024 : r/ selfhosted",
"url": "https://www.google.com/goto?url=CAESkgEB6zswFU4iZw8BzD-p87lcJ5bTm40voFNpVrycY3Sr47VLGFdi-64rmadYrDitvfIaq4NHiPiMMAwmPUHLB4kchiXw5kUOkNeZvYVmV5DO3QJNMze9TTs8_kzoIRRQSvmH4acv60xMVYsrocjwZcmVKMRoLB_Wzl_swH8nDrTVKlmxcKxNm39IC1y5EU5BqgFhAA"
},
{
"title": "Want to self host photos ... Feel out of my depth...",
"url": "https://www.google.com/goto?url=CAESngEB6zswFSbSkD0aXTht2nM29ydYdS2GSeDai_ip7duM3g7fiAsuOr1-sw15Qn_nJaMwTuqnZtWrx6zCEkMbuGCwcaSGYEhfKs9WN8DhZzk9R6BvVsTZLGK8o8qppTv9m7OVc_pdyGAO9HG5ayFtA-GzyBWnP2dKUx-Kgd883ItbAqscuSG3ZU19OZd84iUbSC_p40kobuyp2EFyNh9yQA"
}
],
"extensions": {
"googleRpos": "0"
}
},
{
"position": 2,
"type": "forum",
"title": "photo backup.. - self hosted : is immich the best out there",
"url": "https://www.dpreview.com/forums/threads/photo-backup-self-hosted-is-immich-the-best-out-there.4811025/",
"displayedUrl": "https://www.dpreview.com › ... › Beginners Questions",
"domain": "dpreview.com",
"source": "DPReview",
"date": "Jul 23, 2025",
"snippet": "Jul 23, 2025 — It has a mobile app which allows you to automatically sync your phone photos with the server . If you have a camera and/or you process things ... Read more",
"snippetHighlightedWords": [
"automatically sync your phone photos with the server"
],
"thumbnail": null,
"favicon": null,
"duration": null,
"price": null,
"rating": null,
"sitelinks": [
{
"title": "Read more",
"url": "https://www.google.com/goto?url=CAES5gEB6zswFeNXHXo6JE7g5ucWwCdD3bn_hQlHwnP8ezroXtWzn0qqI36zZ3Xwe91yxcjKkiYKXhBxKZPk0jlfZJQvityZ2LZ1VzJdFWyBpMqaOT4W7FdIB6aiFholvQp7PLDGAuuR2Im52WHJaD__HGZhsn0hOhMqJIeby7lNXUuCMOhqgcV0jTFL_r0jeK1-9x2VqhGEjmf8MAbVCJptgeBajJoxcfGHVTfKGoE4x-rx6VHwFfyoGiEctCioMeT2IJTfiq64HEXjlnmzdYUI39bjLTsfIiQ371mNGoCFscrHceC-ASwGHg"
}
],
"extensions": {
"googleRpos": "1"
}
},
{
"position": 3,
"type": "forum",
"title": "Self Hosted Google Photos - Linux",
"url": "https://forum.level1techs.com/t/self-hosted-google-photos/205893",
"displayedUrl": "https://forum.level1techs.com › ... › Linux",
"domain": "forum.level1techs.com",
"source": "Level1Techs Forums",
"date": "Jan 17, 2024",
"snippet": "Jan 17, 2024 — For my Devember 2023 project I decided to create my own self hosted photo backup solution to use instead of Google Photos. Unfortunately, ... Read more",
"snippetHighlightedWords": [
"self hosted photo backup solution"
],
"thumbnail": null,
"favicon": null,
"duration": null,
"price": null,
"rating": null,
"sitelinks": [
{
"title": "Read more",
"url": "https://www.google.com/goto?url=CAESywEB6zswFcapa93LxnvFbukOZEI_bahb3fYGDvW5P1VGsI5K1eed9-FVSGB-73CekjjWAZ145Y3OONuqZWlXJdUw8lg_L3X2VnLU8UZ_mNNBFxcmFcwVtov_WiVh9U8agYRgYU3qTcNjUIZvHtxdF6Yqoe99fsPMlRo5WNN8mq4hF2luJJEB5AKv0-cp5sMzM7y-pkN76s_cfvziy_xlyUwKgfQ2NhkTcw10hETB60LYZqN6uDgXNnaEa9IAG_JyiLUr8wb8RubltJ6Nkw"
}
],
"extensions": {
"googleRpos": "2"
}
}
],
"features": {
"relatedSearches": [
{
"query": "Self hosted photo backup reddit",
"url": "https://www.google.com/search?safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&q=Self+hosted+photo+backup+reddit&sa=X&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ1QJ6BAg7EAE"
},
{
"query": "Best self hosted photo backup",
"url": "https://www.google.com/search?safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&q=Best+self+hosted+photo+backup&sa=X&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ1QJ6BAhCEAE"
},
{
"query": "Self-hosted cloud storage",
"url": "https://www.google.com/search?safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&q=Self-hosted+cloud+storage&sa=X&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ1QJ6BAhBEAE"
},
{
"query": "Home photo server",
"url": "https://www.google.com/search?safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&q=Home+photo+server&sa=X&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ1QJ6BAg_EAE"
},
{
"query": "PhotoPrism vs Immich",
"url": "https://www.google.com/search?safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&q=PhotoPrism+vs+Immich&sa=X&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ1QJ6BAhAEAE"
},
{
"query": "Immich vs Google Photos",
"url": "https://www.google.com/search?safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&q=Immich+vs+Google+Photos&sa=X&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ1QJ6BAg-EAE"
},
{
"query": "How to create your own cloud photo storage",
"url": "https://www.google.com/search?safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&q=How+to+create+your+own+cloud+photo+storage&sa=X&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ1QJ6BAg9EAE"
},
{
"query": "Best open source photo organizer",
"url": "https://www.google.com/search?safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&q=Best+open+source+photo+organizer&sa=X&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ1QJ6BAg8EAE"
},
{
"query": "2",
"url": "https://www.google.com/search?q=self+hosted+photo+backup&safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&ei=FO_aarPPD4yh5NoP-4OQ2Ac&start=10&sa=N&sstk=AS6-VmKnvbXNVal4Ud1oMvUpZ_sV98WPTRovC6SM3CnZhMdCXCEio56KFGZv5p8eSCv-IM8hddGHFvqYNvKlww_oLibMZpJFC1vfoQ&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ8tMDegQIORAE"
},
{
"query": "3",
"url": "https://www.google.com/search?q=self+hosted+photo+backup&safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&ei=FO_aarPPD4yh5NoP-4OQ2Ac&start=20&sa=N&sstk=AS6-VmKnvbXNVal4Ud1oMvUpZ_sV98WPTRovC6SM3CnZhMdCXCEio56KFGZv5p8eSCv-IM8hddGHFvqYNvKlww_oLibMZpJFC1vfoQ&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ8tMDegQIORAG"
},
{
"query": "4",
"url": "https://www.google.com/search?q=self+hosted+photo+backup&safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&ei=FO_aarPPD4yh5NoP-4OQ2Ac&start=30&sa=N&sstk=AS6-VmKnvbXNVal4Ud1oMvUpZ_sV98WPTRovC6SM3CnZhMdCXCEio56KFGZv5p8eSCv-IM8hddGHFvqYNvKlww_oLibMZpJFC1vfoQ&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ8tMDegQIORAI"
},
{
"query": "5",
"url": "https://www.google.com/search?q=self+hosted+photo+backup&safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&ei=FO_aarPPD4yh5NoP-4OQ2Ac&start=40&sa=N&sstk=AS6-VmKnvbXNVal4Ud1oMvUpZ_sV98WPTRovC6SM3CnZhMdCXCEio56KFGZv5p8eSCv-IM8hddGHFvqYNvKlww_oLibMZpJFC1vfoQ&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ8tMDegQIORAK"
},
{
"query": "6",
"url": "https://www.google.com/search?q=self+hosted+photo+backup&safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&ei=FO_aarPPD4yh5NoP-4OQ2Ac&start=50&sa=N&sstk=AS6-VmKnvbXNVal4Ud1oMvUpZ_sV98WPTRovC6SM3CnZhMdCXCEio56KFGZv5p8eSCv-IM8hddGHFvqYNvKlww_oLibMZpJFC1vfoQ&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ8tMDegQIORAM"
},
{
"query": "7",
"url": "https://www.google.com/search?q=self+hosted+photo+backup&safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&ei=FO_aarPPD4yh5NoP-4OQ2Ac&start=60&sa=N&sstk=AS6-VmKnvbXNVal4Ud1oMvUpZ_sV98WPTRovC6SM3CnZhMdCXCEio56KFGZv5p8eSCv-IM8hddGHFvqYNvKlww_oLibMZpJFC1vfoQ&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ8tMDegQIORAO"
},
{
"query": "8",
"url": "https://www.google.com/search?q=self+hosted+photo+backup&safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&ei=FO_aarPPD4yh5NoP-4OQ2Ac&start=70&sa=N&sstk=AS6-VmKnvbXNVal4Ud1oMvUpZ_sV98WPTRovC6SM3CnZhMdCXCEio56KFGZv5p8eSCv-IM8hddGHFvqYNvKlww_oLibMZpJFC1vfoQ&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ8tMDegQIORAQ"
},
{
"query": "9",
"url": "https://www.google.com/search?q=self+hosted+photo+backup&safe=off&sca_esv=64345335af5ad8d5&udm=18&hl=en&gl=us&sxsrf=APpeQnv5CehHxZw7IkJ2oW7JNb7pe95EJA:1792732948264&ei=FO_aarPPD4yh5NoP-4OQ2Ac&start=80&sa=N&sstk=AS6-VmKnvbXNVal4Ud1oMvUpZ_sV98WPTRovC6SM3CnZhMdCXCEio56KFGZv5p8eSCv-IM8hddGHFvqYNvKlww_oLibMZpJFC1vfoQ&ved=2ahUKEwizqbvUss-XAxWMEFkFHfsBBHsQ8tMDegQIORAS"
}
],
"knowledgePanel": {
"title": null,
"subtitle": null,
"description": null,
"kgmid": null,
"attributes": {
"AutocompletePrediction": "Delete"
},
"sources": []
}
},
"pagination": {
"page": 1,
"start": 0,
"hasNext": true,
"nextStart": 10
},
"meta": {
"elapsedMs": 1864
}
},
"meta": {
"cache": "miss"
}
}
Response fields
| Field | Type | Description |
|---|---|---|
| data.query | object | Search query passed to the engine. |
| data.searchInformation | object | Reported result count and search timing, when provided. |
| success | boolean | Whether the request succeeded. True in this example. |
| requestId | string | Request identifier to include when troubleshooting. |
| data.type | string | Search type used for this response. |
| data.engine | string | Engine that returned the results. |
| data.results | array | Main result list. Check feature groups as well when present. |
| data.features | object | Additional result groups; groups not returned by the engine may be absent. |
| data.pagination | object | Current offset and next-page availability. |
| data.meta.elapsedMs | number | Search duration in milliseconds, not a performance guarantee. |
| meta.cache | string | null | hit, miss, or null if cache status is unknown. |
Result fields
Read data.features.discussionsAndForums when present. Some results may instead appear in data.results; check both before treating a search as empty.
| Field | Type | Description |
|---|---|---|
| data.features.discussionsAndForums[].position | integer | Discussion position. |
| data.features.discussionsAndForums[].title | string | Discussion title. |
| data.features.discussionsAndForums[].link | string | null | Discussion link; may be a Google redirect. |
| data.features.discussionsAndForums[].source | string | null | Forum or source label. |
| data.features.discussionsAndForums[].date | string | null | Displayed date text. |
| data.features.discussionsAndForums[].comments | string | null | Comment-count text. |
| data.features.discussionsAndForums[].community | string | null | Community label. |
| data.features.discussionsAndForums[].answers | array | Answer previews when present. |
| data.features.discussionsAndForums[].answers[].text | string | null | Answer-preview text. |
| data.features.discussionsAndForums[].answers[].votes | string | null | Vote-count text. |
| data.features.discussionsAndForums[].answers[].date | string | null | Answer-date text. |
Main result entries
| Field | Type | Description |
|---|---|---|
| data.results[].domain | string | null | Destination domain, when available. |
| data.results[].favicon | string | null | Site icon when provided. |
| data.results[].sitelinks | array | Additional links nested under the result. |
| data.results[].sitelinks[].title | string | Sitelink label. |
| data.results[].sitelinks[].url | string | null | Sitelink destination. |
| data.results[].extensions | object | Other result-specific properties. |
| data.results[].snippetHighlightedWords | string[], optional | Highlighted terms in the snippet, when provided. |
| data.results[].position | integer | Rank on this results page, starting at 1. |
| data.results[].type | string | Result category: organic, news, image, video, shopping, local, forum, book, patent or ad. This can differ from the request type. |
| data.results[].title | string | null | Title shown in the result. |
| data.results[].url | string | null | Destination URL when resolved; it may be null. |
| data.results[].displayedUrl | string | null | URL or domain displayed by the engine; not always a clickable link. |
| data.results[].source | string | null | Source name or displayed domain. |
| data.results[].date | string | null | Date text when extracted; not necessarily an ISO timestamp. |
| data.results[].snippet | string | null | Result summary. |
| data.results[].thumbnail | string | null | Thumbnail URL or inline data URL, when provided. |
| data.results[].duration | string | null | Video duration text when provided. |
| data.results[].price | string | null | Price text when provided. |
| data.results[].rating | number | null | Rating when provided. |
Pagination
- Check
data.pagination.hasNext; stop when it is false. - Use
data.pagination.nextStartasstart. Keep the other search parameters unchanged. - Send the next request. Each page is a separate search request.
| Field | Type | Description |
|---|---|---|
| data.pagination.nextUrl | string | null | Search-engine URL for the next page, when available; use nextStart with this API. |
| data.pagination.requestedPage | integer | Page requested; may differ from the returned page if the engine does not provide it. |
| data.pagination.page | integer | Current page number. |
| data.pagination.start | integer | Current result offset. |
| data.pagination.hasNext | boolean | Whether another page is available. |
| data.pagination.nextStart | integer | null | Offset for the next request, or null when unavailable. |
Errors
{
"success": false,
"requestId": "req_example",
"error": {
"code": "INVALID_PARAM",
"message": "Unknown parameter \"page\"",
"retryable": false
}
} | Field | Type | Description |
|---|---|---|
| error.code | string | Machine-readable error code. |
| error.message | string | Reason the request failed. |
| error.retryable | boolean | Whether retrying is recommended. |
| error.retryAfterMs | number, optional | Minimum wait before retrying, in milliseconds. |
| HTTP status | Meaning | What to do |
|---|---|---|
| 400 | Invalid request or unsupported search type. | Check the query and engine/type combination. |
| 401 | Missing, invalid or revoked API key. | Check the authentication header and API key. |
| 402 | Insufficient credits. | Check your credit balance. |
| 403 | Permission or plan restriction. | Check account access and plan limits. |
| 422 | Invalid parameter. | Correct the parameter identified by error.message. |
| 429 | Request rate or queue limit. | Follow the retry rules below. |
| 5xx | Server or search service failure. | Keep the requestId; retry only if allowed. |
Retry rules
- Retry only when
error.retryableistrue. - If
error.retryAfterMsis present, wait at least that many milliseconds.
Pricing and limits
- Successful searches use credits at the applicable rate.
- Failed searches and timeouts are not charged.
- Cache hits are free at the default rate. Before searching, your available balance must cover the full request cost.
See plan pricing and rate-limit and credit details.
Frequently asked questions
Does this API measure overall customer sentiment?
No. It returns matching discussion results from a search page; it does not sample all communities or calculate representative sentiment. Analyze the returned items with your own method and context.
How are forum searches charged?
Successful searches use the applicable credit rate for the engine, type and country. Failed searches and timeouts release the reservation; cache hits are free at the default rate. See Pricing and limits below for the current rules.