# Google Analytics

Fire events to your Google Analytics account from the chatbot flow.

Available on the **STARTER plan** and above

Google Analytics is an analytics tracking tool built by Google which websites use to track the visitor behaviour.

When you want you track certain events that occur on your website, you need to **fire events** on Google Analytics.

To fire an event to GA from WotNot, all you need to do is define a "Google Analytics" block at the point in the chatbot flow when you want to fire.

![](https://help.wotnot.io/~gitbook/image?url=https%3A%2F%2F360969599-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FsrMxU8nO3RjusUiYuXBB%252Fuploads%252Fq7xnr9qecpuKvQCFp2T1%252FCleanShot%25202024-05-14%2520at%252011.28.12.png%3Falt%3Dmedia%26token%3Da22d7af5-0271-4111-aae2-84ba3d13b16f\&width=768\&dpr=4\&quality=100\&sign=139ed298\&sv=1)

#### Measurement ID <a href="#measurement-id" id="measurement-id"></a>

The measurement ID acts as a critical link, connecting your website to the corresponding data stream in Google Analytics 4. It ensures that the data from your site is sent to the right location.

[Find your measurement ID](https://support.google.com/analytics/answer/12270356?hl=en)

#### Event name <a href="#event-name" id="event-name"></a>

The name of the event that you want to fire. Event names are to be written in lowercase without spaces and help you easily understand what that event is.

Some examples are -- chat-started, menu-selected, lead-generated etc.

#### Event parameter <a href="#event-parameter" id="event-parameter"></a>

An event parameter is an additional piece of data about a user interaction on a website and/or app, offering valuable context and details about the interaction.

For example, in the below screenshot we have a main menu with multiple options. We can create an event "menu-selected" and pass an additional event parameter which tracks the menu selected under "option".

![](https://help.wotnot.io/~gitbook/image?url=https%3A%2F%2F360969599-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FsrMxU8nO3RjusUiYuXBB%252Fuploads%252FBUJrV4wEWd2sOoMaQIzH%252FCleanShot%25202024-05-14%2520at%252011.39.37.png%3Falt%3Dmedia%26token%3D046bee0b-0c10-406a-af18-159d95ac2fc1\&width=768\&dpr=4\&quality=100\&sign=b4cabf74\&sv=1)

[Learn more about event parameters](https://support.google.com/analytics/answer/13675006?hl=en)

You can use variables in the Event name, and while defining value to event parameters

#### Other options <a href="#other-options" id="other-options"></a>

You can also use the [Javascript](https://help.wotnot.io/bot-builder/action-blocks/javascript)[ action block](https://help.wotnot.io/bot-builder/action-blocks/javascript) to fire events directly on client side.

Once fired, you can create a tag on Google Tag Manager that listens to this event as a trigger and triggers its tag, which would fire an event on your GA4 account.

\ <br>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.wotsabot.ai/wotsabot-help-articles/integrations/ready-integrations/google-analytics.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
