# Google Flights MCP Server & API - Live Fares for AI Agents (`akhil_rajesh/google-flights-mcp-server`) Actor

Google Flights MCP server and live API for AI agents: search fares for any route and dates in seconds, with prices, airlines, stops, times, CO2, Google's price level and price history. Works with Claude, Cursor and any MCP client. Residential proxy included, no login.

- **URL**: https://apify.com/akhil_rajesh/google-flights-mcp-server.md
- **Developed by:** [Akhil rajesh](https://apify.com/akhil_rajesh) (community)
- **Categories:** MCP servers, Travel, AI
- **Features:** Limited permissions, Single-tenant, Server interface
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.70 / 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.
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 Flights MCP Server & API

**Google Flights MCP Server** gives your AI agent live **Google Flights fares on demand**. It is an **MCP server** and a **live HTTP API**: an agent asks for "the cheapest nonstop from Toronto to London on December 10" and gets the flights back in seconds, each with its **price, airlines, flight numbers, departure and arrival times, stops, layovers, duration and CO2**, plus the search's **cheapest fare, Google's price level (low, typical or high), its typical price range and about 60 days of price history**.

It runs the same code as [Google Flights Scraper & Price Tracker](https://apify.com/akhil_rajesh/google-flights-scraper), with Apify Standby switched on, so it answers each request at once instead of starting a run. For many routes and dates in one go, scheduled fare tracking, or price-drop alerts in Slack, Discord, Teams or Telegram, use that Actor.

### Connect your agent

Authenticate with your **Apify API token** (Apify Console → Settings → API & Integrations).

**MCP server** (Streamable HTTP): `https://akhil-rajesh--google-flights-mcp-server.apify.actor/mcp`

```json
{"mcpServers": {"google-flights": {"type": "http", "url": "https://akhil-rajesh--google-flights-mcp-server.apify.actor/mcp",
  "headers": {"Authorization": "Bearer <YOUR_APIFY_TOKEN>"}}}}
```

In Claude Code:

```bash
claude mcp add --transport http google-flights https://akhil-rajesh--google-flights-mcp-server.apify.actor/mcp --header "Authorization: Bearer <YOUR_APIFY_TOKEN>"
```

A client that can't send headers can use `https://akhil-rajesh--google-flights-mcp-server.apify.actor/mcp?token=<YOUR_APIFY_TOKEN>`. Keep that URL private, as it carries your token.

Through **Apify's MCP server** (`https://mcp.apify.com`, for Claude, ChatGPT, Cursor and other clients), add the tools with `https://mcp.apify.com?tools=akhil_rajesh/google-flights-mcp-server`. They appear as `akhil_rajesh--google-flights-mcp-server--search_flights` and so on. Add them that way rather than through Apify's generic `call-actor` tool, which returns the rows only as text.

Then ask in plain words:

- *"What's the cheapest flight from New York to London on December 10, and is that a good price?"*
- *"Nonstop flights from Toronto to Paris next Friday, under $700, leaving after 6 pm."*
- *"Which of December 10, 12 or 14 is cheapest to fly JFK to LAX?"*
- *"What airports does Google Flights mean by 'Tokyo'?"*

### Tools

| Tool | What it returns |
|---|---|
| `search_flights` | A route on up to 3 departure dates, one way or round trip (a return date or a trip length): every flight Google lists, cheapest first unless you sort otherwise, with the search's cheapest fare, price level, typical range and price history. Filters: adults and children, cabin (economy, business, first), stops (any, nonstop, 1 or 2 stops or fewer), airlines to keep or leave out, a maximum price and duration, and departure times. Currency and country of your choice |
| `find_airport` | What a city, airport or country means to Google Flights: its airports and codes, and the place a search reads. Free |
| `run_actor` | The whole input of [Google Flights Scraper & Price Tracker](https://apify.com/akhil_rajesh/google-flights-scraper) in one call, for reads the other tools can't express |

Places can be typed as people say them: "Toronto", "London", "JFK", "New York". A place Google Flights doesn't know is named in `notFound`, with Google's suggestions, and not charged. In testing, a search came back in 3 to 7 seconds after the first request, which starts the Standby run.

### HTTP API

The same reads as plain HTTP requests, with the same token (header `Authorization: Bearer <token>`):

```bash
curl "https://akhil-rajesh--google-flights-mcp-server.apify.actor/flights?from=YYZ&to=London&dates=2026-12-10&stops=nonstop&perSearch=5" \
  -H "Authorization: Bearer <YOUR_APIFY_TOKEN>"
```

| Endpoint | Parameters |
|---|---|
| `GET /flights` | `from`, `to`, `dates` (dates separated by `\|`, or a range "2026-12-10 to 2026-12-14", or "in 30 days"), `return`, `tripDays`, `adults`, `children`, `cabin`, `stops`, `airlines`, `exclude`, `maxPrice`, `maxDuration`, `departsAfter`, `departsBefore`, `perSearch`, `sort`, `currency`, `country`, `language`, `max` |
| `GET /airports` | `q`, `country`, `language` (free) |
| `POST /run` | The Google Flights Scraper & Price Tracker input as the JSON body |

`GET /` lists every parameter, and the Actor's **Endpoints** tab in Apify Console lets you try them.

### What each answer holds

A **search** row per route and date: `route`, `departureDate`, `returnDate`, `flightsFound`, `cheapestPrice`, `cheapestFlight`, `cheapestNonstopPrice`, `shortestDurationMinutes`, `priceLevel`, `typicalPriceLow`, `typicalPriceHigh`, `priceHistory`, `airlinesOffered` and `googleFlightsUrl`.

A **flight** row per itinerary: `rank`, `price`, `pricePerAdult`, `airlines`, `flightNumbers`, `from`, `to`, `departs`, `arrives`, `durationMinutes`, `stops`, `layovers`, `legs` (each flight with its aircraft and legroom), `emissionsGrams` and `isBest`.

Every answer also has `notFound`, `notLoaded` (what Google didn't answer, with the reason), `notRead` (what a limit left out: not charged) and `notes`.

### Limits

| | Searches | Rows | Time |
|---|---|---|---|
| **MCP tool call** | 3 | 100 | 50 seconds |
| **HTTP request** | 10 | 2,000 | 170 seconds |

A search is one route on one departure date. The MCP limits keep answers inside what MCP clients wait for (60 seconds) and what Apify's MCP server passes on (about 1 MB). **A request that has started runs to its end even if you stop waiting**: Apify's Standby proxy keeps it open, so its rows are read and charged. Ask for what you need.

Paused since November 16, 2026, while Google Flights asks its data call for a browser check that this Actor doesn't pass: the **price calendar**, **infants**, **premium economy**, **alliances**, **several airports on one side** and **countries** as a destination. A request for infants, premium economy or an alliance is refused at once (HTTP 400), at no cost. "1 or 2 stops or fewer" and airline codes still work: they're applied to the flights after the search.

### How much does it cost?

Pay-per-event, the same prices as Google Flights Scraper & Price Tracker:

| Your plan | Per 1,000 searches | Per 1,000 results |
|---|---|---|
| Free | $6.00 | $1.00 |
| Starter | $6.00 | $0.90 |
| Scale | $6.00 | $0.80 |
| Business and above | $6.00 | $0.70 |

A search is charged once when its Google Flights page is read; a result is a flight row or a search row with flights. A search for 5 flights costs about $0.012. The residential proxy is included. On top come the start fee when a Standby run starts, and the run's **platform usage** while it serves you and until it has been idle for 2 minutes, at Apify's usual rates. That's why the Store page's pricing box mentions platform usage. Places not found cost nothing.

### Agents that pay per call

Apify's MCP server doesn't offer Actors with a live endpoint to agents that pay per call with **x402** or **Skyfire**. Those agents can use [Google Flights Scraper & Price Tracker](https://apify.com/akhil_rajesh/google-flights-scraper) through `https://mcp.apify.com` instead: it takes the same input and returns the same rows, as a normal run that starts for each call instead of a live answer. An agent with an Apify account or API token can use either.

### FAQ

#### Is there an official Google Flights API or MCP server?

No: Google has no public Google Flights API, and its QPX Express airfare API closed in 2018. This Actor reads the fares a visitor sees on Google Flights and serves them as an MCP server and an HTTP API.

#### Can it alert me when a fare drops?

Not over the live endpoint, which answers each request on its own and ignores tracking fields. A normal run of this Actor does it, with the same input as Google Flights Scraper & Price Tracker: schedule it with Only changes and a Slack, Discord, Teams or Telegram destination, or schedule the scraper. Each Actor keeps its own fare history (this one's is `google-flights-mcp-history` by default), because Apify lets an Actor open only the history stores it created itself.

#### Why did a search come back as not loaded?

Google didn't answer it (its "unusual traffic" page, or an error in place of the data). The reason is in `notLoaded`, and nothing is charged for it. Ask again a little later.

#### Are the prices the same as on Google Flights?

They are Google Flights' prices for the market, currency and passengers asked for, as a visitor sees them; fares can change between a request and a booking. Each search row links its Google Flights page.

### Other Actors by this developer

- [Google Flights Scraper & Price Tracker API - Fare Alerts](https://apify.com/akhil_rajesh/google-flights-scraper): the same Google Flights data as scheduled runs: many routes and dates, fare tracking, price-drop alerts in Slack, Discord, Teams or Telegram
- [Google Hotels Scraper - Hotel Price Tracker & Comparison](https://apify.com/akhil_rajesh/google-hotels-scraper): hotel prices from Google Hotels, with price tracking
- [Google Trends Scraper & API - Trending Now, Pinterest Trends](https://apify.com/akhil_rajesh/google-trends-scraper): Trending Now in 125 countries, interest over time and rising searches, with an MCP server for AI agents
- [Yahoo Finance Scraper, API & MCP](https://apify.com/akhil_rajesh/yahoo-finance-scraper): quotes, price history, financials and options chains, with an MCP server for AI agents

### Disclaimer

This Actor is an independent tool. It is **not affiliated with, endorsed by or sponsored by** Google. It reads publicly available fares at a modest pace, through one residential address per run, and leaves out the pages Google's robots rules close. Use the data in line with Google's terms and the laws that apply to you.

# Changelog

This Actor's version history is a separate document: https://apify.com/akhil_rajesh/google-flights-mcp-server/changelog.md

# Actor input Schema

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

One route per line: 'New York to London' or 'YYZ to LHR'. Cities (all their airports) and airports (IATA codes) work, as in Google Flights' own search box. Countries ('Toronto to Japan') and several places on one side ('YYZ/YTZ to LHR') are paused since 2026-11-16: Google Flights asks its data call for a browser check, which this Actor doesn't pass. At most 50 routes.

## `departureDates` (type: `array`):

One per line: a date (2026-12-10), a range of up to 31 days (2026-12-10 to 2026-12-14), or a date counted from the run's day ('in 30 days', '2 weeks', '3 months'). Every route is searched on every date (at most 100 searches a run). Google Flights lists flights from today to about 11 months ahead. Leave empty for flights in 30 days. For Only changes, use fixed dates: 'in 30 days' is a new date each day.

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

For a round trip with one departure date: the return date (2026-12-20, or 'in 37 days'). Leave empty for one way. With several departure dates, use Trip length instead.

## `tripLengthDays` (type: `integer`):

For round trips: return this many days after each departure date (7 for a week). Leave empty for one way.

## `googleFlightsUrls` (type: `array`):

Optional: Google Flights search links with a 'q=' search, such as the googleFlightsUrl of this Actor's rows (https://www.google.com/travel/flights?q=Flights+to+LHR+from+YYZ+on+2026-12-10). Their dates, currency and country are used for that route.

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

Adults (default 1). Prices are for all passengers together, as Google Flights shows them; rows with several adults also give the price per adult.

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

Children aged 2 to 11.

## `infantsInSeat` (type: `integer`):

Paused since 2026-11-16: Google Flights asks its data call for a browser check, which this Actor doesn't pass; a run with infants is refused before any search, at no cost. Infants under 2 in their own seat.

## `infantsOnLap` (type: `integer`):

Paused since 2026-11-16: Google Flights asks its data call for a browser check, which this Actor doesn't pass; a run with infants is refused before any search, at no cost. Infants under 2 on a lap (one per adult). At most 9 passengers in all.

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

Economy (default), business or first. Premium economy is paused since 2026-11-16 (Google Flights asks its data call for a browser check): a run that asks for it is refused before any search, at no cost.

## `stops` (type: `string`):

Default: any. Nonstop is sent with the search. Since 2026-11-16 '1 stop or fewer' and '2 stops or fewer' are applied to the flights after the search, since Google Flights asks its own filter's data call for a browser check; the status says so.

## `airlines` (type: `array`):

Only these airlines: codes (AC, BA, DL) or names (Air Canada), matched against each flight's airlines. Since 2026-11-16 codes are applied after the search (Google Flights asks its own Airlines filter's data call for a browser check), and alliances (Star Alliance, oneworld, SkyTeam) are paused: name their airlines instead. Leave empty for all.

## `excludeAirlines` (type: `array`):

Flights flown by these airlines (codes or names) are left out.

## `maxPrice` (type: `number`):

Leave out flights above this price, in the run's currency. A search's cheapest fare is the cheapest flight that passes every filter.

## `maxDurationMinutes` (type: `integer`):

Leave out flights longer than this, layovers included (600 for 10 hours).

## `maxLayoverMinutes` (type: `integer`):

Leave out flights with a longer layover.

## `departureTimeFrom` (type: `string`):

Local time at the departure airport, 06:00. With Departs before, a window; a window from 22:00 to 05:00 crosses midnight.

## `departureTimeTo` (type: `string`):

Local time, 12:00 (a plain hour, 12, includes 12:59).

## `arrivalTimeFrom` (type: `string`):

Local time at the arrival airport.

## `arrivalTimeTo` (type: `string`):

Local time at the arrival airport.

## `maxFlightsPerSearch` (type: `integer`):

Flight rows each search returns, in the Sort by order (default 20, up to 300: Google lists up to about 300). 0 returns only each search's summary row, with its cheapest fare and price insight.

## `sortBy` (type: `string`):

The order of each search's flight rows (default: price).

## `maxResults` (type: `integer`):

Charged rows a run returns in all (default 1,000), shared evenly across the searches. Free rows (not found, no flights) don't count.

## `priceCalendarDays` (type: `integer`):

Paused since 2026-11-16: Google Flights asks its data call for a browser check, which this Actor doesn't pass. A run that asks for it says so and searches the departure dates. The cheapest fare for each departure day, for this many days from each route's first departure date (one calendar row per route; round trips keep the trip length). 0 or empty: no calendar.

## `calendarOnly` (type: `boolean`):

Paused since 2026-11-16: Google Flights asks its data call for a browser check, which this Actor doesn't pass. A run that asks for it says so and searches the departure dates. Only the price calendar, no searches (60 days unless Price calendar says otherwise).

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

Return only what changed since the last run of the same search: the cheapest fare dropping or rising by at least the minimum change, a fare at or under your target, and flights whose own price moved. The first run returns everything (firstRun) and saves it as the baseline. Use it with a schedule. Alerts switch it on.

## `changeTypes` (type: `array`):

Which changes Only changes returns and alerts post. Default: price drops and fares under your target.

## `minPriceChangePercent` (type: `number`):

A smaller move isn't reported, and the last reported price stays the baseline, so a slow slide is reported once it adds up (default 1).

## `targetPrice` (type: `number`):

With Only changes: report a search (and alert) when its cheapest fare reaches this price or less, in the run's currency, for all passengers. Reported once until the fare goes back above it.

## `alertWebhookUrl` (type: `string`):

Post the changes to a Slack, Discord or Microsoft Teams channel (its incoming webhook URL), or any HTTPS endpoint that takes JSON (Zapier, Make, n8n). The first run posts one 'alerts are set up' message; fare changes follow from the next run.

## `telegramBotToken` (type: `string`):

Post the changes to Telegram through your own bot: its token from @BotFather (123456789:AAH...).

## `telegramChatId` (type: `string`):

The chat the bot posts to: a chat id (-1001234567890) or a public channel (@mychannel, with the bot as an admin).

## `historyName` (type: `string`):

The named key-value store that keeps the fares Only changes compares with (default google-flights-history). Each search keeps its own record in it, so schedules can share one.

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

The currency of every price: USD (default), EUR, GBP, CAD, INR...

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

The country Google Flights is shown for (two letters: US by default, GB, CA, IN). Fares can differ by country.

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

The language of place and airline names (en by default, de, fr, pt-BR).

## `proxy` (type: `object`):

Leave it off: the Actor reads Google Flights through its own residential proxy, included in the price. Your own proxy URLs are used instead if you give them; an Apify Proxy setting isn't used.

## Actor input object example

```json
{
  "routes": [
    "New York to London"
  ],
  "departureDates": [
    "in 30 days"
  ],
  "changeTypes": [
    "priceDrop",
    "belowTarget"
  ],
  "minPriceChangePercent": 1,
  "proxy": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `overview` (type: `string`):

No description

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

No description

## `calendar` (type: `string`):

No description

## `changes` (type: `string`):

No description

## `notFound` (type: `string`):

No description

## `allData` (type: `string`):

No description

## `runSummary` (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 = {
    "routes": [
        "New York to London"
    ],
    "departureDates": [
        "in 30 days"
    ],
    "proxy": {
        "useApifyProxy": false
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("akhil_rajesh/google-flights-mcp-server").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 = {
    "routes": ["New York to London"],
    "departureDates": ["in 30 days"],
    "proxy": { "useApifyProxy": False },
}

# Run the Actor and wait for it to finish
run = client.actor("akhil_rajesh/google-flights-mcp-server").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 '{
  "routes": [
    "New York to London"
  ],
  "departureDates": [
    "in 30 days"
  ],
  "proxy": {
    "useApifyProxy": false
  }
}' |
apify call akhil_rajesh/google-flights-mcp-server --silent --output-dataset

```

## MCP server setup

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

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/wRIbbd9rxAzeVvcgD/builds/MCLGZ6z7UE2SssNa8/openapi.json
