wordpress
wordpress copied to clipboard
Track what people search for on the site
This is something we may do for all sites in the future but might be easier to do for WordPress as the WordPress site search is more standardized. Basically having a custom event called "Site Search" or something like that and sending all the different things people search for as custom props. Then site owners will have a list of keywords / topics people search for on the site. More details https://github.com/plausible/analytics/discussions/164
+1
We now have a feature that allows you to get search terms so perhaps we can integrate this somehow with the WordPress plugin in the future. See https://plausible.io/docs/custom-query-params
@metmarkosaric any ETA on this? Asking for the project we would like to kickoff end of the month. We're not allowed to use plausible if we dont have a native search integration
hi @masteradhoc! no ETA at the moment unfortunately. we're actively looking for some external help with our WP plugin as we'd like to speed up its development. at the moment, the best way to get search terms would be with this feature. it works very well with the native WordPress search: https://plausible.io/docs/custom-query-params
@metmarkosaric I've got an implementation ready with the custom query param above, will do a pull shortly. But I'm actually wondering if this is the right way to go. Wouldn't it make more sense to:
- send a pageview to
<example.com>/search/ - send an event named "Search" with the value as props, so I'd do:
plausible('Search', {props: {keyword: 'test'}})
That'd make it a lot easier to look at those stats?
nice one @jdevalk, thanks again! @ukutaht is the best person to speak to in terms of how it should work technically. i can see Uku shared some details here on his thinking: https://github.com/plausible/analytics/discussions/164#discussioncomment-2366631
@ukutaht I think the biggest problem is that once I filter by one thing, for instance, resultCount, I can't see the other variables anymore. So I couldn't see keyword when filtering by resultCount == 0:

@ukutaht would be good to get some input on this before continuing with https://github.com/plausible/wordpress/pull/87?
Yes I think the custom event approach proposed by @jdevalk is the best. As he mentioned there's a limitation on filtering/displaying more than a single custom prop at a time. This is a known limitation on the backend that we are planning to address in the future.
Done in #119 above.
This is included in the latest beta of v2.1.0.
Update: Latest version of our WordPress plugin introduces site search tracking. You can see the popularity of different search terms and the number of search results for the individual terms. Special thanks to @jdevalk! Details at: https://plausible.io/wordpress-analytics-plugin