Google Flights MCP
This MCP server provides Google Flights search and airport lookup capabilities for travel planning.
Search one-way or round-trip flights by origin, destination, and date, with passengers, cabin, max stops, sorting, currency, and max results; results include booking links.
Find the cheapest departure date within a date range, optionally for a fixed round-trip length, scanning up to 14 days.
Compare cheapest fares across multiple origin/destination airport combinations, up to 6 routes.
Look up IATA airport codes offline by city, airport name, or code.
Searches Google Flights for one-way and round-trip itineraries, returning prices, stops, durations and a Google Flights deep link for booking. Also finds the cheapest travel dates within a range, compares fares across multiple origin/destination airports, and looks up airports by city or name.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Google Flights MCP Find me the cheapest flights from Milan to London next month, nonstop only."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Google Flights MCP
An MCP server that lets Claude, ChatGPT and any other MCP client search Google Flights: prices, stops, durations, cheapest day in a range, nearby-airport comparison and a deep link to book.
Not affiliated with or endorsed by Google. See Legal before using it.
Tools
Tool | What it does |
| One-way or round-trip search for a date: passengers, cabin, max stops, sorting |
| Cheapest day in a date range (optionally for a fixed trip length) |
| Cheapest fare across several origin/destination airports (e.g. MXP/LIN/BGY → LHR/LGW) |
| Offline lookup of IATA codes from a city or airport name |
| Tells the assistant whether a newer version is on GitHub (called once per conversation) |
Every search result includes a google_flights_url so you can verify and book.
Related MCP server: Google Flights MCP Server
Install
You only need uv (it fetches Python and the dependencies for you). Nothing to clone or build.
Do this once first (warm-up). The very first run downloads and builds everything (about a minute), which is longer than the start-up timeout of most clients, so the first launch from Claude would appear to fail. Pre-download it in a terminal, then register it:
uvx --from git+https://github.com/marcopa84/GoogleFlightsMCP google-flights-mcp --versionAfter that, starting takes ~2 seconds.
Let Claude install it for you
Paste this into Claude Code (or Claude Desktop with file access) and it will do the setup, asking before it touches any config:
Install this MCP server for me and check it works: https://github.com/marcopa84/GoogleFlightsMCP
Follow INSTALL_FOR_AI.md in that repo.If you cloned the repo and open Claude Code in it, you also get three slash commands:
/install (set up), /doctor (diagnose problems), /flights <request> (search in plain language).
Or do it by hand:
Claude Code
claude mcp add google-flights -- uvx --from git+https://github.com/marcopa84/GoogleFlightsMCP google-flights-mcpClaude Desktop
Settings → Developer → Edit Config, then add:
{
"mcpServers": {
"google-flights": {
"command": "/usr/local/bin/uvx",
"args": ["--from", "git+https://github.com/marcopa84/GoogleFlightsMCP", "google-flights-mcp"]
}
}
}Replace /usr/local/bin/uvx with the output of which uvx (Claude Desktop does not see your shell PATH).
Keep any other keys already in the file.
Then quit Claude Desktop completely (⌘Q on macOS, tray icon → Quit on Windows; closing the window is not
enough), reopen it, start a new chat and ask: "Find me the cheapest flights from Milan to London next month,
nonstop only." If the tools do not appear, check ~/Library/Logs/Claude/mcp-server-google-flights.log.
ChatGPT (and other remote clients)
ChatGPT connects to servers on the public internet, so run the HTTP transport and expose it with a tunnel. You need a ChatGPT plan with custom connectors / Developer Mode (check OpenAI's current docs for eligibility).
# terminal 1
uvx --from git+https://github.com/marcopa84/GoogleFlightsMCP google-flights-mcp --transport http --port 8000 --allow-any-host
# terminal 2 (any tunnel works; this one needs no account)
cloudflared tunnel --url http://localhost:8000In ChatGPT: Settings → Connectors → Advanced → Developer mode → add a connector with
https://<your-tunnel>.trycloudflare.com/mcp, authentication none.
⚠️ This server has no authentication. Anyone who learns your tunnel URL can make your machine search
Google Flights. Stop the tunnel when you are done, and do not leave it running unattended.
Prefer --public-host <your-tunnel-hostname> over --allow-any-host if the hostname is stable.
From a clone
git clone https://github.com/marcopa84/GoogleFlightsMCP && cd GoogleFlightsMCP
uv sync
uv run google-flights-mcp # stdio
uv run pytest # tests (offline)
uv run pytest -m live # real Google Flights checkConfiguration (environment variables, all optional)
Variable | Default | Meaning |
|
|
|
| – | Enables the SerpAPI |
|
| Seconds identical searches are cached |
|
| Minimum seconds between upstream requests |
|
| Max days a single |
| – | HTTP(S) proxy for the Google backend |
| built-in | See below |
|
|
|
In Claude Desktop pass them with an "env": { ... } block next to command/args.
Cookie consent (EU)
From the EU, Google answers automated requests with a cookie-consent page instead of results. The Google
backend therefore sends the same SOCS cookie a browser stores after clicking Accept all. That is a
choice made on your behalf: set GFLIGHTS_CONSENT_COOKIE to your own value (copy the SOCS cookie from
your browser) or to an empty string to send nothing (searches from the EU will then fail).
Updates
Installed with uvx --from git+..., the server picks up the latest commit every time it starts. So to
update, just quit the client completely and reopen it (Claude Desktop: ⌘Q / tray → Quit). While the app stays
open the old version keeps running; the assistant calls check_for_updates once per conversation and tells you
when a restart would bring in a newer version.
How it works
MCP client ──► tools (server.py) ──► FlightService (cache, rate limit, validation, fallback)
├─ GoogleFlightsBackend (fast-flights: Google's public web page)
└─ SerpApiBackend (official paid API, optional)There is no official Google Flights API. The default backend reads the public page like a browser and can
break when Google changes it; the weekly CI job runs a live canary so you find out quickly. If it breaks,
update first (uvx --refresh ...) and open an issue.
Legal and fair use
This is not legal advice. Points to be aware of:
Google's Terms of Service restrict automated access. Scraping can violate them even for public pages.
In the EU, a site operator may contractually forbid scraping of databases that are not otherwise protected (CJEU, Ryanair v PR Aviation).
The project is meant for personal, low-volume use: it caches, rate-limits and caps range scans. Do not host it as a public service, resell the data, or raise the limits to bulk-harvest prices.
For anything commercial use the
serpapibackend or a licensed flight-data provider.Prices are indicative; always confirm on the booking site.
Contributing
INSTALL_FOR_AI.md is written for AI assistants; keep it in sync when install steps change.
PRs welcome — especially new backends (implement Backend.search in src/google_flights_mcp/backends/).
License
MIT
Available Tools
4 toolscompare_airportsBRead-only
Compare the cheapest fare across several origin/destination airport combinations (max 6).
Inputs: origins (required), destinations (required), departure_date (required), cabin, +4 more. Returns: routes, currency, return_date, departure_date
find_airportBRead-only
Look up IATA airport codes by city or airport name (offline).
Inputs: query (required), limit. Returns: result
find_cheapest_datesARead-only
Find the cheapest day to fly within a date range (one search per day, max 14 days).
Inputs: origin (required), end_date (required), start_date (required), destination (required), +5 more. Returns: best, note, dates, origin, +3 more
search_flightsBRead-only
Search flights between two airports on a given date (one-way or round-trip).
sort_by: 'price' (default), 'duration' or 'departure'.
Inputs: origin (required), destination (required), departure_date (required), cabin, +8 more. Returns: note, count, origin, backend, +6 more
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 4 tools
The four tools are mostly distinct by scope: find_cheapest_dates scans a date range, compare_airports tests multiple airport pairs, search_flights handles a single date, and find_airport is an offline code lookup. The only mild overlap is that find_cheapest_dates and search_flights both return fares, though their descriptions clearly separate date-range scanning from single-date search.
All names follow a consistent verb_noun snake_case pattern (find_cheapest_dates, compare_airports, search_flights, find_airport). Verbs accurately reflect each action and no convention mixing is present.
Four tools is well within the sensible 3-15 range and each tool earns its place by covering a distinct query style. Nothing feels redundant or bloated for a flight-search server.
The surface covers single-date search, flexible-date scanning, multi-airport comparison, and code lookup, forming a coherent search workflow. Minor gaps exist for auxiliary parameters like passenger counts, cabin class, or nonstop-only filters, but agents can work around them.
Maintenance
Related MCP Connectors
Flight search MCP server providing search, pagination, and itinerary details for AI assistants.
Flight Intelligence MCP — search, cheapest dates, multi-city, airline compare via Google Flights
Real-time Google Flights fares for agents. Three things people do with this server. Scan for deals: one call takes a date range and a list of destination airports, expands every combination server side, and returns each fare with Google's own low, typical or high verdict. Put live search in your app: flat JSON with a bookable link on every result, and round trips priced as paired legs. Run a 24/7 AI travel agent: add the server, sign in with Google, and schedule it. No ads, no sponsored content. You bring your own RapidAPI key, so every search is billed to your plan and never to anyone else's. Add https://flights.flightpowers.com/mcp , click Sign in, sign in with Google, and paste your RapidAPI key once on the page that opens. Scripts and clients without a sign-in button send the key as x-rapidapi-key on the same URL.
Geo-based flight search MCP server. Find more flights between any two places on earth
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceProvides live flight prices, booking links, and airport lookup via a hosted MCP server. Enables search for flights and direct booking URL retrieval.2MIT
- AlicenseAqualityBmaintenanceEnables MCP clients to search one-way, round-trip, and multi-city itineraries and retrieve fares, flight legs, carbon emissions and price history as structured JSON.183 npm5MIT
- AlicenseAqualityAmaintenanceEnables real-time flight fare searches across date ranges and multiple destinations, with historical price insights and booking links. Provides one-way and round-trip search tools through MCP.41MIT
- AlicenseNot gradedqualityBmaintenanceEnables real-time one-way and round-trip flight searches from any MCP client without an API key or account, returning live fares, historical price insights, and bookable links supported by disclosed sponsored cards.2MIT