When you want to collect additional data about events that happen on your site or app, you need to create a custom event using a ready-made tag in Tag Manager. This tag will pass information about an event category, name, action and value to Analytics, and you’ll see it in a custom event report.

To create a custom event, follow these steps:
- Go to Menu > Tag Manager.
- Navigate to Tags.
- Click Add a tag.
- Name the tag and select the following type: Custom event.
- Click Next.
- Add the following elements:
- Category (string, required): The category of the event you’re tracking. The category organizes events into groups. Example:
Buttons
. - Action (string, required): The action of the event you’re tracking. The action tells you what a visitor did. Example:
Click
. - Name (string, optional): The name of the event you’re tracking. The name gives you more information about the event. Example:
Sign up
(a CTA on your button). - Value (float, optional): The value you want to assign to the event you’re tracking. Example:
5
. If an action is worth some money for your business, like a signup button click is worth 5 USD, you can assign a value for it. Every time an event happens, Piwik PRO will count the value and show the total value in an event report.
Note: You can track a previously created custom dimension along with the event by picking the index number of the dimension and providing its value. For more, read this article.
- Category (string, required): The category of the event you’re tracking. The category organizes events into groups. Example:
- In Advanced tag settings, choose Consent type. Set it up if you use a consent form on your site. This tag will fire only for visitors who accept the selected consent type.
- In Tag triggers, click Add a trigger or Choose existing trigger to set up a trigger for your tag.
- Adjust trigger conditions.
- When you’re done, click OK for the trigger.
- Click Save for the tag.
- Test your tag in debug mode.
- When you’re happy how the tag works, click Publish.
- Now your data is collected and you can see it the event under Menu > Analytics > Reports > Custom events.
- You can also see custom events under Analytics > Reports > Session log.
Tip: See some examples of using custom events:
For developers: You can set up custom events manually by modifying the tracking code.