The cheapest performance win is doing less

performance

A page that ships 40 KB of CSS and no JavaScript will beat a page that ships 300 KB of framework and a service worker to make up for it. This is not a controversial claim, but it is an unpopular one, because the second page is more fun to build.

An audit that takes ten minutes

  1. Open the network tab, disable cache, reload.
  2. Sort by size, descending.
  3. For each of the top five: what would break if it were gone?

Most sites lose a font variant nobody uses, an analytics script that duplicates another one, and an icon library imported for four icons.

The two things worth automating

Image renditions. Serving a 3000 px photograph into a 400 px slot is the single most common waste. Generate the sizes, emit a srcset, let the browser choose.

Cache the HTML. For a site where content changes a few times a week, a full-page cache with a filesystem key is a dozen lines of code and removes PHP from the critical path entirely.

Everything after that is diminishing returns — worth doing, but only once the obvious waste is gone.