WordPress Performance Audit Checklist for 2024

A WordPress performance audit checklist

Performance work on WordPress sites often starts with a caching plugin and a vague feeling, and ends without knowing what helped. An audit turns it around: measure first, go through the layers from the server to the browser, write down what is wrong, and fix the biggest problem first. This checklist is the order I use, with the command or tool for each point.

Problem: A site “feels slow”. Over a year, three caching plugins and an image optimizer were installed, nobody measured before or after, and nobody knows which layer is the bottleneck.

Solution: Record a baseline (field data from PageSpeed Insights or the Chrome UX Report, a lab run in WebPageTest, the server time of uncached requests), then check the server, the database and WordPress, the assets and third-party scripts in this order, fix one thing at a time and measure again.

0. Baseline

  • Field data: PageSpeed Insights for the home page and two or three typical templates (a post, a product, an archive). These are the numbers of real visitors over 28 days: LCP, INP, CLS.
  • Lab data: WebPageTest from the region of the visitors, mobile profile, first and repeat view. Save the links.
  • Server time: curl -s -o /dev/null -w '%{time_starttransfer}\n' 'https://example.com/?nocache=1' several times; the query parameter skips most page caches and shows how fast PHP is.

1. Server

  • Current PHP version (8.1 or newer in 2024) with OPcache enabled; opcache.memory_consumption large enough that the OPcache status shows free memory and no restarts.
  • Uncached TTFB under about 600 ms, cached under 200 ms.
  • Full-page cache works: the second request returns a cache header (X-Cache: HIT, cf-cache-status: HIT or the header of your plugin).
  • HTTP/2 or HTTP/3 and Brotli or gzip for text: curl -sI --compressed https://example.com/ | grep -i -E 'HTTP/|content-encoding'.
  • Static files with long cache lifetimes: Cache-Control: max-age=31536000 for versioned CSS, JS, fonts and images.

2. Database and WordPress

  • Query Monitor on a typical page: number of queries, slow queries, duplicate queries, which plugin or theme function causes them.
  • No N+1 patterns, like get_post_meta() or get_the_terms() per post in a custom loop without primed caches: N+1 queries in WordPress.
  • Autoloaded options small (under about 1 MB in total):
SELECT ROUND(SUM(LENGTH(option_value)) / 1024) AS kb, COUNT(*) AS options
FROM wp_options
WHERE autoload IN ('yes', 'on', 'auto-on', 'auto');

Since WordPress 6.6 the autoload column has the values on, off, auto, auto-on and auto-off in addition to the old yes/no; a query with only autoload = 'yes' undercounts on updated sites. Site Health warns too when the size is too big.

  • Persistent object cache (Redis or Memcached) on sites with logged-in users, WooCommerce or many uncached requests: object caching with Redis.
  • WP-Cron from the system cron instead of page visits on busy sites: define( 'DISABLE_WP_CRON', true ); plus a cron job.
  • The MySQL slow query log for a day, to find what Query Monitor does not see (admin, cron, REST): MySQL slow query log.

3. Assets

  • The LCP element is known (PageSpeed Insights names it). If it is an image: not lazy-loaded, with fetchpriority="high", in the right size.
  • Images below the first screen with loading="lazy"; all images with width and height attributes; WebP or AVIF where the server and the theme support it.
  • No render-blocking JavaScript in the head; scripts with the defer or async strategy where possible.
  • CSS: the size of the stylesheets on a typical page, block styles loaded only for the blocks in use (should_load_separate_core_block_assets is on by default for block themes).
  • Fonts: as few files as possible, font-display: swap, self-hosted or with preconnect, the main font preloaded.
  • The total JavaScript of the page; every kilobyte is parsed on the main thread and affects INP.

Details for these points: Core Web Vitals in WordPress.

4. Third parties

  • A list of all third-party scripts on the page (WebPageTest, tab “Domains”) and who needs each of them.
  • Chat widgets, video embeds and maps loaded on interaction or with a facade (a static preview that loads the real embed on click).
  • Analytics and tag managers loaded with async, tags in the tag manager cleaned up once a year.
  • The long tasks in the Performance panel of Chrome DevTools: which script blocks the main thread during and after loading.

5. Write it down

A short table per finding: what, where, measured effect, effort, owner. The order of the fixes follows the effect on real users, not the order of this list. After each fix: the same measurements as in step 0, and a note with the date.

NOTE: Run lab tests in a private window without extensions, and with the same device profile each time; ad blockers and developer extensions change the results more than many optimizations do. Lab and field numbers will differ, and that is fine: the field data decides, the lab data explains.