I frequently get questions along the lines of the following: “How do your themes handle performance? I really need a fast theme.”

Doesn’t everybody?

Page speed is something every website operator should be concerned with. Can you imagine what happens on most websites that take more than five seconds to load?

Well you don’t have to imagine, because data shows the vast majority of users would rather just hit the back button than wait for your site to load at a snail’s pace.

We’re way past the days of dial-up, and web surfers are conditioned to speed.

But how important is the theme itself when it comes to web performance? Perhaps not as critical as you might think.

How we build performance into our themes

We certainly do keep performance in mind when building WordPress themes. Here are a few ways Themetry does that:

  • Make use of transients when appropriate. Like for category lists, the code of which we crib on each of our themes from Underscores.
  • Avoid unbounded queries. Which would be more of a “prevent server from becoming enveloped in flames” thing rather than a performance issue.
  • Generally keep queries under control. We typically only have one loop per page, and try not to query anything unnecessary.
  • Utilize Google Fonts CDN, which has a bonus benefit of having fonts potentially already cached locally on a visitor’s machine (if they visited another site using them before).
  • Write efficient, only-as-needed CSS and avoid including gigantic “front end frameworks” in their entirety to keep file sizes low.

How we intentionally compromise performance in our themes

Our themes could be faster out of the box, however.

Most notably, we don’t minify or concatenate scripts and styles out of the box.

In fact, we usually even separate specific JS-based functionality in compartmentalized files, so they can be easily modified/removed with a child theme.

As I’ve alluded to in past blog posts, we’re biased for ease of customization, even if it compromises performance.

We don’t want to make any assumptions about your build processes, or minification preferences.

Maybe you like to use Gulp to generate your minified/concatenated assets. Or perhaps you’d prefer to use something like Better WordPress Minify to more easily include all the other stylesheets and JavaScript files other plugins load onto your site. We don’t know.

We just want to make sure our themes are as easy to use and as easy to customize as possible. Even at the cost of a few lost milliseconds, which we make no apologies for.

Non-theme related factors that affect page speed

Note that “theme related” does not necessarily equate to “front end related.” But how a user (mis)uses a theme can’t really be faulted on the theme.

This also won’t be an exhaustive list. Merely a sampling to illustrate how relatively inconsequential the theme is to the performance equation.

Optimized images

Adding images to your posts are a nice way to break up long swaths of text.

But many go overboard with too many bandwidth-hogging images.

And to make matters worse, these images could be losslessly optimized for significant file size savings, but aren’t.

Use something like Kraken to fix this.

PHP 7 or nah?

Studies show that simply enabling PHP 7 can drastically improve performance.

That’s it.

You’ll need a host that supports it though, or manage your own server and install it yourself.

Caching everything realistically possible

Caching can get complicated on highly dynamic sites.

However, for many WordPress sites, just activating a page caching solution like WP Super Cache will work wonders.

It’ll make sure logged in users and commenters can still see their stuff, but the vast majority of your visitors will be served static pages, resulting in a much lighter load on your server.

Server Power

The most optimized theme in the world won’t help you if your server does not have adequate resources to serve web pages.

If your host complains about high server load, it might be time to upgrade your plan.

Be wary of resource-hogging plugins (like broken link checkers) and server processes (like sending mass emails which could be offloaded to a third-party service like Amazon SES).

So there you have it

We don’t mean to diminish the importance of a theme in the performance equation, but unless the theme is really bad, there are probably more pertinent performance issues you should be concerned with.

The main point is: theme performance shouldn’t be measured in a vacuum. Type your URL into something like Google PageSpeed Insights and you’ll quickly realize how much more there is to it.

Performance is best handled on a site-by-site basis, after considering every level of the website stack: application (WordPress, themes, plugins), server, and even DNS.

Hyper-focusing on how “fast” a theme is, while ignoring other performance factors, could be a costly mistake.

Previous Article
Developing WordPress sites locally with AMPPS
Next Article
Bari 1.1.0 Theme Update