> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kameleoon.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Associate events and actions with your widget

> Learn how to define interactive behaviors for your widgets by connecting event triggers with automated actions in the Kameleoon Widget Studio.

Define how and when your widget behaves by associating events and actions. Events are triggers that detect specific visitor behaviors or page states, while actions are the responses that Kameleoon executes when those events occur.

For example, you can create a multi-step pop-in flow where submitting an email address in the first pop-in (Event) triggers the display of a second "thank you" pop-in (Action).

## Access the Events section

To manage your widget's triggers and responses, open the Widget Studio and click **Events** in the left sidebar.

<Frame>
  ![](https://storage.googleapis.com/kameleoon-storage-documentation/user-manual/images/assets/widgets/create-a-widget-with-the-widget-studio/associate-events-and-actions-with-your-widget/events-page.png)
</Frame>

## Manage events

An event defines when Kameleoon performs one or more actions. You configure an event's conditions and its actions together in the same panel.

### Create an event

To create a new event:

1. Click **Add event**. The **Create new event** panel opens.
2. Select the type of event you want to create and click **Next**.
3. Under **Conditions**, use the dropdowns to define the values that trigger the event. Click **Add device trigger** to add a condition based on the visitor's device.
4. Under **Actions**, define the action Kameleoon performs when the conditions are met. Click **Add action** to add more actions to the same event, and click the trash icon next to an action to remove it.
5. Optional: click the pencil icon next to the panel title to rename the event.
6. Click **Save** to save the event.

<Frame style={{ maxWidth: "50%", margin: "0 auto" }}>
  <img src="https://storage.googleapis.com/kameleoon-storage-documentation/user-manual/images/assets/widgets/create-a-widget-with-the-widget-studio/associate-events-and-actions-with-your-widget/events-sidebar.png" alt="Create new event panel with Conditions and Actions sections" />
</Frame>

### Edit or delete an event

To manage an existing event, hover over its card in the **Events** section, then:

* **Edit:** Click the pencil icon.
* **Delete:** Click the trash can icon.

### Event types

Kameleoon offers several event types to trigger actions:

| Event type            | Description                                                                                     |
| :-------------------- | :---------------------------------------------------------------------------------------------- |
| **Click**             | Triggers when a visitor clicks a specific element.                                              |
| **URL**               | Triggers when the page URL contains a specific value or matches a regular expression.           |
| **Display**           | Triggers before or after the widget is displayed.                                               |
| **Survey**            | Triggers based on a survey or form value.                                                       |
| **Language**          | Triggers based on the visitor's browser language.                                               |
| **Timer**             | Triggers based on time factors, such as a delay.                                                |
| **Custom data value** | Triggers when a specific custom data value meets defined conditions.                            |
| **Device**            | Triggers based on the visitor's device type.                                                    |
| **Wheel of fortune**  | Triggers based on a wheel of fortune action. Requires a wheel of fortune element on the widget. |
| **Scratch card**      | Triggers based on a scratch card action. Requires a scratch card element on the widget.         |
| **Countdown**         | Triggers when a countdown ends. Requires a countdown element on the widget.                     |
| **Video**             | Triggers when a video ends. Requires a video element on the widget.                             |

## Action types

You configure an event's actions under **Actions** in the **Create new event** panel. Kameleoon offers the following action types:

| Action type          | Description                                                                               |
| :------------------- | :---------------------------------------------------------------------------------------- |
| **Elements**         | Shows or hides a specific element within the widget.                                      |
| **Screens**          | Shows or hides a specific screen within the widget.                                       |
| **Kameleoon goals**  | Converts or cancels a Kameleoon goal.                                                     |
| **Kameleoon events** | Triggers a custom event for segment targeting.                                            |
| **Kameleoon data**   | Sets a custom data value.                                                                 |
| **URL redirects**    | Redirects the visitor to a specified URL.                                                 |
| **JavaScript code**  | Runs custom JavaScript code.                                                              |
| **Survey/Form**      | Enables or disables a survey or form element.                                             |
| **Browser storage**  | Sets a value in local storage, session storage, or a browser cookie.                      |
| **Wheel of fortune** | Rotates a wheel of fortune element. Requires a wheel of fortune element on the widget.    |
| **Translation**      | Displays the widget in a specific language. Requires translations enabled for the widget. |
