# FlightAware Flight API Documentation

<p><strong>FlightAware Flight API Documentation</strong> Get one leg of a flight number (LH400) or of an aircraft registration on a UTC departure date. The leg has the gate departure, takeoff, landing and gate arrival, each scheduled, estimated and actual in UTC, with delay, status, aircraft type, airline, both airports with gate and terminal, the filed route and the distance. Add track=1 for the track points with time, position, altitude and speed. The date is the UTC date of the scheduled departure. The answer also has the local date of each airport. Dates reach back 1500 days (a measured depth, not a limit of FlightAware). Legs of the last 14 days are read from the history list. For an older date the API searches the scheduled departure time around the times of the same flight today. The answer shows found_by (list, cache, scan or exact) and lookups. Pass origin, destination and time (HHMM, UTC) when you know them: this costs one lookup and no search. About 75 to 85 percent of old legs of a flight number are found by the search. Flights that moved their departure by more than 30 minutes between seasons (for example CX250 in summer 30 minutes before its time of today), charters and flight numbers with several legs a day are found less often. A registration flies different flights each day, so the search rarely finds its leg: pass origin, destination and time for a registration. A leg that is not found answers 404 and costs no credit. Pass origin, destination and time (HHMM, UTC) to look up one exact leg. An IATA flight number of a major airline (JL5, NH10, CX250) is named by its ICAO airline code; for another airline use the ICAO flight number (DLH400). The tail of an old leg looked up by flight number is hidden by FlightAware: aircraft.tail is null, never a guess. Look up by registration to get the tail. Cost: 2 credits for a leg of the last 14 days, 10 credits for an older leg. A leg that is not found and every failure cost nothing.</p>

- **Documentation:** [https://scrappa.co/docs/flightaware-api/flightaware_flight](https://scrappa.co/docs/flightaware-api/flightaware_flight)
- **API group:** FlightAware API
- **Endpoint:** `GET https://scrappa.co/api/flightaware/flight`

## Authentication

Send your Scrappa API key in the `X-API-KEY` request header. Paid endpoints also support accountless x402 payments when called without an API key.

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `ident` | string | Yes | Flight number or registration, e.g. LH400, DLH400 or D-AIXO. |
| `date` | string | Yes | UTC date of the scheduled departure, YYYY-MM-DD. Up to 1500 days back. |
| `fetch_by` | string | No | flight (default) or reg. |
| `origin` | string | No | ICAO code of the departure airport, e.g. EDDF. Narrows the search. |
| `destination` | string | No | ICAO code of the arrival airport, e.g. KJFK. Narrows the search. |
| `time` | string | No | Scheduled departure as HHMM in UTC, e.g. 1010. With origin and destination it skips the search. |
| `track` | boolean | No | Set to 1 to add the track points. Default: 0. |

## Example response

```json
{
    "data": {
        "leg": {
            "delay": {
                "arrival_minutes": 15,
                "departure_minutes": 13
            },
            "ident": "DLH400",
            "times": {
                "landing": {
                    "actual": "2026-03-15T18:47:00Z",
                    "estimated": "2026-03-15T18:47:00Z",
                    "scheduled": "2026-03-15T18:05:00Z"
                },
                "takeoff": {
                    "actual": "2026-03-15T10:33:00Z",
                    "estimated": "2026-03-15T10:33:00Z",
                    "scheduled": "2026-03-15T10:10:00Z"
                },
                "gate_arrival": {
                    "actual": "2026-03-15T19:05:00Z",
                    "estimated": "2026-03-15T18:45:00Z",
                    "scheduled": "2026-03-15T18:50:00Z"
                },
                "gate_departure": {
                    "actual": "2026-03-15T10:13:00Z",
                    "estimated": "2026-03-15T10:10:00Z",
                    "scheduled": "2026-03-15T10:00:00Z"
                }
            },
            "track": [
                {
                    "lat": 60.596,
                    "lon": -24.6082,
                    "time": "2026-03-15T13:32:28Z",
                    "speed_kt": 459,
                    "altitude_ft": 36000
                },
                {
                    "lat": 53.108,
                    "lon": -60.9128,
                    "time": "2026-03-15T16:21:54Z",
                    "speed_kt": 449,
                    "altitude_ft": 38000
                }
            ],
            "origin": {
                "lat": 50.0333,
                "lon": 8.5705,
                "city": "Frankfurt, Germany",
                "gate": "Z69",
                "iata": "FRA",
                "icao": "EDDF",
                "name": "Frankfurt/Main",
                "terminal": "1",
                "timezone": "Europe/Berlin",
                "scheduled_local_date": "2026-03-15"
            },
            "status": {
                "raw": "arrived",
                "live": false,
                "text": "Landed",
                "state": "landed",
                "diverted": false,
                "cancelled": false
            },
            "airline": {
                "iata": "LH",
                "icao": "DLH",
                "name": "Deutsche Lufthansa, A.G.",
                "callsign": "Lufthansa"
            },
            "aircraft": {
                "hex": null,
                "tail": null,
                "type": "A346",
                "model": "A340-600",
                "owner": null,
                "type_name": "Airbus A340-600 (quad-jet)",
                "engine_type": "jet",
                "tail_hidden": true,
                "engine_count": 4,
                "manufacturer": "Airbus"
            },
            "flight_id": "DLH400-1773388371-airline-1103p:0",
            "permalink": "/live/flight/DLH400/history/20260315/1010Z/EDDF/KJFK",
            "taxi_in_s": null,
            "iata_ident": "LH400",
            "taxi_out_s": null,
            "destination": {
                "lat": 40.6399,
                "lon": -73.7787,
                "city": "New York, NY",
                "gate": "5",
                "iata": "JFK",
                "icao": "KJFK",
                "name": "John F Kennedy Intl",
                "terminal": "1",
                "timezone": "America/New_York",
                "scheduled_local_date": "2026-03-15"
            },
            "distance_nm": {
                "flown": 3539,
                "direct": 3346,
                "planned": 3764
            },
            "flight_plan": {
                "route": "ULKIG4L ULKIG Y180 DIK CAMRN5",
                "speed_kt": 428,
                "cruise_altitude_ft": 38000,
                "estimated_time_enroute_s": 28500
            },
            "track_points": 6
        },
        "date": "2026-03-15",
        "ident": "DLH400",
        "query": "LH400",
        "lookups": 3,
        "fetch_by": "flight",
        "found_by": "scan",
        "date_basis": "UTC date of the scheduled departure",
        "source_url": "https://www.flightaware.com/live/flight/DLH400/history/20260315/1010Z/EDDF/KJFK"
    },
    "meta": {
        "billable": true,
        "credits_charged": 10,
        "endpoint_family": "flight"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | A query parameter is missing or invalid. This response is not billable. |
| 404 | Not Found | FlightAware has no leg of this flight on that date, or its departure time was not found. This response is not billable. |
| 503 | Service Unavailable | FlightAware could not be reached or changed its answer. This response is not billable. Retry later. |

## More Scrappa resources

- [API documentation](https://scrappa.co/docs)
- [Full LLM-readable API reference](https://scrappa.co/llms-full.txt)
- [OpenAPI specification](https://scrappa.co/docs/api.json)
- [Pricing](https://scrappa.co/pricing)
