# remove()

Canonical URL: https://developers.iagenify.com/sdk/ref/hosts/remove/
Language: en

`api.hosts.remove(id) → Promise<{ ok: true }>`

Deletes a host: what it served, its hostname, its DNS record and its files all go.

Status: DELETE · the address stops · no undo

```javascript
await api.hosts.remove(id);
```

## What goes {#goes}

- What was served, and every deploy in the history.
- The hostname and its DNS record.
- The files, and the space they held.
- Any customer domain attached to it.

> **A slug freed is a slug anyone can take**
>
> Removing a host releases its address. If the name matters, keep the host — an empty one serves nothing and holds the name.

## Attached domains are released {#domains}

The names stop being served. The domains themselves stay attached to the account; it is the link to this host that goes.

## The space comes back {#space}

Into the account's object storage, and a place opens in the plan.

## Taking something offline without deleting {#alternative}

There is no « pause ». Deploying something minimal — a single page saying the site has moved — keeps the host, the address and the certificate.

- [host.remove()](/sdk/ref/host/remove): The same from the object.
- [domains.detach()](/sdk/ref/host/domains/detach): Releasing a domain first.

```python
api.hosts.remove(host_id)
```
