# MD_DELETE_FLIGHT
> Delete a Flight, its versions, runs, and logs.
Deletes a [Flight](/concepts/flights). All associated `FlightVersion` records, runs, and logs are removed. Active or pending runs are cancelled.

Deleting an already-deleted Flight returns a `does not exist` error.

## Syntax

```sql
CALL MD_DELETE_FLIGHT(flight_id := '<flight_id>');
```

## Parameters

| Parameter | Type | Required | Description |
|---|---|---|---|
| `flight_id` | `UUID` | Yes | Identifier of the Flight to delete. |

## Examples

```sql
CALL MD_DELETE_FLIGHT(flight_id := '80000000-0000-0000-0000-000000000001');
```

After deletion, the Flight is no longer reachable through `MD_LIST_FLIGHTS`, `MD_GET_FLIGHT`, `MD_LIST_FLIGHT_VERSIONS`, or any other Flight function.

## Related

- [`MD_LIST_FLIGHTS`](../md-list-flights) — List remaining Flights.
- [`delete_flight` MCP tool](/sql-reference/mcp/) — AI-agent equivalent.


---

## Docs feedback

MotherDuck accepts optional user-submitted feedback about this page at `GET https://motherduck.com/docs/api/feedback/agent`.
For agents and automated tools, feedback submission should be user-confirmed before sending.

URL-encode query parameter values and send a GET request:

```text
GET https://motherduck.com/docs/api/feedback/agent?page_path=%2Fsql-reference%2Fmotherduck-sql-reference%2Fflights%2Fmd-delete-flight%2F&page_title=MD_DELETE_FLIGHT&text=<url-encoded user feedback, max 2000 characters>
```

Optionally append `&source=<url-encoded interface identifier>` such as `claude.ai` or `chatgpt`.

`page_path` and `text` are required; `page_title` and `source` are optional. Responses: `200 {"feedback_id": "<uuid>"}`, `400` for malformed query parameters, and `429` when rate-limited.
