# Google Dictionary Scraper (`googleapi/google-dictionary-scraper`) Actor

Extract source-backed definitions and available pronunciation, grammar, word forms, dictionary-source links, and related public Google Search context from Google Search dictionary cards. Empty, unavailable, and access-boundary pages never create dataset rows.

- **URL**: https://apify.com/googleapi/google-dictionary-scraper.md
- **Developed by:** [Google API](https://apify.com/googleapi) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.99 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### What does the Google Dictionary Scraper do?

The Google Dictionary Scraper looks up words on [Google Search](https://www.google.com/) and extracts a dictionary-card entry when Google exposes one: headword, definitions, pronunciation, part of speech, examples, synonyms, antonyms, word forms, and the linked dictionary source. It also records visible Google Search context such as AI Overview text, People also ask questions, related searches, and organic result snippets when those sections are present.

The Actor does not invent a definition when the dictionary card is missing. If no dictionary entry can be read, the run summary and logs explain why; no placeholder word record is added.

### Why use the Google Dictionary Scraper?

- Look up one term or a bounded list of words and phrases in a single run.
- Keep lexical fields (senses, pronunciation, grammar, word forms) together with the source link that Google shows.
- Retain optional Search context alongside each dictionary entry.
- Review run summaries and logs when a term has no dictionary card or Google limits access.

The Actor reads public Google Search pages only. It does not sign in, solve CAPTCHAs, rotate proxies after a block, or bypass access controls. Optional `proxyConfiguration` applies to public requests. Access boundaries stop the run. AI Overview prose and ordinary result snippets are not converted into dictionary entries; a reachable page can still produce no rows if it has no dictionary card.

### What data can the Google Dictionary Scraper extract?

| Group | Fields |
| --- | --- |
| Word identity | `word`, `headword`, `syllabification`, `language`, `languageCode`, `partOfSpeech`, `partsOfSpeech` |
| Pronunciation | `pronunciation`, `phoneticSpelling`, `pronunciationText`, `pronunciationAudioUrl`, `pronunciationAudioUrls`, `pronunciationAudioPresent` |
| Lexical content | `definitions`, `definitionEntries`, `definitionCount`, `synonyms`, `synonymCount`, `antonyms`, `antonymCount`, `examples`, `exampleCount` |
| Usage and morphology | `origin`, `etymology`, `wordForms`, `inflections`, `derivedForms`, `domains`, `grammarNotes`, `partOfSpeechNotes`, `otherForms`, `translations`, `translationCount` |
| Source | `sourceName`, `sourceNames`, `sourcePageUrl`, `sourceDomain`, `pageUrl`, `canonicalUrl`, `sourcePageLanguage`, `searchLocale` |
| Search context | `dictionaryCardPresent`, `aiOverviewPresent`, `aiOverviewText`, `aiOverviewCitations`, `peopleAlsoAsk`, `relatedSearches`, `webResults`, `webResultCount` |

There are 50 declared properties. `partsOfSpeech` retains all distinct labels visible on the card, while `partOfSpeech` remains the first-label compatibility field. Repeated definition nodes remain separate senses in source order. The flat lexical fields are the primary contract; `dictionary` is retained as a nested compatibility alias for older consumers. Optional scalar values are `null`; missing collections are empty arrays; counts match their corresponding arrays. The Actor only emits a row when it extracts a non-empty word and at least one definition.

Pronunciation audio URLs are collected from audio/source elements and visible Google text-to-speech links within the dictionary section. Media found only in unrelated search-result sections is excluded.

### How to scrape Google Search dictionary cards

1. Open the Actor’s Input tab.
2. Enter one word in `query`, or add words to `queries`.
3. Optionally set `language`, `maxItems`, `page`, or `maxPages`.
4. Run the Actor and review the dataset and run summary.

### How much will it cost to scrape Google Search?

The Actor’s cost follows its Apify compute usage; there is no fixed per-word price stated here. Runtime grows with the number of words and Google results pages requested. Each page request has a bounded timeout and limited network retries, plus a short delay between requests. Requests stop immediately when Google returns an access boundary. Missing dictionary cards do not cause downstream dictionary-source pages to be fetched.

### Input

See the input tab for the complete configuration.

| Field | Type | Default / bounds | Behavior |
| --- | --- | --- | --- |
| `query` | string | optional, max 120 characters | One word or phrase; a leading `define` or `define:` is stripped. |
| `queries` | array of strings | optional, max 100 terms | Additional terms. |
| `startUrls` | array of `{ "url": "..." }` | optional, max 100 URLs | HTTPS Google Search `/search` URLs with a `q` parameter only. Other hosts/paths are rejected. |
| `language` | string | `en`; 2–3 lowercase letters, optional uppercase region | Sets `hl` on generated URLs and supplies a locale when a start URL has no `hl`. An explicit start URL `hl` takes precedence. |
| `maxItems` | integer | `25`; 1–100 | Maximum unique targets across all three term sources. |
| `page` | integer | `1`; 1–100 | First results page for generated query terms; each Google page is 10 results. Explicit `startUrls` preserve their own `start` offset. |
| `maxPages` | integer | `1`; 1–5 | Consecutive results pages per term, starting at `page`. |
| `proxyConfiguration` | object | optional | Apify proxy for public requests. No rotation or challenge solving after an access boundary. |

`query`, `queries`, and `startUrls` are combined. Duplicate target URLs are removed before `maxItems` is applied. The Actor always deduplicates emitted entries by normalized word, language, and part of speech. `maxPages` applies per target; an access boundary stops the entire run.

Example:

```json
{
  "queries": ["serendipity", "ephemeral"],
  "language": "en",
  "maxItems": 10,
  "page": 1,
  "maxPages": 1
}
```

Direct Google Search URL example:

```json
{
  "startUrls": [
    { "url": "https://www.google.com/search?q=define%3Aserendipity&hl=en" }
  ],
  "maxItems": 1
}
```

### Output

You can download the dataset in various formats such as JSON, HTML, CSV, or Excel.

The following is a shape-only example: angle-bracket strings are placeholders, not scraped dictionary values.

```json
{
  "word": "<headword from the dictionary card>",
  "headword": "<displayed headword>",
  "syllabification": null,
  "language": "<language label when shown>",
  "languageCode": null,
  "partOfSpeech": "<part of speech when shown>",
  "partsOfSpeech": ["<each distinct part-of-speech label shown>"],
  "pronunciation": "<phonetic spelling when shown>",
  "pronunciationAudioUrl": null,
  "pronunciationAudioUrls": [],
  "pronunciationAudioPresent": false,
  "definitions": ["<definition text from Google>"],
  "definitionEntries": [
    { "senseNumber": 1, "definitionText": "<definition text from Google>", "domain": null, "examples": [] }
  ],
  "definitionCount": 1,
  "synonyms": [],
  "synonymCount": 0,
  "antonyms": [],
  "antonymCount": 0,
  "examples": [],
  "exampleCount": 0,
  "origin": null,
  "etymology": null,
  "wordForms": [],
  "inflections": [],
  "derivedForms": [],
  "domains": [],
  "grammarNotes": [],
  "translations": [],
  "translationCount": 0,
  "sourceName": "<dictionary source shown by Google>",
  "sourceNames": ["<dictionary source shown by Google>"],
  "sourcePageUrl": "https://example.org/dictionary-entry",
  "sourceDomain": "example.org",
  "pageUrl": "https://www.google.com/search?q=define%3Aexample&hl=en",
  "canonicalUrl": null,
  "searchLocale": "en",
  "dictionaryCardPresent": true,
  "aiOverviewPresent": false,
  "aiOverviewText": null,
  "aiOverviewCitations": [],
  "peopleAlsoAsk": [],
  "relatedSearches": [],
  "webResults": [],
  "webResultCount": 0,
  "sourcePageLanguage": null,
  "partOfSpeechNotes": [],
  "otherForms": [],
  "dictionary": {
    "word": "<headword from the dictionary card>",
    "headword": "<displayed headword>",
    "language": "<language label when shown>",
    "partOfSpeech": "<part of speech when shown>",
    "pronunciation": "<phonetic spelling when shown>",
    "definitions": ["<definition text from Google>"],
    "synonyms": [],
    "antonyms": [],
    "examples": [],
    "origin": null,
    "wordForms": [],
    "sourceName": "<dictionary source shown by Google>",
    "sourcePageUrl": "https://example.org/dictionary-entry"
  }
}
```

Unavailable scalar data is `null`; lists are empty rather than guessed. Dictionary source details are extracted from Google’s visible dictionary card; the Actor does not fetch those external source pages. The dataset and run summary are available in the Output tab, with downloads in formats such as JSON, HTML, CSV, or Excel.

### Tips and advanced options

- Keep `maxPages` at 1 for normal word lookups; later result pages usually do not contain the dictionary card.
- Use separate terms when you need separate dataset entries; `maxItems` is a global target limit.
- A missing optional pronunciation, synonym, example, or source is left empty/null.
- The Actor has bounded request retries for transport errors only. It does not retry after detecting a Google access boundary.

### FAQ, support, and responsible use

**Why is my dataset empty?** Google may not show a dictionary card for that term, or it may return an access boundary. Check the run summary and logs, and try another term if no card is available.

**Are external dictionary pages fetched?** No. Google’s displayed definition and source link are collected when present; the linked publisher page is not opened.

**Can I provide arbitrary start URLs?** No. Only HTTPS Google Search `/search` URLs with a `q` parameter are accepted.

**Does `proxyConfiguration` route requests through Apify Proxy?** Yes, when supplied and available. A proxy failure does not trigger a retry after an access boundary.

**Where can I get help?** Use the Actor’s Issues tab for support and the API tab for API access. Follow Google’s terms, robots guidance, privacy requirements, and applicable law. This independent Actor is not affiliated with or endorsed by Google.

# Actor input Schema

## `query` (type: `string`):

One word or phrase to look up. A leading 'define' or 'define:' is optional.

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

List of additional words or phrases. Each valid dictionary card becomes one dataset row.

## `startUrls` (type: `array`):

Optional HTTPS Google Search /search URLs containing a q parameter. Other hosts and paths are rejected.

## `language` (type: `string`):

Language for generated query URLs, also used when a supplied start URL has no hl parameter. An explicit start URL hl value takes precedence.

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

Maximum number of unique query targets across query, queries, and startUrls.

## `page` (type: `integer`):

One-based Google Search results page for generated query terms. Each page is 10 results; explicit startUrls preserve their own start offset.

## `maxPages` (type: `integer`):

Maximum consecutive Google result pages checked for each word, starting at page. Access boundaries stop the entire run immediately.

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

Optional Apify proxy for all requests in the fresh public browser context. The Actor stops on access boundaries and never rotates proxies after a block or solves challenges.

## Actor input object example

```json
{
  "language": "en",
  "maxItems": 25,
  "page": 1,
  "maxPages": 1
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

## `summary` (type: `string`):

No description

## `health` (type: `string`):

No description

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("googleapi/google-dictionary-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 = {}

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

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

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

```

## CLI example

```bash
echo '{}' |
apify call googleapi/google-dictionary-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,googleapi/google-dictionary-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/pbw3dCNG8EX13p5cL/builds/CAJ9uXwk5EFEigktN/openapi.json
