> ## Documentation Index
> Fetch the complete documentation index at: https://docs.vertracloud.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Remove Application Domain

> Removes a custom domain from an application, together with its automatic www companion.

Removes the domain and, when it has one, its automatic `www` (or root) companion. The domain stops resolving to the
application right away and can be added to another application. The application is not restarted. Domains that
redirected to the removed one start serving the application instead. Requires the `apps:write` scope when called with
an API key.

**id** `string` *required*

The application ID.

**domain\_id** `string` *required*

The ID of the domain to remove, from [List Application Domains](/api-reference/endpoint/apps/domains/list).

**workspace\_id** `string`

If the application belongs to a workspace, the workspace's ID. Required for workspace members acting on an application they don't own.

### Response

A success returns `200` with `{ "response": null }`.

```json Response theme={null}
{
  "response": null
}
```

> [!WARNING]
>
> **Removing a domain does not change your DNS.** Delete the `CNAME` and the validation `TXT` records of the domain, and
> of its companion, at your DNS provider. If they stay, the name keeps pointing at Vertra Cloud and another customer
> could claim it. The same applies when the domain disappears because the application was unpublished or because the
> 14-day cleanup removed it.

> [!NOTE]
>
> Removing the **companion** of a domain removes only the companion. To drop both, remove the main domain.
> Unpublishing the application removes every domain at once.

### Error Responses

**code** `string`

The error code indicating the reason for the failure. Possible values:

* `VALIDATION_ERROR`: The path parameters failed validation (`400`). The response also carries `message` and `path`.
* `UNAUTHORIZED`: The request is not authenticated (`401`).
* `USER_NOT_FOUND`: The authenticated user could not be resolved (`401`).
* `ACCESS_DENIED`: The user does not have permission to act on the application (`403`).
* `API_KEY_SCOPE_DENIED`: The API key does not have the `apps:write` scope (`403`).
* `APP_NOT_FOUND`: The specified application does not exist (`404`).
* `DOMAIN_NOT_FOUND`: The application has no domain with that ID (`404`).
* `RATE_LIMIT_EXCEEDED`: The route's budget was reached (`429`).
* `INTERNAL_SERVER_ERROR`: Unexpected failure (`500`).

```json Error Response (404) theme={null}
{
  "code": "DOMAIN_NOT_FOUND"
}
```

> [!NOTE]
>
> This route has its own budget of 10 requests per minute. See [Rate Limiting](/api-reference/introduction#how-is-the-api-rate-limited).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.