I am trying to reduce the latency on site goldealers.co.uk
The site appears to have a latency of anywhere between 950ms and 1500ms.
I have checked:
- Processes
- RAM usage
- HTTP connections
- Ping
- Removing ALL plugins
Removing plugins doesn’t make the slightest bit of difference.
The server is a VPS Cloud Server with dedicated 1.5ghz processor and 1GB RAM.
My question:
- Is latency a server / programming problem?
- Do wordpress sites generally have a high latency?
- I have checked the latency on Forbes.com (a wordpress site) – This only has a latency of 151ms!!!
I will soon be working on caching, adding expires headers, possibly using a CDN for images etc… but to be honest, there is no point if it takes over 1 second to even start to return any data.
Any advice that you can provide is much appreciated.
Your analysis and priority are correct – starting with the base page load time first, then later optimizing the remaining front-end components.
In general WordPress sites by default can be a bit slow to deliver the HTML pages. Times in the range you mentioned 1-1.5 seconds are not uncommon. (For comparison, an unoptimized WordPress site I run is in the 1-3 second range.)
I would look into two areas:
It could be that your webhost does not have a very fast connection. You can test this (and eliminate the WordPress part of the equation) by fetching a static file. On your site, for example, I can pull the robots.txt file down in about 0.3 seconds. The speed to serve a static file is about your minimum baseline.
Next I would look at the MySQL database query speed. Is MySQL being served on the same host or a different one? The Debug Queries plugin can show you the exact queries being made and performance for each. If the DB queries appear to be the problem, the DB Cache Reloaded plugin can sometimes be helpful. It adds an additional layer of caching for frequent DB calls.
There are also some good suggestions in the answers to this SO question: How can I figure out why my site pages load so slowly?
Your latency is almost certainly a server-related issue. You said you have a VPS and most VPS installations come with all Apache modules enabled – all of which you DO NOT NEED for WordPress.
Eliminating all of the modules you don’t need reduces how much memory each PHP instance will consume.
I’ve answered this question here on stack overflow: How can I figure out why my WordPress pages load so slowly?
When I took a look at your site I saw that a lot of time is being killed on Facebook widgets. Testing from different locations around the world, looks like you are losing 2-3 seconds just for the facebook widgets. Drop those and you will have a much faster site.