---
title: "Delete a custom domain"
method: DELETE
path: "/api/domains/{id}"
tags: ["Domains"]
---

# Delete a custom domain

`DELETE /api/domains/{id}`

## Request

- Base URL: `https://www.flyn.to`
- URL: `https://www.flyn.to/api/domains/{id}`
- Auth: HTTP bearer

Deletes a domain in the caller's scope. First, links the caller created on it are moved back to the legacy www.flyn.to domain; teammates' links on a team domain are not moved.

**Auth:** API key (`Bearer flyn_sk_live_...`), or the signed-in dashboard session cookie when no API key header is sent. MCP OAuth access tokens are not accepted here and get 401.

**Plan:** every plan.

**Rate limit:** 10 requests per 60 s per client IP, fixed window, in memory per server instance, checked before authentication.

## Response `200`

Deleted.

- Success
  - `success` true, required

## Other responses

- `401`: No valid API key and no dashboard session. Messages: "Invalid or revoked API key", "API key has expired", "Unauthorized. Sign in to the dashboard, or pass a Bearer API key in the Authorization header.", or "Unauthorized" when the session lookup itself fails. An MCP OAuth token lands here too.
- `403`: The account is suspended.
- `404`: Not found or not in scope.
- `429`: More than 10 requests in the window. Counted per client IP. Retry-After gives the seconds until the window resets.
- `500`: Delete error.

---

[API](https://skmtc.dev/flyn/apis/flyn-api.md) · [All operations](https://skmtc.dev/flyn/apis/flyn-api/llms.txt) · [OpenAPI document](https://skmtc.dev/flyn/apis/flyn-api/revisions/977962a98ccb?raw)
