# Optimizing Site Loading Speed

In this mini article, I want to highlight some basic yet important reasons that make your website slow. Learning what slows down your website is the key to improving performance and making smarter long-term decisions.

The primary bottlenecks for a slow WordPress website are:

❌ Slow web hosting
❌ Large unoptimized images
❌ Not configured server caching
❌ Too many separate CSS & JS assets to load
❌ Gzip text compression is turned off

# Pick Good Web Hosting

When a visitor opens your website, the page is being requested from a server. If that server:

  • Is shared virtually between many websites
  • Built upon poor non-performant cheap hardware
  • Doesn't have a speedy connection
  • Has very limited resource allocation

... then your website will be slow no matter what else you do. The solution is obvious here – don't buy cheap web hosting. A quality hosting provider is the first key to a fast website.

# Compress Your Images

Unminified images with abnormal resolution make a huge impact on your website loading speed. I recommend you use images no larger than 1920x1280 pixels. When it comes to optimization, I strongly recommend using the TinyPNG (opens new window) free online tool, which can drastically reduce your image size.

When I was building the demo content of the theme, all the images were optimized with TinyPNG. You can optimize your images from the browser (upload up to 20 at once for free) or use the official TinyPNG WordPress plugin (opens new window), which is a more convenient and time-saving way for optimization but may cost you money if your site has lots of images.

# Generate Static HTML Files

As you may know, WordPress works on a PHP language interpreter. Each time you visit your website, the parser does a large amount of work communicating with the database and executing PHP code.

If your website is not updated very often (for example, if you use your website just for portfolio presentation), then you may speed it up by generating static HTML files from your pages.

I recommend setting up and using the WP Super Cache (opens new window) plugin, which is free and very flexible. Rhye theme is tested and fully compatible with it. This includes AJAX transitions too.

# Optimize CSS & JS Assets

The Autoptimize (opens new window) plugin makes optimizing your site really easy. It can aggregate, minify, and cache both scripts and styles.

The plugin itself is very simple to set up and use. Here are the recommended settings, which you can find in the admin panel under Settings → Autoptimize → JS, CSS & HTML.

Recommended CSS & JS optimization options

WARNING

Please refrain from using the HTML minifier in Autoptimize as it may produce issues when AJAX transitions are turned on. You can achieve better (and issue-free) results using gzip compression.

Recommended HTML optimization options

# Enable Gzip

Gzip (opens new window) compression may save up to 70% bandwidth when transferring text assets, including CSS, JS, and HTML. Here are some useful articles: