TickYouOff
Back

Web Performance Budget Setup

Medium 16 items · 1 hour
testuser's avatar
testuser Published 1 month ago

Set up a clear web performance budget to keep Core Web Vitals and payloads in check. This checklist guides teams through measuring current scores, defining numeric budgets (LCP, INP, CLS, JS size, images, fonts), and automating enforcement with Lighthouse CI. It’s for developers, performance engineers, and product owners who want repeatable performance guardrails.

Progress
0 / 16
  1. Run baseline Lighthouse and field audits — Audit representative pages (mobile) using Lighthouse, CrUX, and RUM to capture current LCP, INP, CLS.
  2. Define numeric performance budgets — Turn goals into measurable targets teams can track and enforce.
  3. Set LCP budget to 2.5s — Target field LCP ≤ 2.5s (75th percentile on mobile).
  4. Set INP budget to 200ms — Aim for INP < 200ms by reducing main-thread tasks and input delays.
  5. Set CLS budget to 0.1 — Keep cumulative layout shift under 0.1 by reserving sizes and avoiding late inserts.
  6. Create asset size budgets — Define payload limits for JS, images, and fonts so teams can measure regressions.
  7. Keep total JS bundle under 200kb — Measure gzipped or brotli sizes and include vendor code in totals.
  8. Prefer WebP or AVIF for images — Serve modern formats with fallbacks to reduce bytes.
  9. Subset and preload critical fonts — Subset glyphs, preload key fonts, and use font-display:swap to reduce blocking.
  10. Audit third-party scripts and tag vendors — Identify heavy or blocking third parties and remove or lazy-load nonessential ones.
  11. Serve responsive images and lazy-load offscreen assets — Use srcset, sizes and native lazy-loading to reduce initial payload.
  12. Apply code-splitting and tree-shaking — Split routes and vendor code; remove unused exports to shrink bundles.
  13. Enable compression, long caching, and resource hints — Use brotli/gzip, set cache headers, and add preload/preconnect for critical resources.
  14. Automate Lighthouse CI checks — Add automated checks so performance regressions are caught before merge.
  15. Add budgets to Lighthouse CI config — Declare performance and asset budgets in .lighthouserc or lighthouse-ci config file.
  16. Fail CI builds when budgets exceed limits — Configure CI to fail or warn on budget violations to prevent regressions.
Sign in to save
📝 My Notes