How To Speed Up WordPress Performance At The Server Level

We all know that WordPress is the best CMS for creating any type of website. WordPress has many optimization plugins that optimize WordPress and improves speed.

However, those plugins can improve speed to some extent. To be in the competition and to make websites faster, we need to do some sort of optimization at the server level too.

Server-level optimization can return a good yield if it is done correctly. So in this article, we will talk about How To Speed Up WordPress Performance using some server-level optimization.

If you are using shared hosting, then you can hardly do any setting changes at the server level because most settings will be locked for you.

But if you are on VPS or a dedicated server, then you will get the authority to change the setting at the server level.

To optimize at the server level, you should have a basic knowledge and understanding of how web hosting works. Also, you should know about the different types of web hosting.

How To Speed Up WordPress Performance?

Here are some of the tips that you can follow to speed up your WordPress blog.

Use A Good Web Server

Many of us don’t even check the web server before choosing a web hosting plan. That is a big mistake because a web server is the heart of your web hosting.

Apache is the default choice for almost all shared hosting and VPS. However, Apache is a very slow web server and is not recommended if you care for speed.

Instead, we can go for the LightSpeed server, if not at least go for the NGNIX.

Use A Cache Module

The cache module acts as a mediator between web browsers and web servers. Cache modules save static files in their modules so that whenever visitors request any web content, it is directly served by the cache module instead of fetching that from the main web server.

This helps in loading the website much faster than before. Below two cache modules are very popular.

Both varnish and NGINX cache modules can be installed on Apache and NGINX web servers. For shared hosting, a cache module will be installed by your host. For VPS and Dedicated servers, you need to install the cache module.

Use A Reverse Proxy

A reverse proxy is an intermediate proxy server that handles all client requests as if it is the main server.

Whenever a client request happens, the reverse proxy server serves the content without bothering the main server.

how to Speed Up WordPress Performance

The main difference between the forward and reverse proxy is that, in the case of the forward proxy, the proxy needs to be there at the client level. But in the case of reverse proxy, it sits on the server level.

NGINX reverse proxy is very popular and can be installed on Apache and NGINX. So for those who are looking for a reverse proxy module, NGINX reverse proxy is a very good option.

Enable GZIP compression

More than 90% of websites show content in a compressed format. If data is not compressed, it will take more time for a website to load which is annoying for many visitors.

You can enable GZIP compression by using a WordPress plugin but the same can be done by changing some settings at the server level.

To enable GZIP compression without any plugin, You can add the following code in your .htaccess file. Please make sure that you add this code after the existing derivatives.

Also, you need to ensure that the mod_filter is active in your server, otherwise, you will get an HTTP 500 error.

<IfModule mod_deflate.c>
  # Compress HTML, CSS, JavaScript, Text, XML and fonts
  AddOutputFilterByType DEFLATE application/javascript
  AddOutputFilterByType DEFLATE application/rss+xml
  AddOutputFilterByType DEFLATE application/
  AddOutputFilterByType DEFLATE application/x-font
  AddOutputFilterByType DEFLATE application/x-font-opentype
  AddOutputFilterByType DEFLATE application/x-font-otf
  AddOutputFilterByType DEFLATE application/x-font-truetype
  AddOutputFilterByType DEFLATE application/x-font-ttf
  AddOutputFilterByType DEFLATE application/x-javascript
  AddOutputFilterByType DEFLATE application/xhtml+xml
  AddOutputFilterByType DEFLATE application/xml
  AddOutputFilterByType DEFLATE font/opentype
  AddOutputFilterByType DEFLATE font/otf
  AddOutputFilterByType DEFLATE font/ttf
  AddOutputFilterByType DEFLATE image/svg+xml
  AddOutputFilterByType DEFLATE image/x-icon
  AddOutputFilterByType DEFLATE text/css
  AddOutputFilterByType DEFLATE text/html
  AddOutputFilterByType DEFLATE text/javascript
  AddOutputFilterByType DEFLATE text/plain
  AddOutputFilterByType DEFLATE text/xml  

  # Remove browser bugs (only needed for ancient browsers)
  BrowserMatch ^Mozilla/4 gzip-only-text/html
  BrowserMatch ^Mozilla/4\.0[678] no-gzip
  BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
  Header append Vary User-Agent

How to enable GZIP compression in C Panel

  • Log in to C Panel
  • Go to Optimize Website under “Software
  • Select desired compression option
how to Speed Up WordPress Performance

Optimize Images

If you are using Apache or NGINX, then you can use the Page Speed module to optimize images at the server level. However, you can always optimize images by using WordPress plugins.

Page speed modules compress images and thus improve website loading time. Ideally, it can reduce image size by up to 50% by removing no visible image information and applying high-efficiency compression methods.

It also supports offering new image formats like WEP. If you allow the page speed module to change your HTML and CSS code then it reduces image size more and loads your website faster.

You can read this article to more about how to optimize images in Apache


A CDN ( Content Delivery Network) helps you by offering seamless speed for your website across the globe. CDN uses a bunch of servers in various cities of the world. Those servers copy your website content.

So whenever a visitor visits your website, the content gets delivered from the nearest server. That is why every visitor will get almost the same speed when you are on a CDN.

Cloudflare and BunnyCDN are the two most popular CDN for WordPress. If you use Cloudflare, then please use the WordPress plugin ” Super page cache for Cloudflare” for full page caching. Full page caching improves your website TTFB.

Use HTTP/ 2 Or HTTP/3 protocol

HTTP/ 2 or HTTP version 2 protocol can load your website much faster than HTTP/1. At present, only about 10 million websites use the HTTP/2 protocol. But these numbers are increasing and if you want to increase your website loading speed then you should use the HTTP/2 protocol.

If you are using shared hosting then you might see a straightforward setting to enable HTTP/2. In VPS or dedicated servers, you have to install the module manually depending on your server type.

You can also enable HTTP/2 in Cloudflare CDN without doing anything at the server level.

If you want to use HTTP/3 or then you need to use Lite Speed server as they have the support for HTTP/3 protocol.


SSL ( Secure Sockets Layer) certificates are a must for websites. Google does not entertain any website without an SSL certificate.

SSL helps in blocking non-secure content and thus increases the website speed. Free Lets Encrypt SSL certificate is offered by almost all web hosts.

For VPS and dedicated servers, you need to install the SSL certificate manually.

Minify Codes

There are many server modules available that can minify CSS, JavaScript, and HTML codes to optimize websites.

Unnecessary codes are a big burden for speed. Minifying codes helps in removing those extra codes and loading your website fast.

Apart from minifying codes at the server level, you can also minify codes using cache plugins like WP Rocket.

Optimize PHP setting

Shared hosting does not allow for PHP setting changes. If you use a VPS or dedicated server then you can apply the below PHP setting to get the best out of your server.

memory_limit = 128M
suhosin.get.max_vars = 10000; = 10000;

Conclusion: How To Speed Up WordPress Performance

Optimizing WordPress is the market demand. Slow-loading websites are of no use as Google does not rank high if your website loads very slowly.

You need to make sure that your websites meet the Google Web Core Vitals. You can easily do that by applying some server-level optimization and WordPress-level optimization.

We have only shown 10 optimization tricks. But there could be hundreds of other tricks. If you feel that I have missed any important tricks here, please write in the comment section and I will include it in the article.


Rajib Is The Founder Of RiansTech. A Seasonal Blogger And A Full-Time Product Designer For Over Two Decades. A Technology Freak And Loves To Write About It. RiansTech Is A Online Home For Him Where He Documents His Experiences And Learnings So That Others Can Get Benefited From It.