> For the complete documentation index, see [llms.txt](https://obytejs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://obytejs.com/0.1.3/utils/keep-connection-alive.md).

# Keep connection alive

To keep the connection with the WebSocket node alive you need to notify the node that your peer is awake every 10 sec.&#x20;

### Example

```javascript
setInterval(function() {
  client.api.heartbeat()
}, 10 * 1000);
```
