Brotli or gzip compression enabled on text assets
Why it matters
Uncompressed text assets transfer 2–5x more bytes than their compressed equivalents (ISO-25010 resource-utilisation). A 245 KB JavaScript bundle served without compression transfers 245 KB; with Brotli compression it transfers approximately 55 KB — a 78% reduction. Every kilobyte saved reduces time-to-interactive on constrained connections, cuts CDN egress costs, and directly improves LCP for users on slower networks. Brotli consistently outperforms gzip by 15–25%, making it the preferred algorithm for static text assets.
Severity rationale
Low because major hosting platforms enable compression by default, so this finding usually indicates a custom server misconfiguration rather than a novel issue — but the byte impact can be substantial.
Remediation
Verify compression is active by checking response headers:
curl -sI -H "Accept-Encoding: br, gzip" https://yoursite.com/js/app.js | grep -i content-encoding
# Expected: content-encoding: br (or gzip)
For Node.js servers without a CDN or reverse proxy in front, add the compression middleware:
// server.ts
import compression from 'compression'
import express from 'express'
const app = express()
app.use(compression()) // enables gzip by default
For Brotli (better compression ratio), use shrink-ray-current instead:
import shrinkRay from 'shrink-ray-current'
app.use(shrinkRay()) // serves br for capable clients, gzip as fallback
Vercel, Netlify, and Cloudflare enable Brotli by default — no configuration needed on those platforms.
DetectionPro
The detection method for this pattern is part of AuditBuffet Pro.
The full method (what to look for, pass and fail conditions, and how results get reported) ships inside the Performance Core Audit. The pattern definition, severity rationale, and remediation remain openly licensed under CC-BY-4.0.
External references
- iso-25010:2011 · performance-efficiency.resource-utilization — Resource Utilisation
Taxons
History
- 2026-04-18·v1.0.0·Initial import from performance-core·automated