Custom data (custom properties) attached to pageviews #320
Replies: 31 comments 57 replies
-
Agreed, this would make the platform a lot more powerful. One use-case we've been asked before is filtering articles by the author of the post. Instead of implementing specific fields like I'm really open for suggestions on how the API for this could look. Some options off the top of my head: 1. ManualIn this case, to send a custom dimension you need to disable automatic pageview collection and instead send them manually along with your custom dimensions: <script async defer data-manual="true" data-domain="plausible.io" src="https://plausible.io/js/plausible.js"></script> ... later plausible('pageview', custom: {author: 'Uku Taht'}) 2. Automatic via script tagThis option would probably be less flexible but more convenient depending how you render your page. Just set the custom dimension via html attributes on the script tag: <script async defer custom-author="Uku Taht" data-domain="plausible.io" src="https://plausible.io/js/plausible.js"></script> The tracker could check for any attribute following the |
Beta Was this translation helpful? Give feedback.
-
Another option as I mentioned is to have custom meta tags that are sent. This could work in a somewhat similar fashion to something like opengraph. Think tags like <meta property="analytics:author" content="David" />
<meta property="analytics:another_field" content="Another Value" /> Any tags with the appropriate prefix get picked up and sent as custom dimensions. These same pieces of data could get picked up for custom events as well. Something like your manual proposal could work as well. |
Beta Was this translation helpful? Give feedback.
-
Right, that looks like a great option as well. |
Beta Was this translation helpful? Give feedback.
-
Hello! Glad to see this feature request has already been raised. :) Chiming in to mention another use case for this feature: A/B testing. To make sure we have a large enough sample size for a test, we’d need to know how many visitors saw a particular variation. FWIW on the API form, we’re also flexible but would prefer the data-attribute or meta tag forms over the manual configuration. |
Beta Was this translation helpful? Give feedback.
-
@janejuenyang Yeah thanks for bringing that up, we don't have a good way to segment visitors for A/B testing. I think implementing custom props on pageviews will definitely be helpful. You can tag the pageview with the visitor's segment and also tag the conversion event. It will work for getting conversion rates but there's some manual work involved where you have to grab the numbers and plug them into a calculator. A second phase could be full support for A/B testing. This would involve:
|
Beta Was this translation helpful? Give feedback.
-
Looks so great!! This feature would help our marketing tremendously! I'd love to see you put this feature on your roadmap! |
Beta Was this translation helpful? Give feedback.
-
The first suggestion @ukutaht provided looks great! As for use cases, custom dimensions is great for many reasons. Examples:
As previously mentioned, the author name example, page information is very important. Like:
Say you have 3 languages and a specific product you want to look at. If the url structure is something like this:
You are going to have to do some extra work to see how many visits product A has, because it has three different URLs. These are some of the offhand use cases I can think of with custom dimensions. |
Beta Was this translation helpful? Give feedback.
-
I think this option would help a problem I am facing with our usage of plausible. We are building an app where users signs up they choose a username and then using that as part of the url, ex. would be maelt.co/anda (my co-founder) The thing is, we want to offer (already do in beta) to point your domain to our server, and just show the profile page as the root of the domain - in this case it would be anda.co (not working) and in plausible it then shows as "/" By being able to add a custom user-id tag to the plausible tag, we would be able to see the difference between visitors to our homepage and to users pages on custom domains. |
Beta Was this translation helpful? Give feedback.
-
For PWA apps, I'd love a way to track users' upgrade journey. Sending the app version along could help me monitor when users are stuck on an old version for example. |
Beta Was this translation helpful? Give feedback.
-
"we set up the following Google Analytics Custom Dimensions on our story pages, via variables provided by our CMS. This allows us to segment traffic based on the content itself. We'd like to continue to segment our content as we move away from Google Analytics. Dimensions:
(one more vote for this feature today via email) |
Beta Was this translation helpful? Give feedback.
-
+1 from me. I have recently implemented dark mode on my website and would love to track how many people use it. Enriching automatic page views I could of course track toggling of the dark mode, but that doesn't really give me an accurate representation of how many people use light vs dark mode. Another info I would like to track is whether my visitors are logged in or not, so again a boolean/string attached to all page views. |
Beta Was this translation helpful? Give feedback.
-
I would also +1 this idea. It is something we do in Google Analytics with content groups and custom dimesions. I would like to be able to label pageviews by:
The big advantage of this is that it allows us to easily report on developments in analytics for these custom properties. Making it much easier to make data-driven editorial decsision. |
Beta Was this translation helpful? Give feedback.
-
I am going to add my support for this feature. My use case is the same as some of the above.
|
Beta Was this translation helpful? Give feedback.
-
WordPress related but feels like it fits for this feature request: "We’re using WPML to translate our site. Somehow Plausible should be able to separate between languages used on the website. Could be done over hreflang or similar. So we can filter the data based on languages and additionally see which languages get used how often." |
Beta Was this translation helpful? Give feedback.
-
+1 from me on this! Would help us out with AB testing |
Beta Was this translation helpful? Give feedback.
-
Another request for this via email with this use case: "I don't see a way in Plausible Analytics to group pageviews, as done with content groups in Google Analytics. On our web site, we want to count pageviews for pages like site.com/name2 and site.com/something-else together, because these are of the same page type. But we also want to count each of these urls separately. In GA it is done like this: Basically I just want to set a parameter that describes what type of page it is. This way we can set a name for each type of page. We have millions of pages, and it makes sense to count them as one type of page." |
Beta Was this translation helpful? Give feedback.
-
+1 for this. I'm responsible for some dashboards for a large publisher and use lots of custom dimensions in GA. The option to also have them in Plausible would make it a more 'enterprise ready' GA alternative. This are some of the dimensions I work with daily.
|
Beta Was this translation helpful? Give feedback.
-
We want to do something similar: We do not want to track the users itself but the organization they work for. It would be helpful if we could configure a callback to attach additional |
Beta Was this translation helpful? Give feedback.
-
We are very much looking forward to such a feature in Plausible. The dimensions that we are working with are basically the same as @rmens listed in his last comment. |
Beta Was this translation helpful? Give feedback.
-
This issue is marked as "in progress" on the roadmap. Some related commits appear to already be on master. Is there already an ETA for this feature? |
Beta Was this translation helpful? Give feedback.
-
This feature would allow to record personal data in your database, right? Nothing prevents from storing email adresses, user ids etc... |
Beta Was this translation helpful? Give feedback.
-
We're currently migrating our site from GA over to Plausible and custom dimensions for pageviews would be great to have. Our use case is the same as people mentioned above, distinguishing between free/paid/unregistered users. |
Beta Was this translation helpful? Give feedback.
-
With GA4-mageddon incoming, this is one (of three) features we are looking for as we review privacy focused options. The others are funnels and events. Our dimensions use case is pretty simple, segmenting page views / metrics by anon, free, subscriber user roles. Looking forward to an ETA (looks like it has been a roadmap feature for a long time) so I can help make the case for plausible! |
Beta Was this translation helpful? Give feedback.
-
I see that pull request #1816 (#1816) was merged and referenced in changelog for v1.5.0. Is this feature now usable or is there more work to do? |
Beta Was this translation helpful? Give feedback.
-
We've now opened up a beta version of this to everyone. You can attach custom properties (also known as custom dimensions in Google Analytics) when sending a pageview to Plausible in order to create custom metrics. Instructions at https://plausible.io/docs/custom-pageview-props |
Beta Was this translation helpful? Give feedback.
-
Hey team, great job in getting this feature out! 🙏 I'm testing this out via the API and having trouble applying multiple filters for different custom properties - (adding an additional (AND) filter returns more page views than with the single filter) Is this supported yet? I can see in the dashboard that you can only select one at a time. |
Beta Was this translation helpful? Give feedback.
-
Fantastic addition! I was curious to know if there are any plans to integrate this feature with the plausible-tracker? |
Beta Was this translation helpful? Give feedback.
-
I would really love to use this. Is this available for the self-hosted variant of Plausible? My use cases are:
|
Beta Was this translation helpful? Give feedback.
-
Hi, Thanks for this. |
Beta Was this translation helpful? Give feedback.
-
Precheck
Please note that this tracker is only for feature requests. Do not use the issue tracker for help or support. Our docs are a great place for most answers, but if you can’t find your answer there, you can contact us. Have an issue with your self-hosted install? You can ask in our community forum. Thanks!
Prerequisites
Feature request
Is your feature request related to a problem? Please describe.
I would like to be able to attach custom data (think GA custom dimensions) when sending a pageview. Then I would like to aggregate on those dimensions. I saw the documentation on custom events but I didn't see anything on attaching custom data to a pageview.
How would you like it to work
I'm pretty flexible here. Perhaps the custom data could come from custom meta tags or perhaps there would be an option to manually trigger a pageview with JavaScript and send the data that way.
Sorry if this feature is available somewhere else and I couldn't find it.
Update: We've now opened up a beta version of this to everyone. You can attach custom properties (also known as custom dimensions in Google Analytics) when sending a pageview to Plausible in order to create custom metrics. Instructions at https://plausible.io/docs/custom-pageview-props
Beta Was this translation helpful? Give feedback.
All reactions