List of most popular URLs in real time/live

Is it possible to see in real-time (e.g. the last 3 minutes, as is the default with Real Time Visitor Count) the most popular URLs? The API supports showing which URLs particular visitors are going to, but how to generate a report which shows which URLs have been visited the most in the past few minutes? E.g.

www.example.com/page91 25 visits
www.example.com/page65 17 visits

Etc.

Hi,

I don’t think this is already possible with Matomo. But I like the idea as it could be useful for a lot of things.

It should definitely be possible to build something like this as a plugin.

I’m just a bit afraid that this is going to be hard to implement it in a performant way as it can’t really be cached or preprocessed much.

1 Like

Found this plugin called Top Pages By Actions:
https://plugins.matomo.org/TopPagesByActions

But it does not appear to work for version 3.

Hi,

I didn’t know about that plugin, but it really seems to do exactly what you want.

Maybe you could contact the developer and ask him about upgrading the plugin to Piwik 3. It shouldn’t be that hard.

Hi,

Your problem inspired me to start a little initiative to find new maintainer for old plugins:

https://forum.matomo.org/t/adopt-a-plugin-dog/26869

1 Like

@gueditor

I looked again into the TopPagesByActions and as it seems to be quite simple, I tried migrating it to Matomo 3.

You can try out my version from here:

(e.g. by downloading https://github.com/Findus23/piwik-top-pages-by-actions/archive/master.zip and moving the folder in the zip to plugins/TopPagesByActions)

While the User Interface is quite outdated and a bit buggy, that shouldn’t affect you as it is only fetching the API.

http://localhost/piwik/index.php?module=API&method=TopPagesByActions.getTopPagesByActions&idSite=1&lastMinutes=60&format=JSON&token_auth=anonymous returns the following:

[
  {
    "number": "17",
    "idaction_url": "5761",
    "time": "0.00000000",
    "idaction_name": null,
    "name": "null",
    "url": "http://localhost/piwik-1.9.3-b10.zip"
  },
  {
    "number": "16",
    "idaction_url": null,
    "time": "0.00000000",
    "idaction_name": "9",
    "name": "non",
    "url": "null"
  },
  {
    "number": "10",
    "idaction_url": "5730",
    "time": "1.67167000",
    "idaction_name": null,
    "name": "null",
    "url": "http://localhost/latest.zip"
  }
]

Thanks Lukas. I’ll give it a try shortly. Much appreciated.

Just keep in mind that there is no caching or preprocessing. Every api request triggers a sql query.
So you may want to test how performance and cache the result in your application.

It works very well Thanks. Performance is fine. I only need to run it a few times a day, so it’s exactly what I need. Really appreciate you doing this.

How can I make this work with Matomo 4.10.1? This is exactly what I’m missing in order to switch to Matomo once and for all.

It says it requires Piwik <4.0.0-b1.

1 Like

The repository initial owner has no more GitHub activity for more than 2 years, now…
I don’t know either if @Lukas has time to work on his fork…
Maybe @Mikel_Aguirre_Vera you can work on your own fork? (and then share :wink: )

Hi all! Real-time reports on popular URLs now would be a must-have feature for me, too. Is there some update here (or a workaround possibly?). Thanks a mile.

Just bumping this up to second what @AdminKP has said. This kind of data is really important for me as I want to see what content on my site is trending in real-time, not just what the latest visitors are doing.

Any chance this could be delivered anytime soon, Matomo team?

Hi @AdminKP, @deltahf
Did you try Lukas solution?

– Honestly, I was hoping for something more sustainable and delivered by core matomo devs rather than a 10 years old github

Hi @AdminKP
Then you could either:

Create a new issue in Matomo GitHub repo, or if found another similar add some comments in it

Fork Lukas GitHub piwik-top-pages-by-actions plugin