# update()

Canonical URL: https://developers.iagenify.com/sdk/ref/host/update/
Language: en

`host.update({ label }) → Promise<Host>`

Renames the host. The label only — the slug is the address, and it does not change.

Status: PATCH · label only · the slug is the URL

```javascript
await site.update({ label: "Portfolio (2026)" });
```

## Why the slug is fixed {#why}

> **Changing it would break three things at once**
>
> Links already shared, the customer domain attached to it, and the certificate issued for that hostname. None of the three fails loudly — they just stop working.

## For another address, another host {#another}

```javascript
const next = await api.hosts.create({ kind: "site", slug: "portfolio-2026", label: "Portfolio" });
await next.deploy({ files: "./out" });
// Then move the domain, and remove the old host when nothing points at it.
```

## What the label is for {#label}

Showing in a list. Nothing depends on it, so changing it is safe — which is exactly why it is the one field that can change.

## It updates the object {#object}

`host.label` is replaced with what came back.

- [create()](/sdk/ref/hosts/create): Choosing a slug.
- [domains.attach()](/sdk/ref/host/domains/attach): An address of your own.

```python
site.update(label="Portfolio (2026)")
```

```python
nxt = api.hosts.create(runtime="static", slug="portfolio-2026", label="Portfolio")
nxt.deploy(files="./out")
# Then move the domain, and remove the old host when nothing points at it.
```
