# Google Shopping Scraper (Prices, Stores, Price Tracking) (`locaihost/google-shopping`) Actor

Google Shopping products for any search in 44 countries: price as a number with its currency code, earlier price, store, rating, review count, delivery, brand and product ids, with price-change tracking between runs and a free min, median and max price summary per query.

- **URL**: https://apify.com/locaihost/google-shopping.md
- **Developed by:** [locaihost data](https://apify.com/locaihost) (community)
- **Categories:** E-commerce, Lead generation, Agents
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.65 / 1,000 products

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/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

## Google Shopping Scraper (Prices, Stores, Price Tracking)

Search Google Shopping like a shopper and get one row per product offer: the price as a number with its currency code, the crossed-out earlier price and discount, the store, rating and review count, delivery and returns notes, brand, condition and Google's product ids. Each query also gets one free summary row with the lowest, median and highest price and how many stores sell it. Run the same setup again and every row says what the product cost last time, so you can track prices or return only what changed. Works in 44 countries, no login.

### How do I start?

Paste this into the input (JSON tab) and press Start:

```json
{
    "queries": ["wireless headphones"]
}
```

That returns the first 40 products Google Shopping shows in the United States. Want the cheapest refurbished laptops between 300 and 600 euros in Germany, tracked from run to run?

```json
{
    "queries": ["laptop 16 gb", "macbook air m2"],
    "country": "de",
    "sort": "priceLow",
    "minPrice": 300,
    "maxPrice": 600,
    "condition": "refurbished",
    "maxProducts": 100,
    "onlyPriceChanges": true
}
```

A Google Shopping link you copied from your browser works too, and keeps its own filters:

```json
{
    "queries": ["https://www.google.co.uk/search?q=running+shoes&udm=28&gl=gb"]
}
```

### What does each row contain?

One row per product offer, always the same shape, plus one free `summary` row per query (marked "Summary rows" below; product-only fields are left out of those). A field Google did not show for a product is `null`.

| Field | What it holds |
|---|---|
| `type` | product = one product offer Google Shopping showed (charged); summary = the query's free price summary |
| `id` | Stable id: the catalog product plus its headline offer (summary rows: summary:country:query) |
| `query` | The query from your input |
| `position` | 1-based order among the products that matched your filters for this query |
| `pagePosition` | Where Google placed the card on its page, shelves included |
| `title` | Product title as Google shows it |
| `price` | Current price as a number |
| `currency` | ISO 4217 currency code of the price, e.g. USD, EUR, GBP, JPY |
| `priceText` | The price exactly as shown, e.g. "$49.95" or "40,84 €" |
| `oldPrice` | The crossed-out earlier price, when Google shows one |
| `discountPercent` | How far the price is below the earlier price, in percent |
| `merchant` | The store selling the headline offer |
| `moreSellers` | True when Google says other stores sell it too ("& more") |
| `rating` | Product rating out of 5, to two decimals |
| `reviewCount` | Number of product reviews, as an exact number when Google has it |
| `delivery` | Delivery note as shown, e.g. "Free delivery by Sat" |
| `freeDelivery` | True when the delivery note says delivery is free |
| `returns` | Returns note as shown, e.g. "30-day returns" |
| `brand` | The product's brand |
| `condition` | Condition label when the product is not new, as shown ("Pre-owned", "Refurbished") |
| `badges` | Labels on the card such as SALE or LOW PRICE |
| `sponsored` | True when the card sits in a block Google labels as sponsored |
| `section` | The block heading the card sits under, e.g. "Popular options" |
| `shelf` | True for cards in a side shelf rather than the main product grid |
| `productId` | Google's product docid |
| `catalogId` | Google's catalog id for the product (the same across stores) |
| `groupId` | Google's product group id |
| `offerId` | Google's docid for the headline offer |
| `imageUrl` | Product photo |
| `productLink` | Google's product page for this offer, with prices from every store |
| `isNew` | True when this setup has never returned the product before |
| `previousPrice` | The price this setup's last run returned for the product |
| `priceChange` | Price now minus previousPrice (negative = cheaper) |
| `priceChangePct` | priceChange as a percent of previousPrice |
| `firstSeenAt` | When this setup first returned the product |
| `country` | Country searched from |
| `language` | Interface language used |
| `searchUrl` | The Google Shopping page read |
| `scrapedAt` | When the page was read (ISO time) |
| `products` | Summary rows: product rows returned for the query |
| `productsOnPage` | Summary rows: product cards Google showed before filters |
| `minPrice` | Summary rows: lowest price among the matching products |
| `medianPrice` | Summary rows: median price |
| `maxPrice` | Summary rows: highest price |
| `merchantCount` | Summary rows: number of different stores |
| `topMerchants` | Summary rows: up to 5 stores with the most products |
| `onSale` | Summary rows: products with an earlier price |
| `priceDrops` | Summary rows: products cheaper than in the last run |
| `priceRises` | Summary rows: products dearer than in the last run |
| `message` | Summary rows: a plain note on what was found |

Two views are ready in the Output tab: **Products** and **Price summary**.

### How does price tracking work?

Every run remembers, per setup (the same queries, country, language and filters), which products it returned and at what price, in a store on your own account. The next run with the same setup fills `isNew`, `previousPrice`, `priceChange`, `priceChangePct` and `firstSeenAt` on each row.

- `onlyPriceChanges: true` returns only products that are new or whose price moved since the last run. The rest are skipped and not charged.
- `onlyNew: true` returns only products this setup has never returned before.

Schedule the same input daily and you have a price tracker that only charges for what changed. The free summary row still counts every matching product, so you see the whole market each time.

### What do the inputs do?

- **queries**: product searches as you would type them on Google Shopping, or Google Shopping links. Up to 500 per run.
- **country**: where to shop from. Prices, stores and currency are local to it.
- **language**: the interface language. Leave it on the country default unless you need another.
- **maxProducts**: products per query, up to 100. Google shows about 80 to 90 products for a plain search and about 40 for a filtered or sorted one.
- **sort**: relevance, lowest price, highest price or best rated.
- **onlyPriceChanges**: see price tracking above.
- **Advanced (optional)**: minimum and maximum price, condition (new, used, refurbished), on sale only, free delivery only, keep only some stores, and onlyNew.

Google sometimes ignores a price filter or sort order. Each filtered page is checked, asked for again up to twice, and if Google still ignores it the filter is applied here: products outside your price range are dropped before charging and a price sort is redone. The summary row tells you when that happened.

### How much does it cost?

You pay per product row: $3.00 per 1,000 products on the Free and Starter plans, $2.25 per 1,000 products on Scale and $1.65 per 1,000 products on Business. The run start costs a tiny one-time fee. Summary rows are free, never charged. Products skipped by `onlyNew` or `onlyPriceChanges`, or dropped by your filters, are not charged.

Set a maximum charge on the run and it stops cleanly before going over it.

**Free plan:** at most 100 products and 15 Google pages per run. Any paid Apify plan removes both limits.

### Is it legal to use?

The Actor reads the product listings Google Shopping shows to any visitor, without logging in. It returns product and store information only, never data about private people. You are responsible for how you use the results: check the terms of the sites involved and the laws where you work, especially before republishing prices or product photos. Product photos and names belong to their owners.

### What else do people ask?

#### Why is a product's store link not included?

Google Shopping's result page does not carry the stores' own links. `productLink` opens Google's product page, which lists every store's price with a link to each.

#### Why are some prices in a different currency?

Google Shopping sometimes shows offers from stores abroad. `currency` always says which currency each price is in, and the summary row uses only the most common currency of the query.

#### Why did I get fewer products than maxProducts?

Google shows about 80 to 90 products for a plain search and about 40 once a price filter or sort is used. Store and condition filters, and `onlyNew` or `onlyPriceChanges`, return fewer still. The summary row says how many Google showed and how many matched.

#### Can I search several countries at once?

Paste Google Shopping links from different country sites; each link uses its own country. For typed queries, run once per country.

#### What happens if Google refuses a search?

It is asked again with a pause. If it still fails, that query is named in the run's status message and nothing is charged for it.

#### Did it help?

If the Actor saved you time, a rating on its Apify page helps other people find it. Found a problem? Open an issue on the Actor's Issues tab and it gets fixed.

# Changelog

This Actor's version history is a separate document: https://apify.com/locaihost/google-shopping/changelog.md

# Actor input Schema

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

What to search on Google Shopping, one per line (up to 500). A pasted Google Shopping link (google.com/search?q=...\&udm=28) works too: its words, country, language and filters are read from the link.

## `country` (type: `string`):

The country searched from: products, stores and prices are what a shopper there sees, in the local currency. A pasted link with its own gl parameter overrides this for that query.

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

Interface language. Country default uses the country's own language.

## `maxProducts` (type: `integer`):

Most product rows per query. Google Shopping shows about 90 products for a plain search (two pages) and about 40 when a sort or price filter is set.

## `sort` (type: `string`):

Order Google lists the products in. If Google ignores the order, the run sorts the products itself.

## `onlyPriceChanges` (type: `boolean`):

Return only products this setup has not returned before, or whose price changed since it last did. Unchanged products are skipped and cost nothing. Every row carries previousPrice and priceChange either way.

## `minPrice` (type: `integer`):

Only products at or above this price, in the country's currency. Products below it are dropped before charging even if Google shows them.

## `maxPrice` (type: `integer`):

Only products at or below this price, in the country's currency.

## `condition` (type: `string`):

New, used or refurbished only. Google reads this as a word in front of your search; products whose condition does not match are dropped before charging.

## `onSale` (type: `boolean`):

Only products Google marks as on sale (a crossed-out earlier price).

## `freeShipping` (type: `boolean`):

Ask Google for products with free delivery.

## `stores` (type: `array`):

Keep only offers from these stores (part of the name is enough, e.g. walmart, best buy). Leave empty for every store.

## `onlyNew` (type: `boolean`):

Return only products this setup has never returned before, whatever their price.

## Actor input object example

```json
{
  "queries": [
    "wireless headphones",
    "espresso machine",
    "running shoes women"
  ],
  "country": "us",
  "language": "",
  "maxProducts": 20,
  "sort": "relevance",
  "onlyPriceChanges": false,
  "condition": "any",
  "onSale": false,
  "freeShipping": false,
  "onlyNew": false
}
```

# Actor output Schema

## `products` (type: `string`):

Every product: title, price and currency, earlier price, store, rating, reviews, delivery and change since the last run.

## `summaries` (type: `string`):

One free row per query: lowest, median and highest price, number of stores, top stores and a note on how it ended.

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

Counts per query, anything that failed, and cost.

# 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": [
        "wireless headphones"
    ],
    "country": "us",
    "maxProducts": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("locaihost/google-shopping").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": ["wireless headphones"],
    "country": "us",
    "maxProducts": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("locaihost/google-shopping").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 '{
  "queries": [
    "wireless headphones"
  ],
  "country": "us",
  "maxProducts": 20
}' |
apify call locaihost/google-shopping --silent --output-dataset

```

## MCP server setup

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

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/XfmR6DSeZ0SyORDHz/builds/bj7RYv9rqOW1samvs/openapi.json
