# Google Search Results Scraper (`parseforge/google-search-scraper`) Actor

Scrape search engine results at lightning speed! Run any query and pull ranked URLs, titles, snippets, hostnames, and positions across pages. Supports country and language targeting, perfect for SEO research, SERP tracking, and competitor monitoring. Start searching in minutes!

- **URL**: https://apify.com/parseforge/google-search-scraper.md
- **Developed by:** [ParseForge](https://apify.com/parseforge) (community)
- **Categories:** SEO tools, AI, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per event

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

![ParseForge Banner](https://github.com/ParseForge/apify-assets/blob/ad35ccc13ddd068b9d6cba33f323962e39aed5b2/banner.jpg?raw=true)

## 🔍 Google Search Scraper

> 🚀 **Get SERP results for any query in seconds.** Multi-engine support (Google, Bing, DuckDuckGo), **country and language targeting**, multi-page pagination, and 11 metadata fields per result. No API key, no registration, no CAPTCHAs to solve.

> 🕒 **Last updated:** 2026-04-24 · **📊 11 fields** per result · **🌐 3 engines** · **⚡ 100 results in ~22 seconds** · **🌍 Geo + language targeting**

The **Google Search Scraper** collects search engine results with rank, title, URL, description, and displayed URL from Google, Bing, or DuckDuckGo. Each query can be paginated across multiple pages. Country and language targeting deliver localized SERPs, so you can track rankings in specific markets. The output schema is identical across engines, which means you can switch engines without reworking downstream code.

Bing is the default because it consistently returns real URLs without rate limits. DuckDuckGo is a strong alternative when you want privacy-respectful search. Google mode is available for teams that specifically need Google's ranking signals and comes with integrated support for Apify residential proxy. Batch queries run in parallel, so a list of 10 queries across 10 pages completes in under a minute.

| 🎯 Target Audience | 💡 Primary Use Cases |
|---|---|
| SEO teams, marketing analysts, competitive intelligence, lead gen operators, researchers, growth marketers | SERP monitoring, competitor rank tracking, keyword research, link discovery, content strategy |

---

### 📋 What the Google Search Scraper does

Six SERP workflows in a single run:

- 🔎 **Multi-engine.** Query Google, Bing, or DuckDuckGo with the same input schema.
- 🌍 **Country targeting.** Pass ISO country codes for localized results.
- 🗣️ **Language targeting.** Pass ISO language codes for multilingual SERPs.
- 📄 **Pagination.** Crawl multiple pages per query to go beyond the first 10 results.
- 🧠 **Batch queries.** Feed a list of queries and get every result in one run.
- 🏆 **Rank preserved.** Every result includes its `resultRank` on the engine for ranking analysis.

Each record includes the source query, page number, engine name, URL, displayed URL, title, description, result type (organic, related, PAA), and domain.

> 💡 **Why it matters:** SERP data is the foundation of SEO audits, content strategy, and competitive intelligence. DIY scrapers get blocked; paid SERP APIs cost $99 to $500 per month. This Actor sits in the middle with pay-per-use pricing.

---

### 🎬 Full Demo

_🚧 Coming soon: a 3-minute walkthrough showing rank tracking across engines._

---

### ⚙️ Input

<table>
<thead>
<tr><th>Input</th><th>Type</th><th>Default</th><th>Behavior</th></tr>
</thead>
<tbody>
<tr><td><code>queries</code></td><td>array of strings</td><td>required</td><td>One or more search terms. Each runs independently.</td></tr>
<tr><td><code>engine</code></td><td>string</td><td><code>"bing"</code></td><td><code>bing</code>, <code>duckduckgo</code>, or <code>google</code>.</td></tr>
<tr><td><code>countryCode</code></td><td>string</td><td><code>"us"</code></td><td>ISO 3166-1 alpha-2 country code.</td></tr>
<tr><td><code>languageCode</code></td><td>string</td><td><code>"en"</code></td><td>ISO 639-1 language code.</td></tr>
<tr><td><code>resultsPerPage</code></td><td>integer</td><td><code>10</code></td><td>Results to fetch per page (1-100).</td></tr>
<tr><td><code>maxPagesPerQuery</code></td><td>integer</td><td><code>1</code></td><td>Pages to fetch per query.</td></tr>
<tr><td><code>maxItems</code></td><td>integer</td><td><code>10</code></td><td>Records returned. Free plan caps at 10, paid plan at 1,000,000.</td></tr>
<tr><td><code>proxyConfiguration</code></td><td>object</td><td>RESIDENTIAL</td><td>Recommended when using Google mode.</td></tr>
</tbody>
</table>

**Example: SEO rank tracking across multiple queries.**

```json
{
    "queries": ["best web scraping tools", "apify tutorial", "playwright vs puppeteer"],
    "engine": "bing",
    "countryCode": "us",
    "languageCode": "en",
    "resultsPerPage": 10,
    "maxPagesPerQuery": 3,
    "maxItems": 100
}
````

**Example: DuckDuckGo for privacy-respectful research.**

```json
{
    "queries": ["open source llm observability"],
    "engine": "duckduckgo",
    "maxItems": 30
}
```

> ⚠️ **Good to Know:** Google rate-limits automated access aggressively. If you specifically need Google's SERP, use the Apify residential proxy. For routine SERP monitoring, Bing is the most reliable and has excellent coverage.

***

### 📊 Output

Each result contains **11 fields**. Download the dataset as CSV, Excel, JSON, or XML.

#### 🧾 Schema

| Field | Type | Example |
|---|---|---|
| 🔎 `query` | string | `"best web scraping tools"` |
| ⚙️ `engine` | string | `"bing"` |
| 🏆 `resultRank` | number | `1` |
| 📄 `page` | number | `1` |
| 🔗 `url` | string | `"https://apify.com/blog/web-scraping-tools"` |
| 🏷️ `title` | string | `"Web scraping tools comparison 2026"` |
| 📝 `description` | string | `"A detailed comparison..."` |
| 🌐 `displayedUrl` | string | null | `"apify.com/blog/web-scraping-tools"` |
| 🎯 `type` | string | `"organic"` |
| 🏢 `domain` | string | null | `"apify.com"` |
| 🕒 `scrapedAt` | ISO 8601 | `"2026-04-21T12:00:00.000Z"` |

#### 📦 Sample records

<details>
<summary><strong>🏆 Top organic result</strong></summary>

```json
{
    "query": "best web scraping tools",
    "engine": "bing",
    "resultRank": 1,
    "page": 1,
    "url": "https://apify.com/blog/web-scraping-tools",
    "displayedUrl": "apify.com/blog/web-scraping-tools",
    "title": "Web scraping tools comparison 2026",
    "description": "A detailed comparison of the best web scraping tools in 2026 including code libraries, visual builders, and cloud platforms.",
    "type": "organic",
    "domain": "apify.com",
    "scrapedAt": "2026-04-21T12:00:00.000Z"
}
```

</details>

<details>
<summary><strong>🔎 Related search result</strong></summary>

```json
{
    "query": "best web scraping tools",
    "engine": "google",
    "resultRank": 9998,
    "page": 1,
    "url": "",
    "displayedUrl": null,
    "title": "web scraping tools python",
    "description": "",
    "type": "related_search",
    "domain": null,
    "scrapedAt": "2026-04-21T12:00:00.000Z"
}
```

</details>

<details>
<summary><strong>❓ People Also Ask entry</strong></summary>

```json
{
    "query": "best web scraping tools",
    "engine": "google",
    "resultRank": 9999,
    "page": 1,
    "url": "",
    "displayedUrl": null,
    "title": "What is the easiest web scraping tool?",
    "description": "",
    "type": "people_also_ask",
    "domain": null,
    "scrapedAt": "2026-04-21T12:00:00.000Z"
}
```

</details>

***

### ✨ Why choose this Actor

| | Capability |
|---|---|
| 🌐 | **Three engines.** Google, Bing, DuckDuckGo with the same output schema. |
| 🌍 | **Geo and language targeting.** Localized SERPs for 200+ country codes. |
| 📄 | **Pagination.** Go beyond the first page with `maxPagesPerQuery`. |
| 🏆 | **Rank preserved.** Every result includes its rank on the source engine. |
| ⚡ | **Fast.** 100 results in about 22 seconds on Bing. |
| 🔁 | **Batch queries.** Feed a list of terms; every result lands in one dataset. |
| 🚫 | **No SERP API subscription.** Pay-per-use instead of $99+ monthly fees. |

> 📊 Accurate SERP data is the single most important input for SEO strategy. Rank changes signal content opportunities, competitor moves, and algorithm updates.

***

### 📈 How it compares to alternatives

| Approach | Cost | Coverage | Refresh | Filters | Setup |
|---|---|---|---|---|---|
| **⭐ Google Search Scraper** *(this Actor)* | $5 free credit, then pay-per-use | 3 engines | **Live per run** | geo, language, pagination | ⚡ 2 min |
| Paid SERP APIs | $99-500+/month | Usually Google only | Real-time | Rich | ⏳ Hours |
| DIY scraping scripts | Free | Whatever you code | Your schedule | Whatever you build | 🐢 Days |
| Browser extensions | Free | Single user, manual | Manual | Basic | 🕒 Variable |

Pick this Actor when you want flexible engine selection and pay-per-use billing without committing to a SERP API subscription.

***

### 🚀 How to use

1. 📝 **Sign up.** [Create a free account with $5 credit](https://console.apify.com/sign-up?fpr=vmoqkp) (takes 2 minutes).
2. 🌐 **Open the Actor.** Go to the Google Search Scraper page on the Apify Store.
3. 🎯 **Pick an engine and queries.** Add queries, set country and language, choose pages.
4. 🚀 **Run it.** Click **Start** and let the Actor collect your SERP data.
5. 📥 **Download.** Grab your results in the **Dataset** tab as CSV, Excel, JSON, or XML.

> ⏱️ Total time from signup to downloaded dataset: **3-5 minutes.** No coding required.

***

### 💼 Business use cases

<table>
<tr>
<td width="50%" valign="top">

#### 🎯 SEO & Rank Tracking

- Daily rank monitoring for target keywords
- Track competitor domains in top results
- Watch SERP feature changes over time
- Build keyword research datasets

</td>
<td width="50%" valign="top">

#### 📊 Content Strategy

- Discover what ranks for a topic
- Identify top-performing formats per query
- Map SERP intent (informational, commercial)
- Prioritize content gaps to fill

</td>
</tr>
<tr>
<td width="50%" valign="top">

#### 📈 Competitive Intelligence

- See which competitors dominate your terms
- Track new entrants on branded searches
- Map competitor content footprints
- Monitor PR placement in SERPs

</td>
<td width="50%" valign="top">

#### 💼 Lead Generation

- Pull contact pages from companies ranking for niche queries
- Discover emerging vendors in a category
- Build prospect lists by SERP presence
- Qualify leads by search visibility

</td>
</tr>
</table>

***

### 🔌 Automating Google Search Scraper

Control the scraper programmatically for scheduled runs and pipeline integrations:

- 🟢 **Node.js.** Install the `apify-client` NPM package.
- 🐍 **Python.** Use the `apify-client` PyPI package.
- 📚 See the [Apify API documentation](https://docs.apify.com/api/v2) for full details.

The [Apify Schedules feature](https://docs.apify.com/platform/schedules) lets you trigger this Actor daily or weekly for rank tracking. Pipe the output into your SEO dashboard via webhook.

### 🌟 Beyond business use cases

Data like this powers more than commercial workflows. The same structured records support research, education, civic projects, and personal initiatives.

<table>
<tr>
<td width="50%">

#### 🎓 Research and academia

- Empirical datasets for papers, thesis work, and coursework
- Longitudinal studies tracking changes across snapshots
- Reproducible research with cited, versioned data pulls
- Classroom exercises on data analysis and ethical scraping

</td>
<td width="50%">

#### 🎨 Personal and creative

- Side projects, portfolio demos, and indie app launches
- Data visualizations, dashboards, and infographics
- Content research for bloggers, YouTubers, and podcasters
- Hobbyist collections and personal trackers

</td>
</tr>
<tr>
<td width="50%">

#### 🤝 Non-profit and civic

- Transparency reporting and accountability projects
- Advocacy campaigns backed by public-interest data
- Community-run databases for local issues
- Investigative journalism on public records

</td>
<td width="50%">

#### 🧪 Experimentation

- Prototype AI and machine-learning pipelines with real data
- Validate product-market hypotheses before engineering spend
- Train small domain-specific models on niche corpora
- Test dashboard concepts with live input

</td>
</tr>
</table>

***

### 🤖 Ask an AI assistant about this scraper

Open a ready-to-send prompt about this ParseForge actor in the AI of your choice:

- 💬 [**ChatGPT**](https://chat.openai.com/?q=How%20do%20I%20use%20the%20GOOGLE%20SEARCH%20RESULTS%20SCRAPER%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🧠 [**Claude**](https://claude.ai/new?q=How%20do%20I%20use%20the%20GOOGLE%20SEARCH%20RESULTS%20SCRAPER%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🔍 [**Perplexity**](https://perplexity.ai/search?q=How%20do%20I%20use%20the%20GOOGLE%20SEARCH%20RESULTS%20SCRAPER%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🅒 [**Copilot**](https://copilot.microsoft.com/?q=How%20do%20I%20use%20the%20GOOGLE%20SEARCH%20RESULTS%20SCRAPER%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)

***

***

### ❓ Frequently Asked Questions

<details>
<summary><strong>🧩 How does it work?</strong></summary>

Pass a list of queries. The Actor sends them to the selected engine with your country and language settings, parses the HTML, and returns a clean row per result. Multiple pages per query are fetched sequentially.

</details>

<details>
<summary><strong>📏 How accurate are the rankings?</strong></summary>

Accurate for the selected engine at the time of the run. Rankings shift by geo, device, and personalization, so always match the country and language to your target market.

</details>

<details>
<summary><strong>🎯 Which engine should I use?</strong></summary>

Bing for reliable high-volume runs. DuckDuckGo for privacy-sensitive research. Google when you specifically need Google's ranking signals and are willing to use residential proxy.

</details>

<details>
<summary><strong>🔁 Do results change by country code?</strong></summary>

Yes. Bing, Google, and DuckDuckGo all localize heavily. Pass `gb` for UK, `de` for Germany, `jp` for Japan, etc.

</details>

<details>
<summary><strong>⏰ Can I schedule daily rank tracking?</strong></summary>

Yes. Use Apify Schedules to run the same queries daily or weekly and track movement over time.

</details>

<details>
<summary><strong>⚖️ Is SERP scraping legal?</strong></summary>

Search engines' terms of service generally prohibit automated scraping. SERP APIs and rank tracking are standard tools in SEO, and search engines typically issue IP-level blocks rather than legal action. Consult legal counsel for commercial use.

</details>

<details>
<summary><strong>💼 Can I use this commercially?</strong></summary>

SERP data is widely used for SEO, content strategy, and market research. Commercial use is common, but respect each engine's terms.

</details>

<details>
<summary><strong>💳 Do I need a paid Apify plan to use this Actor?</strong></summary>

No. Free plan covers testing (10 results per run). A paid plan lifts the limit, speeds up concurrency, and includes access to the Apify residential proxy.

</details>

<details>
<summary><strong>🔁 What happens if a run fails?</strong></summary>

Apify retries transient errors. Individual failed pages are logged but the run continues. Partial results are preserved.

</details>

<details>
<summary><strong>🎨 Can I get more than 100 results per query?</strong></summary>

Yes. Increase `maxPagesPerQuery`. Each engine returns 10-30 results per page depending on the engine and query.

</details>

<details>
<summary><strong>🌍 Does it support Chinese, Russian, Japanese SERPs?</strong></summary>

Yes. Bing and DuckDuckGo support most languages. Pass the right `languageCode` and `countryCode` combo for localized results.

</details>

<details>
<summary><strong>🆘 What if I need help?</strong></summary>

Our team is available through the Apify platform and the Tally form below.

</details>

***

### 🔌 Integrate with any app

Google Search Scraper connects to any cloud service via [Apify integrations](https://apify.com/integrations):

- [**Make**](https://docs.apify.com/platform/integrations/make) - Automate rank tracking workflows
- [**Zapier**](https://docs.apify.com/platform/integrations/zapier) - Push SERP changes to Slack or Sheets
- [**Slack**](https://docs.apify.com/platform/integrations/slack) - Alert on rank movements
- [**Airbyte**](https://docs.apify.com/platform/integrations/airbyte) - Pipe SERPs into your warehouse
- [**GitHub**](https://docs.apify.com/platform/integrations/github) - Trigger runs from commits
- [**Google Drive**](https://docs.apify.com/platform/integrations/drive) - Export SERPs to Sheets

You can also use webhooks to trigger rank-alerting pipelines and dashboard updates.

***

### 🔗 Recommended Actors

- [**📈 Google Trends Scraper**](https://apify.com/parseforge/google-trends-scraper) - Interest over time and related queries
- [**🗺️ Google Maps Scraper**](https://apify.com/parseforge/google-maps-scraper) - Local business data from Maps
- [**🤖 RAG Web Browser**](https://apify.com/parseforge/rag-web-browser) - Search or fetch URLs with LLM-ready output
- [**🕸️ Website Content Crawler**](https://apify.com/parseforge/website-content-crawler) - Deep-crawl a domain
- [**📰 Smart Article Extractor**](https://apify.com/parseforge/article-extractor) - Extract articles from news sites

> 💡 **Pro Tip:** browse the complete [ParseForge collection](https://apify.com/parseforge) for more SEO and search tools.

***

**🆘 Need Help?** [**Open our contact form**](https://tally.so/r/BzdKgA) to request a new scraper, propose a custom data project, or report an issue.

***

> **⚠️ Disclaimer:** this Actor is an independent tool and is not affiliated with Google, Microsoft, or DuckDuckGo. It accesses only publicly accessible search results. Respect each engine's terms of service and applicable laws when using results commercially.

# Actor input Schema

## `queries` (type: `array`):

Search queries. One result set per query.

## `engine` (type: `string`):

Which engine to use. Bing is most reliable; Google requires browser automation and is rate-limited.

## `countryCode` (type: `string`):

ISO 3166-1 alpha-2 country code.

## `languageCode` (type: `string`):

ISO 639-1 language code.

## `resultsPerPage` (type: `integer`):

Number of results returned per page

## `maxPagesPerQuery` (type: `integer`):

Maximum pages to fetch per query

## `maxItems` (type: `integer`):

Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000

## `includePaa` (type: `boolean`):

Include People Also Ask questions (billed per PAA item).

## `includeRelated` (type: `boolean`):

Include related search suggestions (billed per related item).

## `includeRichSnippets` (type: `boolean`):

Include featured snippets, videos, image packs, top stories, discussions (billed per rich snippet).

## `includeKnowledgePanel` (type: `boolean`):

Include Google knowledge panel entries (billed per panel).

## `includeLocalPack` (type: `boolean`):

Include local business results (billed per local pack item).

## `includeWidgets` (type: `boolean`):

Include stock, weather, translate widgets (billed per widget).

## `proxyConfiguration` (type: `object`):

Apify proxy configuration

## Actor input object example

```json
{
  "queries": [
    "best web scraping tools",
    "apify tutorial"
  ],
  "engine": "bing",
  "countryCode": "us",
  "languageCode": "en",
  "resultsPerPage": 10,
  "maxPagesPerQuery": 1,
  "maxItems": 10,
  "includePaa": true,
  "includeRelated": true,
  "includeRichSnippets": true,
  "includeKnowledgePanel": true,
  "includeLocalPack": true,
  "includeWidgets": true,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# Actor output Schema

## `results` (type: `string`):

Complete dataset

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "queries": [
        "best web scraping tools",
        "apify tutorial"
    ],
    "engine": "bing",
    "countryCode": "us",
    "languageCode": "en",
    "resultsPerPage": 10,
    "maxPagesPerQuery": 1,
    "maxItems": 10,
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("parseforge/google-search-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "queries": [
        "best web scraping tools",
        "apify tutorial",
    ],
    "engine": "bing",
    "countryCode": "us",
    "languageCode": "en",
    "resultsPerPage": 10,
    "maxPagesPerQuery": 1,
    "maxItems": 10,
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("parseforge/google-search-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "queries": [
    "best web scraping tools",
    "apify tutorial"
  ],
  "engine": "bing",
  "countryCode": "us",
  "languageCode": "en",
  "resultsPerPage": 10,
  "maxPagesPerQuery": 1,
  "maxItems": 10,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call parseforge/google-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=parseforge/google-search-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Google Search Results Scraper",
        "description": "Scrape search engine results at lightning speed! Run any query and pull ranked URLs, titles, snippets, hostnames, and positions across pages. Supports country and language targeting, perfect for SEO research, SERP tracking, and competitor monitoring. Start searching in minutes!",
        "version": "1.0",
        "x-build-id": "qH2lDcZEBZ27AsKR5"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/parseforge~google-search-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-parseforge-google-search-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/parseforge~google-search-scraper/runs": {
            "post": {
                "operationId": "runs-sync-parseforge-google-search-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/parseforge~google-search-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-parseforge-google-search-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "queries"
                ],
                "properties": {
                    "queries": {
                        "title": "Search Queries",
                        "type": "array",
                        "description": "Search queries. One result set per query.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "engine": {
                        "title": "Search Engine",
                        "enum": [
                            "bing",
                            "duckduckgo",
                            "google"
                        ],
                        "type": "string",
                        "description": "Which engine to use. Bing is most reliable; Google requires browser automation and is rate-limited."
                    },
                    "countryCode": {
                        "title": "Country Code (gl)",
                        "type": "string",
                        "description": "ISO 3166-1 alpha-2 country code."
                    },
                    "languageCode": {
                        "title": "Language Code (hl)",
                        "type": "string",
                        "description": "ISO 639-1 language code."
                    },
                    "resultsPerPage": {
                        "title": "Results per Page",
                        "minimum": 1,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Number of results returned per page"
                    },
                    "maxPagesPerQuery": {
                        "title": "Max Pages per Query",
                        "minimum": 1,
                        "maximum": 20,
                        "type": "integer",
                        "description": "Maximum pages to fetch per query"
                    },
                    "maxItems": {
                        "title": "Max Items",
                        "minimum": 1,
                        "maximum": 1000000,
                        "type": "integer",
                        "description": "Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000"
                    },
                    "includePaa": {
                        "title": "Include People Also Ask",
                        "type": "boolean",
                        "description": "Include People Also Ask questions (billed per PAA item).",
                        "default": true
                    },
                    "includeRelated": {
                        "title": "Include Related searches",
                        "type": "boolean",
                        "description": "Include related search suggestions (billed per related item).",
                        "default": true
                    },
                    "includeRichSnippets": {
                        "title": "Include rich snippets",
                        "type": "boolean",
                        "description": "Include featured snippets, videos, image packs, top stories, discussions (billed per rich snippet).",
                        "default": true
                    },
                    "includeKnowledgePanel": {
                        "title": "Include knowledge panel",
                        "type": "boolean",
                        "description": "Include Google knowledge panel entries (billed per panel).",
                        "default": true
                    },
                    "includeLocalPack": {
                        "title": "Include local pack",
                        "type": "boolean",
                        "description": "Include local business results (billed per local pack item).",
                        "default": true
                    },
                    "includeWidgets": {
                        "title": "Include widgets",
                        "type": "boolean",
                        "description": "Include stock, weather, translate widgets (billed per widget).",
                        "default": true
                    },
                    "proxyConfiguration": {
                        "title": "Proxy",
                        "type": "object",
                        "description": "Apify proxy configuration"
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
