How To Optimize WordPress Speed WITHOUT Plugins

We get asked about how to optimize WordPress speed without plugins more often than you’d expect. And there are valid reasons why some site admins want to do WordPress speed optimization without plugins – some sites are on a complex multisite installation, or have extremely high traffic and more plugins mean more complexity.

WordPress speed optimization without plugins

Below you’ll find our key recommendations for speeding up a WordPress website, or any other site for that matter, without using plugins. Using these steps, you’ll be able to get your WordPress website to load extremely fast BUT probably not as fast as it could if you were using plugins to do things like page caching and image optimization, so please keep that in mind.

Common Misconceptions

From what we see daily, there’s a frequent misconception that more plugins are ALWAYS worse when it comes to speed. However, that’s not the case, so if you’re avoiding plugins simply because of this, we urge you to rethink your position as there are some fantastic site speed plugins like WP Rocket out there that will make a world of difference to how fast your site runs.

Site Speed Bot

Identify The Root Cause So You Don’t Waste Time 

One very common mistake we see people make when working on their site speed is randomly testing tools and tactics without identifying the root cause for the slow loading speed of their site. Before doing anything, we’d strongly suggest you run a site speed test beforehand to identify the low-hanging fruit.

Our speed test tool SiteSpeedBot is 100% FREE and will give you detailed recommendations on what to do in under 60 seconds!

How to Optimize WordPress Speed Without Plugins

Some recommendations below are a bit technical, so if you have questions or need anything clarified, please leave a comment below.

1. Use a Good Host with page caching built-in

Web hosting is of huge importance for everything you do online, whether for your SEO, Google Adwords, Facebook Ads, or the inquiries, calls, and emails your website generates. Better hosting means better user experience, and a better user experience will increase your conversion rate. 

This being said, it’s clear that having reliable, fast hosting will shortly pay off. A quality host is one of the key factors in WordPress speed optimization without plugins. A good hosting provider uses NVME hard drives vs solid state drive (SSD) or standard hard drives (HDD), and so allows shorter page load times and better overall performance. Good providers come with larger bandwidth and RAM, which also implies better speed and more power to your website. 

Another important factor to consider are server locations. In most cases, websites will perform 1+ second slower outside of the country where the server is located. That’s why it’s important to use a server located in the country or continent where most of your visitors come from. 

Page Caching is an absolute must for WordPress

Without page caching, your WordPress site is going to crawl along. Typically you’ll need to use a plugin like WPRocket to add Page Caching to a site but some hosts also offer built-in page caching. In most cases however, this in-built caching will still require a plugin to manage the cache in an optimal fashion.

Surprisingly today, the price difference between high-quality hosts and garbage hosts is almost insignificant, so here’s a list of hosts we usually recommend:

Cloudways
  • Cloudways offers cheap hosting packages starting at $10/month. These guys use VPS servers on a speed-optimized server stack to provide high speed while offering 60+ locations around the globe.
  • Siteground stands out as one of the most affordable options, and still provides satisfactory site speed, which makes it a way better choice than other cheap hosts. 
  • WPAlpha Hosting is an excellent option for small businesses with a number of features built in including optional page caching.
  • Kinsta is pricier, but it’s one of the best choices for websites that have a lot of traffic. These guys do page caching at the server level without a plugin and so does WPengine.

2. Use HTTPS and ensure your host supports HTTP2 AND HTTP3 protocols and you have HSTS enabled

Running a site in HTTPS mode allows the browser to use the newer HTTP2 protocol, which speeds up how quickly the browser can download the site versus the older HTTP 1.1 protocol. Keep in mind that many cheap providers don’t support HTTP2 so if your host is lacking this support it’s an indication that their infrastructure is old or not up to scratch.

On today’s web, it’s ABSOLUTELY CRITICAL that your hosting supports both HTTP2 and HTTP3 protocols. A site running HTTP2 vs HTTP 1.1 will load 30-100% faster and HTTP3 gives a 10-15% boost over HTTP2 as well as slight TTFB benefits.

Our WordPress Speed Test tool will probe for HTTP2 protocol support and probing for HTTP3 can be done with this tool https://http3check.net/

If your host doesn’t support HTTP2 or HTTP3 then the first step should be to log a ticket and ask about this issue. Adding HTTP2 protocol support is relatively easy however HTTP3 support requires firewall changes and is a bit more complex.

HSTS boosts security AND speed!

HSTS is a server header and security mechanism that forces the browser to use HTTPS. This boost security AND also speed as the second time a visitor comes to your website their browser will automatically load the site from the HTTPS url variation. This is generally the case even if you type HTTP:// in the browser bar. HSTS reduces the number of redirects the user experiences when loading the site and allows your browser to use the HTTP2 to HTTP3 protocol immediately as these protocols are only available over HTTPS.

Click play on the video below to see how to enable HSTS in Cloudflare which is generally the simplest way to do it.

3. Use the Highest Version of PHP the Site Supports

PHP is the programming language or framework that WordPress is built on. Overall load speed typically increases 10-20% with each new version of PHP. In March of 2021, the newest 8.0.3. version of PHP was released. Most themes and plugins won’t support this version yet BUT it’s worth checking the version of PHP that you site can support and switching to that – version 7.4 is the version prior to v8 and most sites should support it.

WPEngine has a free plugin that can test your site for PHP compatibility on any host. Often you’ll have a couple of plugins that fail their automated testing but more often than not if you check with the plugin vendor and confirm what is the version of PHP their plugin can support.

4. Use Cloudflare for CDN, image optimization and firewall

Even with the worst hosting providers, Cloudflare can shorten your load times drastically. Even if you go for a free plan, it will make a huge difference in load speed. Here are the services Cloudflare offers to boost your site’s performance:

Cloudflare
  • DNS hosting is a service that brings your website to the user who typed its address into the URL bar. Cheap providers often have slow DNS hosting which results in failed or slow hookups, further causing a load time increase. Cloudflare is amongst the 10 fastest DNS hosts in the world (see https://dnsperf.com for rankings). In most cases, Cloudflare’s DNS hosting will speed up your site significantly
  • Cloudflare also provides firewall and security features giving better protection for your site, reduces the load on the hosting as it filters some of the garbage crawlers and scrapers hitting the site which helps increase the site’s speed. This article details some of the rules we use to boost security and performance using Cloudflare.
  • The $5/month APO service effectively does page caching at the edge. Edge caching essentially means entire pages are cached on Cloudflare’s server reducing the load on your hosting and putting the entire site closer to the visitor.
  • The $20/month plan offers some additional features like a full web application firewall (WAF), better image optimization and a handful more website acceleration features.

If you can’t use Cloudflare, at least use a CDN service (one that has image optimization built-in, like Bunny CDN). 

5. Turn on-Site Speed Optimizations in Your Theme

Many WordPress themes come with speed optimization features, such as lazy loading,  which means that images don’t load until the viewer gets to that part of the page, or combining CSS and JavaScript, which decreases the number of network requests a browser has to make. 

A large number of themes also have more up-to-date optimizations, like just in time preloading, which preloads the page just before a user clicks on it (see https://instant.page for an example).

It’s worth checking your theme for these settings to ensure they’re enabled as well as turning off any theme features you aren’t using as many features load additional javascript and CSS.

6. Compress Images Before You Upload Them

Compressing images before uploading them to your website can decrease the loading time of your page for precious 1-2 seconds, and so boost the site’s performance.

It’s important that you use lossless compression, which can cut image size by 20-50%, and leave the image quality unchanged.

Lossy compression can squeeze more from your images but does reduce the quality slightly so use it with caution. Imageoptim is a great tool for image compression. If you still want to use a plugin, check out our post on how to compress and insert web images in WordPress.

7. Make Sure Your Database Is Using the Innodb Storage Engine for All Tables

servebolt

MySQL uses two storage engines for it’s database tables InnoDB and MyISAM. Innodb is faster for WordPress sites but many older sites will be using MyISAM. Converting these tables to Innodb will improve speed substantially for database heavy sites like Woocommerce.

You can do this conversion in PHPMyAdmin at the database level but we generally use a plugin called Servebolt Optimizer which allows you to do this with a few clicks in the WP backend.

**Make sure you backup your database before messing with this.

8. Disable Any Plugins and Tools You’re Not Using

This tip is especially important for older websites. Check the list of plugins and tools your site uses, and make sure you delete or disable the ones that are no longer in use. From a speed point of view, fewer plugins mean better performance. Pay attention to plugins that load elements from other sites, because they might bring your site’s speed down. Other plugins that can heavily decrease a site’s speed are ones that implement tracking, live chat, or remarketing codes. 

Moving these tracking codes to Google Tag Manager and using the Window Loaded trigger OR pausing them with the Delay JS function in WP Rocket can speed these up substantially.

9. Use Google Tag Manager

You’re probably already familiar with Google Tag Manager. Moving code like Google Analytics and Google Adwords tracking code to GTM and firing this code with a Window Loaded Trigger can significantly reduce their impact on load times.

With this trigger the tag is fired once the entire content of the page has been fully loaded, including any embedded resources (images, scripts, etc.). You can find this trigger by going to Triggers (in GTM interface) > New > Window Loaded. GTM allows managing when the tag fires – the later the tag gets fired, the lesser impact it has on page loading speed.

10. Move Code to the Footer 

Moving as much JS code to the footer of the site as possible (for code in the <head> section, move it as close to the closing </head> as possible) loads the code later in the render process allowing the device to do more of the HTML processing up front. Often code is inserted at the very start of the <head> tag which can immediately slow down the render process and a simple change of moving this to the end of the </head> section can make a huge difference.

11. Fix 404 Errors! 404 Errors Are Terrible for Speed!

Frustrated customers are not the only result of broken links. Site’s speed and overall performance also suffer. The problem is that the page may be listed in search results, making search engines continue trying to crawl that non-existent URL instead of spending time and resources crawling real pages, which is why you should focus on fixing this. 

12. Configure Speculation Rules Appropriately

The speculation rules API is now fully supported in the core of WordPress. Basically, this feature starts background loading pages before the user clicks on them.

I won’t go into too much detail here but changing the preload settings to “eager” will make this feature work harder for you. This can be done at the code level or by using the speculative loading plugin – the plugin essentially adds the same code as the manual code feature. More details are available here

Leave a comment