How to track impressions from external banners

We want to place a banner on a external website that will redirect to our website when clicked
We will set the redirection link to have utm query parameters so we can track the actions. However, the external website does not offer any analytics regarding impressions so we want to have that data also

Is there any way to track impressions on the banner placed on the external website? We can build a quick counter to increase each time the image is requested from our server but I want to know if there’s anything we can do directly from matomo

You can add a transparent-1-pixel image targeting your Matomo instance.
Look at the code provided in the Administration>Measurables>Tracking Code menu for Image tracking code.
For the complete API, have also a look at:
https://developer.matomo.org/api-reference/tracking-api

Yes i saw that page but we will only be providing the link towards our banner, not an extra image… Also don’t want to overwrite the default 1x1 image that matomo uses because we might need multiple images

Then the 3 other possible solutions are:

  • The ones who host your banner must track the banner impression themselves
  • The server which provides the image will also ping Matomo at each image request
  • Matomo imports the HTTP logs of the server that hosts the image

hmm yes i think i can make a quick script when the image is requested to send a http req to matomo for impression, thank you