Web tracking API gaps (especially for single-page-apps)

The JavaScript tracking of custom events is a welcome addition to Kentico Cloud. However, it has a couple big gaps that need to be addressed for it to be useful outside of traditional websites:

  • Virtual pageview tracking
  • Activity key/value pairs

If you are using Kentico Cloud tracking on a single page app (for example, an Angular or React-driven website), a mobile application, or any other non-website system, Kentico Cloud will only track an initial pageview.

There is a recommendation here (https://github.com/Kentico/cloud-sample-app-react#tracking-visitors-and-their-activity) to use custom event tracking to achieve this, but that's impractical for a content-managed system, since pages will be dynamically created all the time.

The standard way to achieve tracking in these situations ("standard" meaning Google Analytics' recommended method), is to track virtual pageviews. This is done by sending an explicit pageview event to Google Analytics.

This is not only simple to implement, but it also has the benefit that every page-level report can be used to analyze behavior in the application, and those reports are typically much richer than event/activity reports. (Doubly so with Kentico Cloud, since there aren't any aggregate activity reports yet.)

An additional feature that would simplify things would be to have activities include both the activity itself, and an associated value - like Google Analytics' "Events." If an activity were a key/value pair, my application could send a custom page view activity, with a value of the "URL" or view name that I can analyze.

The key/value on activities would have a lot of applications and make activity tracking far more useful than it is today. As it is, it's just a counter with no nuance, which will lead to a TON of custom activity management - which is rather contrary to the whole concept of reusability and scalability that's core to Kentico Cloud.


  • Hi Nik,

    thank you very much for your feedback. You're right that the tracking API could be improved. I will store your feedback and we will re-evaluate your suggestion about virtual pages, once we have input from more users.

    Regarding the values - we were actually planning extending this feature, but due to other priorities we had to postpone it. Therefore I would love to hear your feedback on few things. First of all, how critical is this capability for your projects? And secondly, how many value pair would you need (is one key-value pair enough)?

    Moreover, if you want we can schedule a quick call to discuss your suggestions.

    Thank you.

    Kind regards,
    Martin Michalik

Sign In or Register to comment.