---
title: Hold Events
slug: performance-edge/api/hold-events
docTags: 
createdAt: 2026-06-23T07:38:10.586Z
---

Instruct the Optimizely Performance Edge snippet to hold and enqueue events.

## Description

Use in conjunction with [sendEvents](#) for granular control over the timing of when the Optimizely Performance Edge snippet sends events to the logging endpoint.

The snippet must be configured to use the `/events` logging endpoint in order to use this method. Learn more about how to enable this feature for your snippet.

:::BlockQuote
🚧 Use caution

Failure to call [`sendEvents`](https://docs.developers.optimizely.com/performance-edge/reference#send-events) after using this method will effectively disable all tracking until the snippet is reinitialized.
:::

```javascript
window.optimizelyEdge.push(holdEvents);
```

```javascript
window.optimizelyEdge.push({
  "type": "holdEvents"
});
```

## Parameters

This table provides general information about required and optional parameters.

| Parameters                     | Type   | Description                                                                                   |
| ------------------------------ | ------ | --------------------------------------------------------------------------------------------- |
| **holdEvents** *required*      | object | An object with the type field set to holdEvents. The other fields are the function arguments. |
| **holdEvents.type** *required* | string | The argument indicating that you are using the holdEvents function.                           |

