How to reduce Initial server response time

How to reduce initial server response time?

I created a web 8 months ago and we have been facing “Reduce Initial server response time”.
We have enable CDN yet same issue repeats itself in search console.

We told it’s because of pagespeed.

We need help since Dreamhost is our host provider.

DreamHost servers are fast. Most my pages are 98 to 100 at pagespeed.

Your slow pages are because of how your site is constructed. WordPress is not a fast platform. Your database & backend creates your pages.This takes time (initial server response.) No changing much of that.

Having said that, there are a couple things that will help your pages load faster:
• Get rid of most of your plugins & themes. Slim it all down. Only keep what is absolutely necessary. Then get rid of still more. Remember, all this needs to load along with your pages.
• Reduce the byte size of all your images. Images are usually the slowest things to load. There are many image programs to reduce byte size, several free. This will make a huge difference.

Google’s Pagespeed (report in search console) measures your page speed primarily with FP (first paint.) The tool does not consider that many visitors are returning and load pages quicker because of previous caching. So your pages may appear to load fast for you, but for new visitors & Google’s Pagespeed, every file needs to be requested, found & displayed for the first time, every time.

As @keyplyr noted, WordPress is very slow in its default setup. Caching can help a lot:

@habilis I agree caching is extremely important for fast loading pages… when measuring load times for returning visitors who have previously cached some of the files needed to render the web page.

However… the OP seems to be concerned with the metric given in Google’s Search Console. This is basically the Pagespeed tool.

As I noted above, while the tool does note whether caching is being used, it does not use caching when rendering the page and arriving at the score. All requests are treated as first requests.

When you think about it, Google could not really do it any other way. Otherwise it would need to deliver many different scores, each for various browsers accepting various caching parameters, various server configs, etc.

Ah, I should have been more clear and distinguished between client-side and server-side caching. @keyplyr’s right that client-side caching (i.e. cacheing controlled by the Cache-Control HTTP header) isn’t used when scoring performance.

WordPress caching plugins control server-side caching, which is invisible to performance tools. When building a typical page, WP will run dozens of DB queries and thousands of lines of plugin code – this quickly adds up to a slow response time. By caching the resulting HTML, you can speed up subsequent deliveries of the page.

As an example of server-side caching, one WP site I know uses WP-Super-Cache, which records the page generation time in a comment on the cached page:

<!-- Dynamic page generated in 1.437 seconds. -->
<!-- Cached page generated by WP-Super-Cache on 2020-12-26 09:53:04 -->
<!-- super cache -->

With caching, the page is server in 0.075 seconds. That’s 19 times faster!

@habilis - thanks for that clarification. Actually, I hadn’t considered the plugin affecting the backend, which indeed would affect server response time.

WP cache plugins only work after a PHP handler is fired up, then the WP code is loaded and it’s requisite MySQL queries have all completed. This is problematic on accounts were PHP processes are killed after a few minutes of inactivity. For example, it is not uncommon for a very basic WP site (with super cache) to take quite some time to first response on a DH shared plan if no one has hit it for a while.

https://xwordpress.dreamhosters.com

<!-- Dynamic page generated in 10.298 seconds. -->
<!-- Cached page generated by WP-Super-Cache on 2021-05-16 08:26:55 -->
<!-- super cache -->

Some cache plugins, like WP-Super-Cache, have a mode (advanced/expert mode) that statically caches the site using only the web server, so no PHP is invoked. When this mode is activated, anonymous visitors are only served from the cache by Apache. Fancy .htaccess rules allow logged-in users to interact directly with WP.

It does, however anyone who uses the quote (Recommended) wp-super-cache instructions – which are parroted in Dreamhost’s knowledge base regarding it’s installation btw – will be led to believe that the default settings (i.e. not Advanced) are good enough.