Query by URL in BigQuery dataset

329 views
Skip to first unread message

Matthew Delambo

unread,
Oct 20, 2020, 2:52:53 PM10/20/20
to Chrome UX Report (Discussions)
I've been using the CrUX api which gives me the ability to get CrUX data for a given URL. Is it possible to use the BigQuery interface to query by URL instead of origin.

When querying for CrUX data, I would like to avoid including a lot of the subdomains on the site that I work on, which is a lot of noise. I'd also like to be able to query for cohorts of content/page types on the site so that I can monitor them individually.

Rick Viscomi

unread,
Oct 20, 2020, 3:13:09 PM10/20/20
to Chrome UX Report (Discussions), Matthew Delambo
Hi Matthew,

> Is it possible to use the BigQuery interface to query by URL instead of origin.

The BigQuery dataset only supports origins by design, so your best bet to see URL-level data would be to use the PSI or CrUX APIs or Search Console if you're the site owner.

> When querying for CrUX data, I would like to avoid including a lot of the subdomains on the site that I work on, which is a lot of noise.

The origin-level data is at scheme and subdomain granularity, so you can query for only the subdomains you're interested in, if that helps.

> I'd also like to be able to query for cohorts of content/page types on the site so that I can monitor them individually.

If you have a set of known URLs you can look them all up in the API and weight them together based on your internal analytics. It's a bit complex but it should be doable as long as you're able to enumerate every URL you're interested in and you don't hit API quota limits.


Rick

Matthew Delambo

unread,
Oct 20, 2020, 4:33:45 PM10/20/20
to Chrome UX Report (Discussions), Rick Viscomi, Matthew Delambo
Thanks Rick!

What you described at the end is exactly what we are doing with the CrUX web api. It's a little cumbersome. Our data team uses a tool called Chartio which is kind of like DataStudio, and let's us query our RUM metrics from an internal BigQuery instance. To simplify things, we were hoping to join our RUM tables against the CrUX BigQuery dataset.

Good to know that we can at least look by sub-domain.

Reply all
Reply to author
Forward
0 new messages