Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions docs/custom-event-goals.md
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,33 @@ Once you’ve made the necessary changes, simply click "Update goal," and your u

Custom properties can be attached to events to capture dynamic elements and to further break down goal conversions. You can use custom properties to create your custom metrics to collect and analyze data that Plausible doesn't automatically track. [Learn more here](/custom-props/for-custom-events).

### Automatically attached properties

#### `url`

For clicks on links (`<a>` elements) tagged with `plausible-event-name=...`, we automatically track where the link is pointing (its `href` property).

:::note
This property is not automatically attached when the tagged `<a>` element is within `<svg>` tags.
:::

There's no additional processing on our side for this value and the value of `href` is stored in full. If you're tagging links that contain sensitive data, you may want to stop this value from being sent. You can do so by providing the following `transformRequest` option when initializing the tracker.

```javascript
function omitAutomaticUrlProperty(payload) {
if (payload.p.url) {
delete payload.p.url
}
return payload
}

plausible.init({
transformRequest: omitAutomaticUrlProperty
// ... your other init options
})
```


### Monetary values to track ecommerce revenue

You can also send dynamic monetary values alongside custom events to track revenue attribution. Here's how to set up the [ecommerce revenue tracking](ecommerce-revenue-tracking.md).
Expand Down