What is a Performance Budget?
You'll learn: How performance budgets act as guardrails to keep your site fast by setting hard limits on measurable performance metrics.
The Core Concept
A performance budget is a set of predefined constraints you impose on your website's performance characteristics. Think of it like a financial budget: just as you allocate dollars to different expenses and refuse to overspend, a performance budget allocates "resources" like kilobytes, milliseconds, and points to different aspects of your site—and holds you accountable when you try to exceed them.
Performance budgets typically constrain:
- File sizes (e.g., "JavaScript bundles must stay under 200 KB")
- Load times (e.g., "Time to Interactive must be under 3.5 seconds")
- Core Web Vitals scores (e.g., "LCP must remain under 2.5 seconds")
- Request counts (e.g., "No more than 50 HTTP requests per page")
Why Budgets Matter
Without explicit limits, websites naturally grow heavier over time—a phenomenon called "performance regression." Every new feature, third-party script, or high-resolution image chips away at speed. Performance budgets prevent this by:
- Making performance a measurable requirement, not an afterthought
- Enabling automated alerts when thresholds are crossed (in CI/CD pipelines)
- Forcing trade-off conversations ("Do we really need this 500 KB animation library?")
Building on Your Baseline
Remember establishing performance baselines? Your budget builds directly on that. If your baseline shows LCP at 2.1 seconds, you might set a budget of "LCP ≤ 2.5 seconds" to allow slight fluctuation while preventing major regression.
Key Takeaway: A performance budget transforms performance from a vague goal into concrete, enforceable limits on file sizes, load times, and metric scores—protecting your site from getting slower over time.