Skip to content

Instantly share code, notes, and snippets.

@rviscomi
Created May 7, 2020 17:39
Show Gist options
  • Save rviscomi/bbb776099c3fbda05356c3d7cfa4e053 to your computer and use it in GitHub Desktop.
Save rviscomi/bbb776099c3fbda05356c3d7cfa4e053 to your computer and use it in GitHub Desktop.
CrUX Core Web Vitals timeseries
# Query the Core Web Vitals for an origin over time.
SELECT
yyyymm,
# Largest Contentful Paint
# good < 2500ms, poor >= 4000ms
p75_lcp,
fast_lcp AS good_lcp,
avg_lcp AS needs_improvement_lcp,
slow_lcp AS poor_lcp,
# First Input Delay
# good < 100ms, poor >= 300ms
p75_fid,
fast_fid AS good_fid,
avg_fid AS needs_improvement_fid,
slow_fid AS poor_fid,
# Cumulative Layout Shift
# good < 0.10, poor >= 0.25
p75_cls,
small_cls AS good_cls,
medium_cls AS needs_improvement_cls,
large_cls AS poor_cls
FROM
`chrome-ux-report.materialized.metrics_summary`
WHERE
# metrics_summary is partitioned by date, YYYY-MM-01.
date >= '2020-01-01' AND
origin = 'https://web.dev'
ORDER BY
yyyymm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment