# Google Flights Scraper & Price Tracker (`wulfcare/google-flights-scraper`) Actor

Google Flights prices for any route and date, with price tracking built in: each run says which prices dropped or rose, which flights are new or gone, and the all-time low. Plus total trip cost with a hotel, cheapest dates, layovers, CO2 and Google's low/typical/high verdict. Built for AI agents.

- **URL**: https://apify.com/wulfcare/google-flights-scraper.md
- **Developed by:** [Wulfcare Data](https://apify.com/wulfcare) (community)
- **Categories:** Travel, AI, E-commerce
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$0.50 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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 Flights Scraper & Price Tracker

Get **Google Flights prices for any route and date**, with **price tracking built in** and the **total trip cost
(flight + hotel)**. Each run returns:

- every flight: airlines, flight numbers, times, layovers, aircraft, legroom, CO2 and price
- one **summary row** per route and date: the lowest price, Google's *low / typical / high* verdict, the typical
  price range and the daily price history
- with tracking on, **what changed since the last run**: price drops and rises, new flights, flights that are gone,
  and the all-time low

It works through Google Flights' own data endpoint, with no browser, so a search takes a few seconds. That makes it
quick enough to call from an AI agent.

### How this one is different

Most Google Flights scrapers give you a snapshot. To spot a price drop you have to save every run and compare them
yourself. This one does that for you.

| | This Actor | A typical Google Flights scraper |
|---|---|---|
| Flights, prices, layovers, CO2, Google's price insight | ✅ | ✅ |
| **Price tracking between runs** (drops, rises, new and gone flights) | ✅ built in | ❌ compare runs yourself |
| **All-time low** across runs (longer than Google's ~60-day history) | ✅ | ❌ |
| **Pay only for changes** (`onlyChanges`) for cheap daily monitoring | ✅ | ❌ |
| **Total trip cost: flight + cheapest good hotel** (3★+, rated 4+, from Google Hotels) | ✅ no extra charge | ❌ flights only |
| **Target price** flag for alerts (`belowTargetPrice`) | ✅ | ❌ |
| Layover warnings: long layover, overnight, change of airport | ✅ as true/false fields | partly, or as text |
| Cheapest price for every date in a range | ✅ | some |

### Use it from an AI agent (MCP)

Through the [Apify MCP server](https://mcp.apify.com), an agent can call this Actor as a tool. The defaults are kept
small so a call returns in seconds: one route, one date, 20 flights.

Typical agent questions and the input that answers them:

- *"How much is JFK to LAX on Dec 5, and is that a good price?"*
  `{"origin": "JFK", "destination": "LAX", "departureDate": "2026-12-05", "maxFlights": 5}`
  Read the summary row: `lowestPrice`, `priceLevel` (low / typical / high), `typicalPriceLow`–`typicalPriceHigh`.
- *"What will a week in Tokyo cost all in?"*
  `{"origin": "SYD", "destination": "HND,NRT", "departureDate": "2027-03-10", "tripDays": 7, "includeHotels": true, "maxFlights": 0}`
  Read `tripTotalPrice` (round-trip flight + 7 nights in the cheapest 3-star+ hotel rated 4+), plus `hotelName` and `hotelOptions`.
- *"Tell me when SFO to Honolulu drops."*
  `{"origin": "SFO", "destination": "HNL", "departureDate": "2027-01-15", "trackPrices": true, "onlyChanges": true, "targetPrice": 250}`
  Run it on a schedule. Read `lowestPriceChange`, `isLowestEver`, `belowTargetPrice` and the flights with `priceStatus` = `cheaper`.
- *"Which day in February is cheapest to fly LHR to JFK?"*
  `{"origin": "LHR", "destination": "JFK", "departureDate": "2027-02-01", "cheapestDates": true, "cheapestDatesRange": 28, "maxFlights": 0}`
  Read the rows with `type` = `date`; the cheapest has `isCheapest: true`.

Every row has a `type` (`summary`, `flight` or `date`), so an agent can read the summary first and the details only
when it needs them.

### Input

| Field | What it does |
|---|---|
| `origin`, `destination` | IATA airport codes. Separate several with commas to search them together (`JFK,LGA,EWR`). |
| `routes` | More routes, one per line: `SYD-LAX`, `JFK,EWR-LHR`, `MEL to AKL`. |
| `departureDate` | `2026-12-05`, or relative: `+30 days`, `in 2 weeks`, `tomorrow`. |
| `returnDate` / `tripDays` | Round trip. Leave both empty for one way. |
| `departureDays` | Search several departure dates in a row. |
| `maxFlights` | Flight rows per search (Google's best first, then by price). `0` = summary only. |
| `cabinClass`, `adults`, `children`, `maxStops`, `currency` | As on Google Flights. Prices are totals for all passengers. |
| `trackPrices`, `trackerName`, `onlyChanges`, `targetPrice` | Price tracking (see below). |
| `includeHotels`, `hotelNights`, `hotelMinRating`, `hotelMinStars` | Total trip cost. |
| `cheapestDates`, `cheapestDatesRange` | Cheapest price per departure date. |

### Price tracking

1. Turn on **Track prices between runs**. Optionally give the tracker a name.
2. Schedule the Actor (Apify Console → Schedules), e.g. daily, with the same input.
3. Each run compares against the last one and fills in:
   - on each flight: `priceStatus` (`first-seen`, `new`, `cheaper`, `pricier`, `same`, `gone`), `previousPrice`,
     `priceChange`, `lowestPriceSeen`, `lowestPriceSeenAt`, `firstSeenAt`
   - on the summary: `previousLowestPrice`, `lowestPriceChange`, `lowestPriceEver`, `lowestPriceEverAt`,
     `isLowestEver`, `trackedSince`, `trackedRuns`, `changes` (counts of new / cheaper / pricier / gone)
4. Turn on **Only output changes** and each run outputs just the summary and the flights that changed. You pay only
   for those rows.

Prices are stored in a named key-value store in your own Apify account, `google-flights-tracker-<name>`, so they
survive between runs. Delete that store to start over. Flights that disappear come out once as `gone` rows, at no
charge.

Pair this with an Apify webhook or integration (Slack, email, Make, Zapier) on `belowTargetPrice` or `isLowestEver` to
get price-drop alerts.

### Output

A **summary** row (one per route and date):

```json
{
  "type": "summary", "route": "JFK-LAX", "departureDate": "2026-12-05", "tripType": "one-way", "currency": "USD",
  "lowestPrice": 169, "priceLevel": "typical", "typicalPrice": 174, "typicalPriceLow": 75, "typicalPriceHigh": 320,
  "previousLowestPrice": 179, "lowestPriceChange": -10, "lowestPriceEver": 169, "isLowestEver": true,
  "targetPrice": 175, "belowTargetPrice": true, "changes": {"new": 0, "cheaper": 92, "pricier": 0, "gone": 1},
  "cheapestFlight": {"price": 169, "airlines": ["Delta"], "flightNumbers": ["DL 1788"], "stops": 0},
  "hotelName": "…", "hotelRating": 4.3, "hotelNights": 3, "hotelTotalPrice": 412.5, "tripTotalPrice": 581.5,
  "priceHistory": [{"date": "2026-08-27", "price": 173}, "…"],
  "googleFlightsUrl": "https://www.google.com/travel/flights?q=Flights+to+LAX+from+JFK+on+2026-12-05+one+way…"
}
```

A **flight** row:

```json
{
  "type": "flight", "route": "SYD-LAX", "rank": 1, "isBest": true, "price": 659, "currency": "USD",
  "priceStatus": "cheaper", "previousPrice": 689, "priceChange": -30, "lowestPriceSeen": 659,
  "airlines": ["Virgin Australia", "Delta"], "flightNumbers": ["VA 808", "DL 12"],
  "departureTime": "2026-12-10T07:00", "arrivalTime": "2026-12-10T05:55", "durationMinutes": 1075, "stops": 1,
  "layovers": [{"airport": "MEL", "city": "Melbourne", "durationMinutes": 95, "isLong": false,
                "isOvernight": false, "changesAirport": false}],
  "hasLongLayover": false, "hasOvernightLayover": false, "changesAirport": false,
  "emissionsKg": 756, "typicalEmissionsKg": 740, "emissionsVsTypicalPercent": 2,
  "legs": [{"flightNumber": "VA 808", "operatedBy": "Virgin Aust Intl for Virgin Aust", "aircraft": "Boeing 737MAX 8 Passenger",
            "legroom": "30 in", "departureAirport": "SYD", "arrivalAirport": "MEL", "durationMinutes": 95}, "…"],
  "tripTotalPrice": 1071.5
}
```

Times are local at each airport. Round-trip prices are for the whole trip, as Google Flights shows them; the flight
rows are the outbound options.

### Pricing

Pay per result: **$0.50 per 1,000 results**. A result is a summary, flight or date row. Errors and "gone" rows are
free, and so are the hotel lookups for trip cost. One search with the defaults (summary + 20 flights) costs about
$0.01. A tracked route checked daily with **Only output changes** costs about $0.10 a month.

### Notes and limits

- Prices are what Google Flights shows a logged-out visitor in the US, in the currency you pick.
- Booking-site prices for a single flight (the "booking options" page) and multi-city trips are not included yet.
- Google keeps fares for about 11 months ahead.
- The hotel in the trip cost is the cheapest real hotel room in the destination city (3+ stars and rated 4+ by
  default; hostels, dorm beds and apartments are skipped), for your number of adults, from Google Hotels. For every booking site's price for a hotel, see
  [Google Hotels Prices Scraper](https://apify.com/wulfcare/google-hotels-scraper).

### Other Actors by wulfcare

- [Google Hotels Prices Scraper](https://apify.com/wulfcare/google-hotels-scraper): every booking site's price for any hotel and dates
- [Google AI Mode Scraper](https://apify.com/wulfcare/google-ai-mode-scraper)
- [App Store Scraper](https://apify.com/wulfcare/app-store-scraper)

# Actor input Schema

## `origin` (type: `string`):

IATA code of the departure airport, e.g. JFK. Several, comma-separated, to search them together: JFK,LGA,EWR.

## `destination` (type: `string`):

IATA code of the arrival airport, e.g. LAX (or several: LAX,BUR,LGB).

## `departureDate` (type: `string`):

YYYY-MM-DD, or relative: "+30 days", "in 2 weeks", "tomorrow". Empty = in 30 days.

## `returnDate` (type: `string`):

Empty = one way. YYYY-MM-DD, or "+7 days" counted from the departure date. Round-trip prices are for the whole trip, as on Google Flights.

## `tripDays` (type: `integer`):

Instead of a return date: return this many days after departure. 0 = one way.

## `routes` (type: `array`):

Extra routes, one per line: "SYD-LAX", "JFK,EWR-LHR", "MEL to AKL". Each is searched for the same dates and options.

## `departureDays` (type: `integer`):

Search this many consecutive departure dates from the first (full flight lists for each). For just the cheapest price per date over a long range, use "Cheapest dates" instead.

## `maxFlights` (type: `integer`):

Flight rows per route and date: Google's "best" flights first, then the rest by price. Google lists 50-300. 0 = just the summary row (lowest price, verdict, trip cost).

## `cabinClass` (type: `string`):

Seat class.

## `adults` (type: `integer`):

Prices are the total for all passengers.

## `children` (type: `integer`):

Children aged 2-11 (count toward the total price).

## `maxStops` (type: `string`):

Most stops a flight may have.

## `currency` (type: `string`):

Three-letter code: USD, EUR, GBP, AUD, INR... Google prices directly in it.

## `trackPrices` (type: `boolean`):

Remember this run's prices and compare the next run with them: every flight gets priceStatus (new, cheaper, pricier, same), previousPrice, priceChange and its lowest price seen; flights no longer listed come out as "gone" (free); the summary gets the change in the lowest price and the all-time low. Schedule the Actor (e.g. daily) with the same input. Prices are kept in your named key-value store "google-flights-tracker-<tracker name>".

## `trackerName` (type: `string`):

Keep separate trackers apart (e.g. "client-a", "summer-trip"). Letters, digits, dashes.

## `onlyChanges` (type: `boolean`):

With tracking: output only flights that are new or changed price (plus one summary row per search). You pay only for those rows, so daily monitoring costs almost nothing.

## `targetPrice` (type: `integer`):

Optional: the summary's belowTargetPrice is true when the lowest price is at or under this (in the chosen currency). Handy for alerts and webhooks.

## `includeHotels` (type: `boolean`):

Look up the cheapest well-rated hotel (3+ stars, 4+ rating by default) in the destination city on Google Hotels for the stay (arrival to return date, or "Hotel nights" for one way), and add tripTotalPrice = flight + hotel to the summary and every flight. No extra charge.

## `hotelNights` (type: `integer`):

Stay length for one-way searches. Round trips stay until the return date.

## `hotelMinRating` (type: `string`):

Google rating (out of 5) a hotel needs to count.

## `hotelMinStars` (type: `integer`):

Hotel class a hotel needs to count (0 = any). Hostels, dorms and apartments never count, so the trip cost is for a real hotel room.

## `cheapestDates` (type: `boolean`):

Also output the cheapest price for every departure date in a range (Google's date grid), one row per date, the cheapest flagged. Round trips keep the same trip length.

## `cheapestDatesRange` (type: `integer`):

Departure dates from the departure date on.

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

Language of airport and airline names (hl=).

## `maxConcurrency` (type: `integer`):

Searches sent to Google at the same time.

## `residentialFallback` (type: `boolean`):

With the default Apify Proxy: when Google keeps refusing datacenter IPs, finish the run on US residential IPs (no extra charge to you).

## `proxyConfig` (type: `object`):

Apify Proxy (datacenter) works well; the Actor switches IPs on its own when Google slows one down.

## Actor input object example

```json
{
  "origin": "JFK",
  "destination": "LAX",
  "departureDate": "+30 days",
  "departureDays": 1,
  "maxFlights": 20,
  "cabinClass": "economy",
  "adults": 1,
  "children": 0,
  "maxStops": "any",
  "currency": "USD",
  "trackPrices": false,
  "trackerName": "default",
  "onlyChanges": false,
  "includeHotels": false,
  "hotelNights": 3,
  "hotelMinRating": "4",
  "hotelMinStars": 3,
  "cheapestDates": false,
  "cheapestDatesRange": 60,
  "language": "en",
  "maxConcurrency": 6,
  "residentialFallback": true,
  "proxyConfig": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

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

No description

## `flights` (type: `string`):

No description

## `dates` (type: `string`):

No description

## `all` (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 = {
    "origin": "JFK",
    "destination": "LAX",
    "departureDate": "+30 days",
    "proxyConfig": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("wulfcare/google-flights-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 = {
    "origin": "JFK",
    "destination": "LAX",
    "departureDate": "+30 days",
    "proxyConfig": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("wulfcare/google-flights-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 '{
  "origin": "JFK",
  "destination": "LAX",
  "departureDate": "+30 days",
  "proxyConfig": {
    "useApifyProxy": true
  }
}' |
apify call wulfcare/google-flights-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,wulfcare/google-flights-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/QrywFBkatxhZxIU4j/builds/16QHY7a665YZBYWY5/openapi.json
