Flights API

Google Flights Scraper API for Live Airfares, Route Data, and Booking Options

Search Google Flights, retrieve structured itinerary details and price insights, and compare provider booking options through two purpose-built API endpoints.

1,000 free credits
No credit card required

Use the same API key and credit balance across every ScrapeBadger API.

GET /v1/google/flights/search
{
  "best_flights": [
    {
      "legs": [
        {
          "departure_airport": "JFK",
          "arrival_airport": "LHR",
          "airline": "Example Airline",
          "flight_number": "EX101"
        }
      ],
      "total_duration_minutes": 425,
      "price": 782,
      "currency": "USD"
    }
  ]
}
Endpoints

Explore Both Google Flights API Endpoints

Move from flight discovery to itinerary comparison and provider booking options with structured JSON responses.

GET/v1/google/flights/search7 credits

Flights Search

Parameters
departure_idrequiredDeparture IATA code, such as JFK, or another supported airport ID.
arrival_idrequiredArrival IATA code, such as LHR, or another supported airport ID.
outbound_daterequiredOutbound date in YYYY-MM-DD format.
Request
curl --get \
  'https://scrapebadger.com/v1/google/flights/search' \
  --data-urlencode 'departure_id=JFK' \
  --data-urlencode 'arrival_id=LHR' \
  --data-urlencode 'outbound_date=2026-10-12' \
  --data-urlencode 'trip_type=one_way' \
  --data-urlencode 'adults=1' \
  --data-urlencode 'travel_class=economy' \
  --data-urlencode 'currency=USD' \
  --data-urlencode 'gl=us' \
  --data-urlencode 'hl=en' \
  --data-urlencode 'stops=any' \
  --data-urlencode 'sort_by=price' \
  --header 'x-api-key: YOUR_API_KEY'
Response200 OK
{
  "departure_id": "JFK",
  "arrival_id": "LHR",
  "outbound_date": "2026-10-12",
  "best_flights": [
    {
      "legs": [
        {
          "departure_airport": "JFK",
          "departure_airport_name": "John F. Kennedy International Airport",
          "departure_time": "2026-10-12 18:30",
          "arrival_airport": "LHR",
          "arrival_airport_name": "Heathrow Airport",
          "arrival_time": "2026-10-13 06:35",
          "duration_minutes": 425,
          "airline": "Example Airline",
          "airline_logo": "https://images.example.com/airline.png",
          "flight_number": "EX101",
          "aircraft": "Example aircraft",
          "travel_class": "Economy",
          "legroom": "31 in",
          "extensions": ["In-seat power"]
        }
      ],
      "layovers": [],
      "total_duration_minutes": 425,
      "price": 782,
      "currency": "USD",
      "booking_token": "example-booking-token",
      "booking_url": "https://www.google.com/travel/flights/example",
      "selection_token": "example-selection-token",
      "departure_token": null,
      "carbon_emissions_grams": 412000,
      "carbon_emissions_diff_typical": -8,
      "airline_logo": "https://images.example.com/airline.png",
      "extensions": ["Nonstop"]
    }
  ],
  "other_flights": [],
  "price_insights": {
    "lowest_price": 720,
    "typical_price_range": [720, 920],
    "price_history": [[1726000000, 790]]
  },
  "airports": [
    {
      "iata_code": "JFK",
      "name": "John F. Kennedy International Airport",
      "city": "New York",
      "country": "United States"
    },
    {
      "iata_code": "LHR",
      "name": "Heathrow Airport",
      "city": "London",
      "country": "United Kingdom"
    }
  ],
  "return_date": null,
  "currency": "USD",
  "trip_type": "one_way",
  "search_url": "https://www.google.com/travel/flights/example"
}
View Flights Search documentation

What Can You Build With the Google Flights Scraper API?

Flight discovery and itinerary comparison

Search routes, travel dates, passenger configurations, cabin classes, and stop preferences across country and language contexts. Capture structured airlines, flight numbers, airport details, departure and arrival times, durations, layovers, prices, emissions, and price insights for downstream travel analysis.

Flights Search

Airfare tracking and deal alerts

Use Flights Search results to identify comparable itineraries, then repeat consistent route and date searches to monitor displayed fare changes. Track total-party prices, typical price ranges, price history, airlines, travel duration, and stop patterns without treating an older result as a currently bookable fare.

Flights Search

Corporate travel and route intelligence

Measure the available flight schedules and market prices for commonly travelled routes. Compare nonstop and connecting options, cabin classes, total journey duration, layovers, emissions, and displayed fares across consistent passenger, country, language, and currency settings.

Flights Search

Booking-provider and fare comparison

Turn a selected Google Flights itinerary into a list of available airlines and online travel agencies for travel tools, booking-assistance products, research dashboards, or itinerary QA. Preserve the original route, dates, passenger configuration, selection token, currency, and booking URL so downstream systems can retain the search context.

Flights SearchFlights Booking Options
Sign Up For Free

1,000 free credits · No credit card required

More Google Data APIs

Use the same ScrapeBadger account, API key, and credit balance to connect flight itineraries with accommodation data, destination information, demand signals, and broader travel research.

Why Choose ScrapeBadger?

Build Faster

Structured JSON responses remove browser automation, proxy orchestration, and HTML parsing from your roadmap. Make your first request in minutes and move from proof of concept to production without maintaining scrapers.

Scale Confidently

99.9% uptime SLA. Your data pipeline does not stop because Google changes a page, rotates an anti-bot challenge, or moves a result block. Monitoring, session management, browser infrastructure, and parsing are all us.

All Google Data on One Platform

Search, Maps, News, Hotels, Trends, Jobs, Shopping, Patents, Scholar, Images, Videos, Finance, AI Mode, Lens, Local, Shorts, Flights, Products, and Autocomplete — every Google surface under one API key.

Integrate Anywhere

RESTful API, SDK support, MCP, CLI, and no-code options. Use ScrapeBadger in an existing system or a new application with consistent authentication, structured JSON, and unified billing.

Integrate With Your Stack

Use ScrapeBadger through an official SDK, a standard API request, MCP, CLI, or the tools already in your workflow.

Python SDK

Build asynchronous data pipelines with typed responses, retry handling, and access to the complete Google API suite.

Node.js SDK

Add Google data to Node.js and TypeScript applications with type definitions and support for both ESM and CommonJS.

REST API

Connect from any backend or programming language using standard HTTP requests. Responses arrive as structured JSON that can be stored, transformed, or passed into another service.

One API Key

Access Search, Maps, News, Trends, Shopping, Scholar, Flights, and every other supported Google product with one ScrapeBadger API key and one credit balance.

MCP for AI Tools

Give compatible AI agents access to Google Search, Maps, News, Trends, Shopping, Scholar, Images, Flights, and more through ScrapeBadger's MCP server.

ScrapeBadger CLI

Run Google searches, inspect trends, collect local business data, and export results as JSON, CSV, Markdown, or terminal-friendly tables without building an application.

Trusted by Developers Worldwide

See why developers choose ScrapeBadger for reliable, structured web data.

We switched from the official Twitter API and cut our costs by 95%. The pagination is seamless, and we've never hit a rate limit. Best decision we made this year.

MC
Marcus Chen
Lead Data Engineer at DataFlow Analytics
2 weeks ago

The follower and engagement endpoints are incredibly detailed. We use it for influencer research and competitor analysis. Response times are sub-100ms consistently.

SM
Sarah Mitchell
Marketing Director at SocialPulse Agency
1 month ago

Started with the Apify actor, then moved to the API for more control. The 1,000 free credits were enough to build our MVP. Now processing 2M+ tweets monthly.

JR
James Rodriguez
Founder at TweetMetrics
3 weeks ago

Perfect for academic research. The community and trends endpoints give us data we couldn't get anywhere else. Documentation could use more examples, but support is responsive.

EW
Emily Watson
Research Scientist at Stanford NLP Lab
1 month ago

We monitor 50,000+ accounts for our clients. ScrapeBadger handles it without breaking a sweat. The bulk ID endpoints are a game-changer for large-scale monitoring.

AP
Alex Petrov
CTO at MediaMonitor Pro
2 weeks ago

The geo and trends endpoints power our location-based analytics. Setup took 10 minutes. Their Apify actors are also great for quick one-off scrapes.

LP
Lisa Park
Product Manager at Trendy AI
3 weeks ago
Pricing

Simple, transparent pricing

Start with pay-as-you-go credits (never expire) or save up to 64% with a monthly or annual subscription. Failed requests never consume credits, and every Google API endpoint is included on every plan.

Not Sure Which Plan Fits Your Needs? Calculate Your Cost and Find the Right Plan.

Choose an endpoint and enter your expected request volume. Google APIs use flat per-request credits, making usage easy to forecast. Failed requests cost 0 credits.

FAQ

Frequently asked questions

Everything you need to know about the Flights API.

What data can I retrieve with the Google Flights Scraper API?

Flights Search returns recommended and other available flight itineraries, airport information, price insights, and the original search context. A flight offer can include flight legs, departure and arrival airports and times, airline, flight number, aircraft, travel class, legroom, journey duration, layovers, total-party price, currency, booking and selection tokens, booking URL, carbon emissions, and additional flight information. Flights Booking Options returns the available booking providers and their displayed prices for a selected itinerary.

How do I move from a Flights Search result to airline and travel-agency booking options?

Call GET /v1/google/flights/search with the departure airport, arrival airport, outbound date, and other relevant search parameters. For a one-way itinerary, retain the returned selection_token and pass it to GET /v1/google/flights/booking_options . For a round trip, use the outbound offer's departure_token to retrieve return-flight options first, then pass the fully selected itinerary's selection_token to Booking Options.

Which passenger, travel-class, stop, price, and sorting controls are supported?

Use adults , children , infants_in_seat , and infants_on_lap to describe the travelling party. The documented travel_class values are economy , premium_economy , business , and first . Use stops to request any number of stops, nonstop flights, one-stop flights, or flights with up to two stops. Use max_price for a maximum total-price filter and set sort_by to top or price . Country, language, and currency can be controlled with gl , hl , and currency .

How do round-trip searches work?

Google Flights selects a round trip in two steps, and the API follows the same process. The first request returns outbound options. Each outbound price represents the lowest complete round-trip total Google can pair with that outbound. Select an outbound option and send its departure_token in a second Flights Search request with the same route and dates. The second response returns compatible return flights and exact totals for the selected outbound-and-return combinations.

Does the returned flight price include taxes, fees, and every passenger?

The price field represents the total Google Flights displays for the entire travelling party, including mandatory taxes and fees. It is not a per-passenger price. Optional extras such as checked baggage, seat selection, onboard services, and other airline add-ons are not included and should be checked with the booking provider.

How much does the Google Flights Scraper API cost?

Flights Search currently costs 7 credits per successful request. The Flights Booking Options cost is not published as a fixed amount in the endpoint documentation, so it should be loaded from ScrapeBadger's current public pricing feed using the exact route or the current Google base cost when no route override exists. There is no per-itinerary or per-booking-option charge, and failed requests cost 0 credits.

Start Building With the Google Flights Scraper API

Use 1,000 free credits to search flight itineraries, compare available prices and schedules, and retrieve airline and travel-agency booking options through two structured JSON endpoints.

No credit card required · Failed requests cost 0 credits

Disclaimer: ScrapeBadger is not affiliated with, endorsed by, or in any way officially connected with Google LLC or any of its subsidiaries or affiliates. Google and related trademarks are the property of their respective owners.