> For a complete index of all SignalWire documentation pages, fetch https://signalwire.com/docs/llms.txt

# hangup

> Hangs up the call and releases all resources.

```ts
hangup(): Promise<void>
```

Ends the call and releases all WebRTC resources.

Sends a Verto `bye` to the server, transitions [`status$`](/docs/browser-sdk/v4/reference/webrtc-call/status\$) to `disconnecting` then `disconnected`, and destroys the call instance. After the promise resolves, the call object is no longer usable — drop your reference and let it be garbage-collected.

The promise resolves once the local teardown has completed. Server-side cleanup (recording finalization, billing) continues asynchronously and is not awaited.

## **Returns**

`Promise<void>` — resolves when the local teardown has completed.

## **Examples**

### Hang up on user click

```ts
endCallButton.addEventListener('click', async () => {
  await call.hangup();
  showCallEndedUI();
});
```

### Hang up from a status subscription

```ts
call.status$.subscribe(async (status) => {
  if (status === 'connected' && callTooLong()) {
    await call.hangup();
  }
});
```

## **See**

* [`reject`](/docs/browser-sdk/v4/reference/webrtc-call/reject) to decline an inbound call before it's answered.
* [`status$`](/docs/browser-sdk/v4/reference/webrtc-call/status\$) to observe the call's lifecycle.