Can snowplow measure first contentful paint?


I would like to know if snowplow can measure first contentful paint?

I know using performance timing context, we can measure the page load performance, but it only measure up to first paint (ie. when the first pixel starts to be drawn). AFAIK, it does not measure up to first contentful paint. So is there anyway for snowplow to do that?

Hi @aditya,

This isn’t something that the tracker currently handles itself currently. We’re interested in the concept and are at very early stages of exploring something along these lines - but even if we have promising results from those experiments it would still likely be a while before it would get scheduled into our roadmap and delivered.

It is possible, however, to handle the logic of measuring this data yourself, and track the results using a custom event or context. The most striaghtforward way to do so would be to instrument something like the Paint Timing API outside the tracker, define custom schemas, and track the data against those schemas.

If this is something you do embark on, it would be awesome to hear back from you on how you instrumented it and what the results are - oftentimes, if we’re considering how feasible a feature is, then having someone show us a viable proof of concept will lend weight to the idea and accelerate the discovery phase - especially if it’s been instrumented in a production environment and we can learn from the results.

Hope that’s helpful!


Hi @Colm,

Thanks for your reply and your information. Seems that Paint Timing API is the closest that I can do for now to get this information. I would probably do as what you mentioned above, create an unstructured event context, define the schemas, create javascript in GTM side to get the Paint Timing API and get the numbers, and fire those as unstructured event context.

Let me see to implement this and I let you know if I am getting good feasibility with it.